From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 100136 invoked by alias); 25 Jul 2018 11:02:49 -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 100118 invoked by uid 89); 25 Jul 2018 11:02:48 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-1.9 required=5.0 tests=BAYES_00,SPF_HELO_PASS autolearn=ham version=3.3.2 spammy=Hx-languages-length:1116 X-HELO: mx1.redhat.com Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Wed, 25 Jul 2018 11:02:47 +0000 Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.phx2.redhat.com [10.5.11.23]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id BE3DAC0587D5; Wed, 25 Jul 2018 11:02:46 +0000 (UTC) Received: from tucnak.zalov.cz (ovpn-117-71.ams2.redhat.com [10.36.117.71]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 53A5426E69; Wed, 25 Jul 2018 11:02:46 +0000 (UTC) Received: from tucnak.zalov.cz (localhost [127.0.0.1]) by tucnak.zalov.cz (8.15.2/8.15.2) with ESMTP id w6PB2hcq020380; Wed, 25 Jul 2018 13:02:44 +0200 Received: (from jakub@localhost) by tucnak.zalov.cz (8.15.2/8.15.2/Submit) id w6PB2frE020379; Wed, 25 Jul 2018 13:02:41 +0200 Date: Wed, 25 Jul 2018 11:02:00 -0000 From: Jakub Jelinek To: Alexandre Oliva Cc: Tom de Vries , Richard Biener , gcc-patches@gcc.gnu.org, Jim Wilson Subject: Re: [RFC 2/3, debug] Add fkeep-vars-live Message-ID: <20180725110241.GO17988@tucnak> Reply-To: Jakub Jelinek References: <20180716132909.633uvqxojzgg3wg6@delia> <0e82c00b-a8fc-9f8a-0115-9f7254e1bde1@suse.de> <16bec84d-f6e8-60be-c764-83eb4861b515@suse.de> <20180724113732.xo4av4fcbgigi7w2@delia> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.9.2 (2017-12-15) X-IsSubscribed: yes X-SW-Source: 2018-07/txt/msg01512.txt.bz2 On Tue, Jul 24, 2018 at 04:11:11PM -0300, Alexandre Oliva wrote: > On Jul 24, 2018, Tom de Vries wrote: > > > This patch adds fake uses of user variables at the point where they go out of > > scope, to keep user variables inspectable throughout the application. > > I suggest also adding such uses before sets, so that variables aren't > regarded as dead and get optimized out in ranges between the end of a > live range and a subsequent assignment. But that can be done incrementally, right, and perhaps being controllable by a level of this option, because such extra uses might make it even more costly. Though, if the extra uses and sets aren't in the same stmt, then the optimizers could still move it appart (in addition of it making the IL larger). We need to think about different cases (non-gimple reg vars are probably ok, they just live in memory unless converted (sra etc.) into gimple reg vars, then what to do about SSA_NAMEs with underlying user variable if it doesn't have overlapping ranges, if it does have overlapping ranges). Jakub