public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Andrew MacLeod <amacleod@redhat.com>
To: Andrew Pinski <pinskia@gmail.com>
Cc: gcc-patches <gcc-patches@gcc.gnu.org>,
	Aldy Hernandez <aldyh@redhat.com>,
	 Richard Biener <richard.guenther@gmail.com>,
	Jakub Jelinek <jakub@redhat.com>
Subject: Re: [PATCH] Ranger : Do not process abnormal ssa-names.
Date: Mon, 18 Oct 2021 12:08:23 -0400	[thread overview]
Message-ID: <0ab30e4e-150c-7164-6e42-b1c939bc9376@redhat.com> (raw)
In-Reply-To: <CA+=Sn1=aFXtFxcYAOxgKPoEvp3vjAaWeGMRptACCrvRiVJGCFA@mail.gmail.com>

On 10/16/21 5:27 AM, Andrew Pinski wrote:
> On Fri, Oct 15, 2021 at 6:53 AM Andrew MacLeod via Gcc-patches
> <gcc-patches@gcc.gnu.org> wrote:
>> I've been looking at the pathological time issue ranger has with the
>> testcase from, uuuuuh..  PR 97623 I think.  I've lost the details, but
>> kept the file since it was showing unpleasant behaviour.
>>
>> Most of the time is spent in callbacks from substitute_and_fold to
>> value_on_edge()  dealing with PHI results and arguments.  Turns out, its
>> virtually all wasted time dealing with SSA_NAMES with the
>> OCCURS_IN_ABNORMAL_PHI flag set..
>>
>> This patch tells ranger not to consider any SSA_NAMEs which occur in
>> abnormal PHIs.  This reduces the memory footprint of all the caches, and
>> also has a ripple effect with the new threader code which uses the GORI
>> exports and imports tables, making it faster as well as no ssa-name with
>> the abnormal flag set will be entered into the tables.
>>
>> That alone was not quite enough, as all the sheer volume of call backs
>> still took time,  so I added checks in the value_of_* class of routines
>> used by substitute_and_fold to indicate there is no constant value
>> available for any SSA_NAME with that flag set.
>>
>> On my x86_64 box, before this change, that test case looked like:
>>
>> tree VRP                           :   7.76 (  4%)   0.23 ( 5%)   8.02
>> (  4%)   537k (  0%)
>> tree VRP threader                  :   7.20 (  4%)   0.08 (  2%) 7.28 (
>> 4%)   392k (  0%)
>> tree Early VRP                     :  39.22 ( 22%)   0.07 (  2%) 39.44 (
>> 22%)  1142k (  0%)
>>
>> And with this patch , the results are:
>>
>>    tree VRP                           :   7.57 (  6%)   0.26 ( 5%)   7.85
>> (  6%)   537k (  0%)
>>    tree VRP threader                  :   0.62 (  0%)   0.02 ( 0%)   0.65
>> (  0%)   392k (  0%)
>>    tree Early VRP                     :   4.00 (  3%)   0.01 ( 0%)   4.03
>> (  3%)  1142k (  0%)
>>
>> Which is a significant improvement, both for EVRP and the threader..
>>
>> The patch adjusts the ranger folder, as well as the hybrid folder.
>>
>> bootstrapped on x86_64-pc-linux-gnu with no regressions and no missed
>> cases that I have been able to find.
> Did you test it with go enabled?
> Because others and myself are now running into a bootstrap failure
> most likely due to this patch.
> The number of SSA_NAME_OCCURS_IN_ABNORMAL_PHI in go is increased due
> to -fnon-call-exceptions being true there.

I would have sworn upside down I did, but looking at my build script, 
somewhere along the way GO got turned off, so although I was building 
ada, GO was not being included.. sorry.

I'll get this resolved this afternoon.

Andrew


  parent reply	other threads:[~2021-10-18 16:08 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-10-15 13:50 Andrew MacLeod
2021-10-15 14:17 ` Jeff Law
2021-10-15 16:05   ` [COMMITTED] " Andrew MacLeod
2021-10-15 14:21 ` [PATCH] " Aldy Hernandez
2021-10-15 14:23   ` Jeff Law
2021-10-16  9:27 ` Andrew Pinski
2021-10-16 16:22   ` Iain Sandoe
2021-10-18 16:08   ` Andrew MacLeod [this message]
2021-10-18  9:49 ` Richard Biener
2021-10-18 22:05   ` [COMMITTED] tree-optimization/102796 - Process EH edges again Andrew MacLeod

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=0ab30e4e-150c-7164-6e42-b1c939bc9376@redhat.com \
    --to=amacleod@redhat.com \
    --cc=aldyh@redhat.com \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=jakub@redhat.com \
    --cc=pinskia@gmail.com \
    --cc=richard.guenther@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).