This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Ada and the TREE_COMPLEXITY field on struct tree_exp


> Ada is the last user of the tree_exp->complexity field.  Removing
> this field should reduce GCC's memory usage by about 5% on a 64 bit
> host.  Could an Ada maintainer see if it possible to remove the use
> of this field?  I would think it shouldn't be too hard --
> TREE_COMPLEXITY is used only inside ada/decl.c.  But I haven't been
> able to figure out myself yet how to avoid using TREE_COMPLEXITY there...

It's just being used as a cache to avoid recomputing a value.  My
suggestion would be to replace it with a hash table. It'll tend to keep nodes
around a little more than usual, but that should be a tiny cost.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]