Lazy allocation of DECL_ASSEMBLER_NAME

Jan Hubicka jh@suse.cz
Mon Mar 1 20:33: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.

Tricking me that the objects are separate when they are not is a
problem.  The observation about multiple decls is pretty old and Zack
already mentioned that he should've fixed them, so hopefully it will
work.  But definitly the backward inlining didn't work even for trivial
testcases then.
> 
> >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.

OK, I will give it a try and see if it works.  (BTW the situation of
DECL_RTL set is not terribly bad - we create these only for DECLs
finalized and relatively high portion of these gets used,  I used do
have some data for this, but can't find them).

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



More information about the Gcc mailing list