Lazy allocation of DECL_ASSEMBLER_NAME
Geoff Keating
geoffk@geoffk.org
Mon Mar 1 21:19:00 GMT 2004
Mark Mitchell <mark@codesourcery.com> writes:
> >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.
You'll want to be doing some benchmarks before committing to one
approach...
--
- Geoffrey Keating <geoffk@geoffk.org>
More information about the Gcc
mailing list