This is the mail archive of the
mailing list for the GCC project.
Re: Unintended variable renaming in SSA replacement table
- From: Jeff Law <law at redhat dot com>
- To: Benedikt Huber <benedikt dot huber at theobroma-systems dot com>
- Cc: GCC Development <gcc at gcc dot gnu dot org>
- Date: Tue, 17 Mar 2015 13:10:45 -0600
- Subject: Re: Unintended variable renaming in SSA replacement table
- Authentication-results: sourceware.org; auth=none
- References: <39F92F64-9F54-4FC5-BA88-78B02396092C at theobroma-systems dot com> <5508718A dot 1030006 at redhat dot com> <586565C1-2156-4708-8F91-6C7B64A841A1 at theobroma-systems dot com>
On 03/17/2015 12:54 PM, Benedikt Huber wrote:
Because uses that are reached by the new names obviously have to get
updated. The SSA updater is supposed to relieve passes from the burden
of trying to figure out how to handle updates on their own. You copy
the blocks, update your cfg, remove unreachables, then let the ssa
updater handle updating the ssa graph.
Thank you for the answer.
I made sure that each variable is only assigned exactly once.
duplicate_block already generates new names for all lhs.
After that I edited all rhs to the uses I wanted for the unrolling,
so SSA-form should still be intact.
What I do not understand is: Why does gcc change the names on the rhs?
If you're using the block copier, but doing your own updates, then
you'll need some kind of hack to avoid the standard update mechanisms.
I'm not immediately aware of a "blessed" way to do that. You'll need to
hack somethign up.