This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: your change to tree-sra.c
- From: Diego Novillo <dnovillo at redhat dot com>
- To: Richard Kenner <kenner at vlsi1 dot ultra dot nyu dot edu>
- Cc: Richard Henderson <rth at redhat dot com>, "gcc at gcc dot gnu dot org" <gcc at gcc dot gnu dot org>
- Date: Wed, 07 Jul 2004 10:45:36 -0400
- Subject: Re: your change to tree-sra.c
- Organization: Red Hat Canada
- References: <10407071431.AA05430@vlsi1.ultra.nyu.edu>
On Wed, 2004-07-07 at 10:31, Richard Kenner wrote:
> The case is the Ada front end file osint.adb in the Osint._Elabb routine.
> Look at the assignment _init = osint__P32s;
>
> osint__p32s is a static that has a zero DECL_INITIAL because it's an
> expression that's not a valid initializer. But that does't mean that
> it's zero. Indeed you can see it initialized directly above.
>
Why isn't it a valid initializer? It's not valid GIMPLE?
> But I think it best not to rely on a zero DECL_INITIAL meaning anything.
>
> What do you think?
>
That would be problematic for the optimizers. If a static variable has
a NULL DECL_INITIAL, we assume that it has not been initialized.
I don't think we should give 3 meanings to a binary value. DECL_INITIAL
NULL -> it's not initialize. DECL_INITIAL non-NULL -> it is
initialized. We use this in CCP.
Diego.