From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 30650 invoked by alias); 10 Sep 2009 14:37:17 -0000 Received: (qmail 30609 invoked by uid 22791); 10 Sep 2009 14:37:15 -0000 X-SWARE-Spam-Status: No, hits=-3.6 required=5.0 tests=AWL,BAYES_00 X-Spam-Check-By: sourceware.org Received: from cantor2.suse.de (HELO mx2.suse.de) (195.135.220.15) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Thu, 10 Sep 2009 14:37:08 +0000 Received: from relay1.suse.de (mail2.suse.de [195.135.221.8]) by mx2.suse.de (Postfix) with ESMTP id 00B998672B; Thu, 10 Sep 2009 16:37:06 +0200 (CEST) Date: Thu, 10 Sep 2009 14:37:00 -0000 From: Richard Guenther To: Richard Henderson Cc: gcc-patches@gcc.gnu.org, Diego Novillo Subject: Re: [PATCH] Merge from LTO: eh_personality changes In-Reply-To: Message-ID: References: <4AA293E4.8090301@redhat.com> <4AA2A9D7.3030406@redhat.com> <4AA67D0C.8000704@redhat.com> User-Agent: Alpine 2.00 (LNX 1167 2008-08-23) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org X-SW-Source: 2009-09/txt/msg00688.txt.bz2 On Thu, 10 Sep 2009, Richard Guenther wrote: > On Tue, 8 Sep 2009, Richard Henderson wrote: > > > On 09/08/2009 08:20 AM, Richard Guenther wrote: > > > > Ok. I'll modify the patch to make this a true langhook and maybe move > > > > the eh-personality also to a langhook called from eh lowering. > > > > > > The latter is difficult as C++ is playing some tricks with Java vs. > > > non-Java personality, so I leave that alone for now. > > > > Ew. > > > > > FYI the following two patches would implement the above (untested). > > > > Looks good. > > I've been playing a bit with optimizing setting of > DECL_FUNCTION_EH_PERSONALITY only if the function uses EH types > instead of just checking for an empty EH region tree. It doesn't look > like its very simple - even a catch (...) needs a personality routine. > > So I am now testing the following - the ERT_ALLOWED_EXCEPTIONS case > is required to get diagnostics from g++.dg/torture/pr34850.C which > requires inlining memset into clear_mem. > > If that doesn't work out I'll refrain from optimizing at all and > just disable cross different EH personality TU inlining completely > (that already passed bootstrapping and testing, it would be > - if (function_needs_eh_personality (cfun)) > - DECL_FUNCTION_PERSONALITY (current_function_decl) = > eh_personality_decl; > + DECL_FUNCTION_PERSONALITY (current_function_decl) = > eh_personality_decl; > meaning no functional change as far as trunk is concerned) Doesn't seem to work. Instead I tried to fall back to the gcc personality for detecting empty type lists, again setting a cfi personality for all functions we emit. But that doesn't work either (it seems catch (...) doesn't work with the gcc personality, g++.dg/eh/loop1.C fails). Bah. So, ok without trying to be clever about inlining cross personality for now? Thanks, Richard.