This is the mail archive of the
mailing list for the GCC project.
Re: Proposal for path splitting for reduction in register pressure for Loops.
- From: Jeff Law <law at redhat dot com>
- To: Richard Biener <richard dot guenther at gmail dot com>
- Cc: Ajit Kumar Agarwal <ajit dot kumar dot agarwal at xilinx dot com>, "vmakarov at redhat dot com" <vmakarov at redhat dot com>, "gcc at gcc dot gnu dot org" <gcc at gcc dot gnu dot org>, Vinod Kathail <vinodk at xilinx dot com>, Shail Aditya Gupta <shailadi at xilinx dot com>, Vidhumouli Hunsigida <vidhum at xilinx dot com>, Nagaraju Mekala <nmekala at xilinx dot com>
- Date: Mon, 09 Mar 2015 11:31:25 -0600
- Subject: Re: Proposal for path splitting for reduction in register pressure for Loops.
- Authentication-results: sourceware.org; auth=none
- References: <BN1AFFO11OLC004D84D26C6A4468398AD3DAE1A0 at BN1AFFO11OLC004 dot protection dot gbl> <7A0E44F9-1DB4-44C6-85C6-B8DF48E5B589 at gmail dot com> <BY2FFO11OLC0045AF32468170562DF25ACAE1A0 at BY2FFO11OLC004 dot protection dot gbl> <D6FE4994-7C21-49EB-8398-1C940F536C09 at gmail dot com> <54FCA7D6 dot 7090609 at redhat dot com> <CAFiYyc2UTgHd-XmHmMxU-mAQq_q=CXpTZiRZRdKECzGYTzrUSg at mail dot gmail dot com>
On 03/09/15 05:40, Richard Biener wrote:
Dunno. The RTL jump optimizer ought to eliminate the unnecessary
jumping late in the optimization pipeline and creating the forwarder
allows us to put the loop into a "more canonical" form for the loop
optimizers. Seems like it'd be worth some experimentation.
On Sun, Mar 8, 2015 at 8:49 PM, Jeff Law <email@example.com> wrote:
On 03/08/15 12:13, Richard Biener wrote:
I see. This basically creates two loop latches and thus will make our
loop detection code turn the loop into a fake loop nest. Not sure if that
is a good idea.
I'd have to sit down and ponder this for a while -- what would be the
register pressure implications of duplicating the contents of the join block
into its predecessors, leaving an empty joiner so that we still have a
Good question. Now another question is why we don't choose this
way to disambiguate loops with multiple latches? (create a forwarder
as new single latch block)
I'm having trouble seeing how Ajit's proposal helps reduce register
pressure in any significant way except perhaps by exposing partially
dead code. And if that's the primary benefit, we may better off
actually building a proper framework for PDCE.
I've often pondered if PDCE is really worth it. There's some good PLDI
papers from many years ago. One is closely related to our RTL GCSE
implementation (Knoop). But RTL seems the wrong place to be doing this.
Click's GCM/GVN can achieve similar results by the nature of code motion
algorithm IIRC, but as much as I like Click's algorithm, I wasn't ever
able to get it to do anything significantly better than existing bits in