From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from nikam.ms.mff.cuni.cz (nikam.ms.mff.cuni.cz [195.113.20.16]) by sourceware.org (Postfix) with ESMTPS id 0D6E03858D39 for ; Tue, 27 Jun 2023 16:24:36 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 0D6E03858D39 Authentication-Results: sourceware.org; dmarc=fail (p=none dis=none) header.from=ucw.cz Authentication-Results: sourceware.org; spf=none smtp.mailfrom=kam.mff.cuni.cz Received: by nikam.ms.mff.cuni.cz (Postfix, from userid 16202) id 20024281AB9; Tue, 27 Jun 2023 18:24:34 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ucw.cz; s=gen1; t=1687883074; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=Tc036ZixrLepeC9K+99HLT4Q1ZgqvzCUvbOBvscr5EU=; b=aoXAQuX3Qg6CikbEonIstwTEnvi+QSYYD1yz9DDMdTTqF5vOXOX1d4VCRJYjbBhWPTMJzq N/86Lb9JgxZs+SbDhpqz7TmfR53T7HB+exI3eOzjckrIoGKuxckgH9LpUTf0vqBNh2R3CP XuMEWZKkwbe/BMgIJ/WEw2BJsIGfbA0= Date: Tue, 27 Jun 2023 18:24:34 +0200 From: Jan Hubicka To: Andrew MacLeod Cc: aldyh@redhat.com, mjambor@suse.cz, gcc-patches@gcc.gnu.org, jwakely@redhat.com Subject: Re: Enable ranger for ipa-prop Message-ID: References: <4d2f5bc2-c4ff-7576-cb82-b6c8a1a1da5f@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-2 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <4d2f5bc2-c4ff-7576-cb82-b6c8a1a1da5f@redhat.com> X-Spam-Status: No, score=-5.1 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL,SPF_HELO_NONE,SPF_NONE,TXREP,T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: > > On 6/27/23 09:19, Jan Hubicka wrote: > > Hi, > > as shown in the testcase (which would eventually be useful for > > optimizing std::vector's push_back), ipa-prop can use context dependent ranger > > queries for better value range info. > > > > Bootstrapped/regtested x86_64-linux, OK? > > Quick question. > > When you call enable_ranger(), its gives you a ranger back, but it also sets > the range query for the specified context to that same instance.  So from > that point forward  all existing calls to get_range_query(fun) will now use > the context ranger > > enable_ranger (struct function *fun, bool use_imm_uses) > <...> >   gcc_checking_assert (!fun->x_range_query); >   r = new gimple_ranger (use_imm_uses); >   fun->x_range_query = r; >   return r; > > So you probably dont have to pass a ranger around?  or is that ranger you > are passing for a different context? I don't need passing ranger around - I just did not know that. I tought the default one is the context insensitive one, I will simplify the patch. I need to look more into how ranger works. Honza > > > Andrew > >