From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 19988 invoked by alias); 22 Jun 2012 21:01:39 -0000 Received: (qmail 19972 invoked by uid 22791); 22 Jun 2012 21:01:38 -0000 X-SWARE-Spam-Status: No, hits=-6.3 required=5.0 tests=AWL,BAYES_00,KHOP_RCVD_UNTRUST,RCVD_IN_DNSWL_HI,RCVD_IN_HOSTKARMA_W,SPF_HELO_PASS,T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from mx4-phx2.redhat.com (HELO mx4-phx2.redhat.com) (209.132.183.25) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Fri, 22 Jun 2012 21:01:20 +0000 Received: from zmail16.collab.prod.int.phx2.redhat.com (zmail16.collab.prod.int.phx2.redhat.com [10.5.83.18]) by mx4-phx2.redhat.com (8.13.8/8.13.8) with ESMTP id q5ML1JP5003163; Fri, 22 Jun 2012 17:01:19 -0400 Date: Fri, 22 Jun 2012 21:09:00 -0000 Subject: Re: New option to turn off stack reuse for temporaries Message-ID: From: Jason Merrill To: Richard Guenther Cc: Xinliang David Li , GCC Patches , Michael Matz MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit 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: 2012-06/txt/msg01505.txt.bz2 Yes. -------- Original Message -------- From: Richard Guenther Sent: Fri, Jun 22, 2012 02:39 AM To: Jason Merrill CC: Xinliang David Li ; GCC Patches ; Michael Matz Subject: Re: New option to turn off stack reuse for temporaries On Fri, Jun 22, 2012 at 11:29 AM, Jason Merrill wrote: > On 06/22/2012 01:30 AM, Richard Guenther wrote: >>> >>> What other issues? It enables more potential code motion, but on the >>> other hand, causes more conservative stack reuse. As far I can tell, >>> the handling of temporaries is added independently after the clobber >>> for scoped variables are introduced. This option can be used to >>> restore the older behavior (in handling temps). >> >> >> Well, it does not really restore the old behavior (if you mean before >> adding >> CLOBBERS, not before the single patch that might have used those for >> gimplifying WITH_CLEANUP_EXPR).  You say it disables stack-slot sharing >> for those decls but it also does other things via side-effects of no >> longer >> emitting the CLOBBER.  I say it's better to disable the stack-slot >> sharing. > > > The patch exactly restores the behavior of temporaries from before my change > to add CLOBBERs for temporaries.  The primary effect of that change was to > provide stack-slot sharing, but if there are other effects they are probably > desirable as well, since the broken code depended on the old behavior. So you see it as workaround option, like -fno-strict-aliasing, rather than debugging aid? Richard. > Jason