From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 11589 invoked by alias); 17 May 2016 08:47:03 -0000 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 Received: (qmail 11579 invoked by uid 89); 17 May 2016 08:47:02 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.8 required=5.0 tests=AWL,BAYES_00,RP_MATCHES_RCVD,SPF_HELO_PASS,SPF_PASS autolearn=ham version=3.3.2 spammy= X-HELO: gate.crashing.org Received: from gate.crashing.org (HELO gate.crashing.org) (63.228.1.57) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES256-SHA encrypted) ESMTPS; Tue, 17 May 2016 08:47:00 +0000 Received: from gate.crashing.org (localhost.localdomain [127.0.0.1]) by gate.crashing.org (8.14.1/8.13.8) with ESMTP id u4H8kt6H024296; Tue, 17 May 2016 03:46:55 -0500 Received: (from segher@localhost) by gate.crashing.org (8.14.1/8.14.1/Submit) id u4H8ksvm024295; Tue, 17 May 2016 03:46:54 -0500 Date: Tue, 17 May 2016 08:47:00 -0000 From: Segher Boessenkool To: Eric Botcazou Cc: gcc-patches@gcc.gnu.org Subject: Re: [PATCH 1/3] function: Do the CLEANUP_EXPENSIVE after shrink-wrapping, not before Message-ID: <20160517084654.GB18363@gate.crashing.org> References: <213485283eede9da12b217737d95fc8f5c4be442.1463428211.git.segher@kernel.crashing.org> <1831730.xXXSthoG5j@polaris> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1831730.xXXSthoG5j@polaris> User-Agent: Mutt/1.4.2.3i X-IsSubscribed: yes X-SW-Source: 2016-05/txt/msg01176.txt.bz2 On Tue, May 17, 2016 at 10:05:57AM +0200, Eric Botcazou wrote: > > We should do CLEANUP_EXPENSIVE after shrink-wrapping, because shrink- > > wrapping creates constructs that CLEANUP_EXPENSIVE can optimise, and > > nothing runs CLEANUP_EXPENSIVE later. We don't need cleanup_cfg before > > shrink-wrapping, nothing in shrink-wrapping (or the other *logue insertion > > code) cares at all. > > Are you sure of that? I agree that CLEANUP_EXPENSIVE might be overkill, but > can't cleanup_cfg expose more opportunities to have multiple epilogues? How would it? The shrink-wrapping algorithms do not much care how you write your control flow. The only things I can think of are drastic things like removing some dead code, or converting a switch to a direct jump, but those had better be done for the immediately preceding passes already (register allocation). I can put back a cleanup_cfg (0) in front if that seems less tricky (or just safer)? Segher