This is the mail archive of the gcc-patches@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] fix opt/13798


> > Consider two inline copies of the same function sharing same static
> > variable where we optimized out the address taking operand in one but
> > fialed to do so in the other.
> 
> If TREE_ADDRESSABLE on the variable declaration is cleared even though the
> variable is still addressed by one or more copies of the function, I would
> consider this a bug.

I see, I missed the test of TREE_ADDRESSABLE.
So you are checking that the variable is function local scope && it's
address has not been taken
and conclude from that the fact that it can not be accessed indirectly.

Why do you need the function local scope part of the conditional?  It
seems to me that same information hold for any global static variable.

Honza


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