This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: [RFC] ignoring type alias conflicts between structures andscalars
- From: Diego Novillo <dnovillo at redhat dot com>
- To: Richard Kenner <kenner at vlsi1 dot ultra dot nyu dot edu>
- Cc: "gcc at gcc dot gnu dot org" <gcc at gcc dot gnu dot org>
- Date: Thu, 25 Nov 2004 16:02:25 -0500
- Subject: Re: [RFC] ignoring type alias conflicts between structures andscalars
- Organization: Red Hat Canada
- References: <10411252103.AA08279@vlsi1.ultra.nyu.edu>
On Thu, 2004-11-25 at 16:03 -0500, Richard Kenner wrote:
> But if we just have a structure reference and a global variable, we
> won't ever have this problem. The aliasing code doesn't look at
> those. It only ever looks at pointers vs addressable variables. It
> doesn't care about other variables.
>
> You lost me. Isn't a global variable an addressable variable?
>
Yes, but if there are no pointers involved, it will never be considered
for aliasing:
int X;
foo()
{
struct int_float_s x = bar();
X = 10;
x.i = 3;
return X;
}
Diego.