Lazy allocation of DECL_ASSEMBLER_NAME

Mark Mitchell mark@codesourcery.com
Mon Mar 1 20:27:00 GMT 2004


>I will try to look into it, but last time I tried to do so, both C and
>C++ frontends was creating separate declarations for local declarations,
>  
>
If so, those are bugs -- or cases where the front ends really wants you 
to think of those as seaparate objects.

>forward declarations and such, so single function got many DECLs.
>Also we can't hash directly the addresses as the hashtable is saved into
>PCH headers, so I am unsure about better sollution to the hashing.
>I need at least one entity that is stable across PCH and multiple
>declarations...
>  
>
Use DECL_UID.

But, really, someone should just fix PCH to do the obvious pointer 
swizzling and/or hash-table rebuilds.  It's silly to be inventing new 
uniquifiers, computing them, filling up memory with them, etc., in lots 
of places when we could just fix the PCH machinery.

-- 
Mark Mitchell
CodeSourcery, LLC
(916) 791-8304
mark@codesourcery.com



More information about the Gcc mailing list