Patch: gcj ggc patch

Zack Weinberg zack@codesourcery.com
Wed Mar 6 23:15:00 GMT 2002


On Wed, Mar 06, 2002 at 10:58:18PM -0800, Per Bothner wrote:
> 
> This is a specification issue of the semantics of identifier
> nodes, and there should be a clear answer:  Can an identifier,
> once it has been created, ever be garbage collected?

The whole point of the stringpool code was to make IDENTIFIER_NODEs
permanently allocated, so that we need not bother to mark them.
Before, something like 2% of runtime on large C++ test cases was being
wasted repeatedly looking up the page entries for identifiers.

There are two nuances here:

- IDENTIFIER_NODEs must always be allocated through get_identifier,
not make_node or whatever.

- The trees stored in struct lang_identifier do need to be marked and
swept; this is taken care of by lang_mark_tree.

zw



More information about the Gcc-patches mailing list