[tree-ssa, mainline] Fix nested inlining

Jan Hubicka hubicka@ucw.cz
Sat Oct 18 20:37:00 GMT 2003


> On Oct 18, 2003, Jan Hubicka <hubicka@ucw.cz> wrote:
> 
> > -   DECL_ABSTRACT_ORIGIN (copy) = DECL_ORIGIN (decl);
>   
> > +   if (DECL_ABSTRACT_ORIGIN (decl))
> > +     DECL_ABSTRACT_ORIGIN (copy) = DECL_ABSTRACT_ORIGIN (decl);
> > +   else
> > +     DECL_ABSTRACT_ORIGIN (copy) = DECL_ORIGIN (decl);
>   
> 
> Err...  Given the definition of DECL_ORIGIN, I don't see how you
> change could make sense.  For reference:
> 
> #define DECL_ORIGIN(NODE) \
>   (DECL_ABSTRACT_ORIGIN (NODE) ? DECL_ABSTRACT_ORIGIN (NODE) : (NODE))
> 
> I.e., you're essentially turning:
> 
> DECL_ABSTRACT_ORIGIN (copy) =
>   (DECL_ABSTRACT_ORIGIN (decl) ? DECL_ABSTRACT_ORIGIN (decl) : (decl));
> 
> into
> 
> if (DECL_ABSTRACT_ORIGIN (decl))
>   DECL_ABSTRACT_ORIGIN (copy) = DECL_ABSTRACT_ORIGIN (decl);
> else
>   DECL_ABSTRACT_ORIGIN (copy) =
>     (DECL_ABSTRACT_ORIGIN (decl) ? DECL_ABSTRACT_ORIGIN (decl) : (decl));
> 
> that simplifies to:
> 
> if (DECL_ABSTRACT_ORIGIN (decl))
>   DECL_ABSTRACT_ORIGIN (copy) = DECL_ABSTRACT_ORIGIN (decl);
> else
>   DECL_ABSTRACT_ORIGIN (copy) = (decl);
> 
> and then to
> 
> DECL_ABSTRACT_ORIGIN (copy) =
>   (DECL_ABSTRACT_ORIGIN (decl) ? DECL_ABSTRACT_ORIGIN (decl) : (decl));
> 
> which is the original definition.  How can this patch possibly bring
> any improvements?

Hmm, I see, I made the patch together with the other change and it made
the strange trees to go away.  I will revert this patch then.

Honza
> 
> -- 
> Alexandre Oliva   Enjoy Guarana', see http://www.ic.unicamp.br/~oliva/
> Red Hat GCC Developer                 aoliva@{redhat.com, gcc.gnu.org}
> CS PhD student at IC-Unicamp        oliva@{lsd.ic.unicamp.br, gnu.org}
> Free Software Evangelist                Professional serial bug killer



More information about the Gcc-patches mailing list