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] must-alias analysis


On Mon, 14 Jul 2003 11:31:19 -0400, Nathanael Nerode <neroden@twcny.rr.com> wrote:

> Diego said:
>>We currently do not propagate ADDR_EXPR values that have been type
>>casted.  So, things like 'PTR = (type *)&VAR' are not propagated.  The
>>problem with this is that we would need to fold instances of *PTR into
>>(type)VAR, which would produce non-GIMPLE code and confuse the
>>optimizers. 
>
> This may be dumb, but could we get by with, for instance:
> VAR.1 = (type)VAR;
> and then fold *PTR into (VAR.1) ?  Seems simple enough.  :-)

No, that does a conversion; *(type*)&VAR does type punning.

Jason


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