From: Jeff Law <jeffreyalaw@gmail.com>
To: Richard Biener <rguenther@suse.de>, gcc-patches@gcc.gnu.org
Cc: Jakub Jelinek <jakub@redhat.com>
Subject: Re: [PATCH] rtl-optimization/109237 - quadraticness in delete_trivially_dead_insns
Date: Fri, 31 Mar 2023 10:30:05 -0600 [thread overview]
Message-ID: <e3008ef0-d569-1961-bffd-ccddab817840@gmail.com> (raw)
In-Reply-To: <20230322100210.AE2793857B9B@sourceware.org>
On 3/22/23 04:01, Richard Biener via Gcc-patches wrote:
> The following addresses quadraticness in processing debug insns
> in delete_trivially_dead_insns and insn_live_p by using TREE_VISITED
> on the INSN_VAR_LOCATION_DECL to indicate a later debug bind
> with the same decl and no intervening real insn or debug marker.
> That gets rid of the NEXT_INSN walk in insn_live_p in favor of
> first clearing TREE_VISITED in the first loop over insn and
> the book-keeping of decls we set the bit since we need to clear
> them when visiting a real or debug marker insn.
>
> That improves the time spent in delete_trivially_dead_insns from
> 10.6s to 2.2s for the testcase.
>
> Bootstrapped and tested on x86_64-unknown-linux-gnu.
>
> OK?
>
> Thanks,
> Richard.
>
> PR rtl-optimization/109237
> * cse.cc (insn_live_p): Remove NEXT_INSN walk, instead check
> TREE_VISITED on INSN_VAR_LOCATION_DECL.
> (delete_trivially_dead_insns): Maintain TREE_VISITED on
> active debug bind INSN_VAR_LOCATION_DECL.
OK
jeff
next parent reply other threads:[~2023-03-31 16:30 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20230322100210.AE2793857B9B@sourceware.org>
2023-03-31 16:30 ` Jeff Law [this message]
2023-03-22 10:01 Richard Biener
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=e3008ef0-d569-1961-bffd-ccddab817840@gmail.com \
--to=jeffreyalaw@gmail.com \
--cc=gcc-patches@gcc.gnu.org \
--cc=jakub@redhat.com \
--cc=rguenther@suse.de \
/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).