This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [tree-ssa] reaching def. question


Hello,

>  >On Tue, 2004-03-16 at 18:42, law@redhat.com wrote:
>  >
>  >> It seems to me that to do that he must first take the affected variables
>  >> out of SSA form.  Otherwise how does the renamer know which instance of
>  >> "a" ought to be used?
>  >> 
>  >If you mark a _DECL to be renamed, the renamer itself strips the
>  >SSA_NAME wrappers.
> Which is not a safe thing to do if you've done things like copy propagation
> since you can have overlapping lifetimes.
> 
> You also have to be damn careful about marking something to be rewritten
> which is used in a mixed PHI node.  ie
> 
> a_3 = PHI (a_2, b_1)
> 
> Marking just a or b to be written is a recipe for disaster.
> 
> 
>  > Or you mean *really* taking the variable out of SSA form?
> If you've done things like copy propagation and the like, then yes,  you
> really need to take it out of SSA form.

I have thought about this issue for some time -- would not it be better
to do ssa rewriting over ssa names, thus not requiring the rewrite out
of ssa? I.e. to allow the ssa name temporarily have several definitions,
and do rewriting just over them?  It might be faster.  It also would not
need to do rewriting out of ssa, which may require you to insert new
assignments that must be later optimized out.  It would also allow you
not to lose ssa name tags in the process.

Zdenek


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]