This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: Yet another DOM memory improvement
- From: Jan Hubicka <hubicka at ucw dot cz>
- To: Jeffrey A Law <law at redhat dot com>
- Cc: gcc-patches at gcc dot gnu dot org
- Date: Wed, 22 Sep 2004 16:55:56 +0200
- Subject: Re: Yet another DOM memory improvement
- References: <1095826282.10950.408.camel@localhost.localdomain>
> In an earlier message I indicated that moving the vrp_data information
> into the SSA_NAME itself probably wasn't that good of an idea. I also
> suggested that a hash table might be a better means to record that
> data since typically it's going to be rather sparse.
>
> This change turns that varray into a hash table per those ideas. The
> memory savings is substantial on the order of many megabytes for
> Gerald's testcase -- even though we have to allocate a two word
> structure for each hash table element (I did my initial measurements
> with those structures in GGC memory, but for the final version I moved
> them into malloc'd memory).
For a record, it is roughly 3.8%, 22MB, but for some reason only at -O3
;) similar savings can be seen on insn-attrtab on all optimization
levels however.
The DOM iteration seems to be pretty expensive thing. Did you
considered trottling it to 1 iteration by -fexpensive-optimizations so
it is disabled for -O1?
thanks,
Honza