This is the mail archive of the
mailing list for the GCC project.
Re: Higher level RTL issues
- To: law at redhat dot com
- Subject: Re: Higher level RTL issues
- From: Daniel Berlin <dan at cgsoftware dot com>
- Date: Mon, 22 Oct 2001 10:49:21 -0400
- Cc: gcc at gcc dot gnu dot org
On Monday, October 22, 2001, at 12:34 PM, firstname.lastname@example.org wrote:
> In message <071E8F7C-C4E4-11D5-B9EF-0030657B5340@cgsoftware.com>you
>> <snip the rest, for various reasons, i'm not going to reply>
>>> I'll have to show you an example where you do need renaming to perform
>>> relatively simple redundancy elimination problems that are found by
>>> reasonable value numbering scheme.
>> Please, do.
> I'm going to try to get it to y'all today.
From the thread, bob morgan says: " However, other
transformations, such as eliminating copy operations, can cause two
variants of the same register to be live at the same time. In that
case the easy thing to do is to actually rename the registers as new
I'll take his word for it.
However, note that he says the "easy" thing.
He doesn't say it's impossible.
*If* two variants of the same register became live at the same time,
It's a matter of updating definitions in the case of FUD chains, while
you usually can get away with doing nothing in explicitly renamed ssa
Of course, what *we* should do, if we only had to select one thing, (in
terms of renaming or fud chains) depends on which type of problem we
have more, forwards or backwards.
I'd rather *allow* us to do both.
If part of the point of the SSA path is to be fast and efficient, and
cut down the amount of rtl we have to deal with in later, slower,
passes, then what makes most sense is something like:
Convert to FUD chains
SSA-CCP (including simple dead-code removal)
<other ssa optimizations that are faster or easier on fud chains>
Convert to explict renamed form
<Other SSA optimizations that are faster or easier with renaming>
This is because fud-chains are going to be faster to work with for
things that remove a lot of code quickly. For instance, while SSA-CCP on
explicit renamed form will require up to two evaluations per operand of
an operation, on fud-chains, you can guarantee to evaluate each thing