gcc-patches@gcc.gnu.org
[Top] [All Lists]

Re: [patch] Fix regression (Re: Fix PR tree-optimization/41857)

Subject: Re: [patch] Fix regression Re: Fix PR tree-optimization/41857
From: Zdenek Dvorak
Date: Tue, 17 Nov 2009 17:47:11 +0100
Hi,

> >> >> > Tested on s390-ibm-linux and spu-elf with no regressions.
> >> >> > OK for mainline?
> >> >>
> >> >> Ugh.  Well, good enough for now :(
> >> >>
> >> >> I think TMR is broken as it basically treats the base pointer
> >> >> as "value" compared to everywhere else where pointers have
> >> >> semantics attached (like target type, ref-all status, etc.).
> >> >
> >> > I think you paint TMRs too much evil.  It's whole point is to be
> >> > a lower-level representation of memory access, corresponding to
> >> > the addressing modes available on the target.  Thus, you should
> >> > expect to lose some information in the lowering.
> >>
> >> But then why try so hard and preserve TMR_ORIGINAL at all?
> >
> > because alias analysis uses it.  Of course, another option would be to 
> > throw it
> > away completely and use some safe default.  A better option would be to 
> > have a
> > representation of alias analysis information that would be independent on 
> > the
> > shape of the memory reference.
> 
> We do have that now ...

well, almost.  get_alias_set still seems to rely quite heavily on the memory 
reference
shape, which seems to be the only serious reason for keeping TMR_ORIGINAL at 
the moment
(other places where TMR_ORIGINAL are used are tree_could_trap_p, which could be 
solved
easily by adding a flag to TMR),

Zdenek

<Prev in Thread] Current Thread [Next in Thread>