This is the mail archive of the
gcc-regression@gcc.gnu.org
mailing list for the GCC project.
A recent patch decreased GCC's memory consumption.
- From: gcctest at suse dot de
- To: jh at suse dot cz, gcc-regression at gcc dot gnu dot org
- Date: Tue, 19 Jul 2005 20:35:42 +0000
- Subject: A recent patch decreased GCC's memory consumption.
Hi,
I am a friendly script caring about memory consumption in GCC. Please
contact jh@suse.cz if something is going wrong.
Comparing memory consumption on compilation of combine.i, insn-attrtab.i,
and generate-3.4.ii I got:
comparing combine.c compilation at -O0 level:
Overall memory needed: 24641k -> 24637k
Peak memory use before GGC: 9586k
Peak memory use after GGC: 8934k
Maximum of released memory in single GGC run: 2754k
Garbage: 41358k
Leak: 6696k
Overhead: 5818k
GGC runs: 321
comparing combine.c compilation at -O1 level:
Overall memory needed: 26808k
Peak memory use before GGC: 17359k
Peak memory use after GGC: 17170k
Maximum of released memory in single GGC run: 2402k
Garbage: 66308k
Leak: 7186k
Overhead: 7737k
GGC runs: 415
comparing combine.c compilation at -O2 level:
Overall memory needed: 26808k
Peak memory use before GGC: 17360k
Peak memory use after GGC: 17170k
Maximum of released memory in single GGC run: 2503k
Garbage: 84750k
Leak: 7426k
Overhead: 10298k
GGC runs: 482
comparing combine.c compilation at -O3 level:
Ovarall memory allocated via mmap and sbrk decreased from 27916k to 26808k, overall -4.13%
Peak amount of GGC memory allocated before garbage collecting run decreased from 18805k to 17609k, overall -6.79%
Amount of produced GGC garbage decreased from 127918k to 115642k, overall -10.62%
Amount of memory still referenced at the end of compilation decreased from 7803k to 7496k, overall -4.09%
Overall memory needed: 27916k -> 26808k
Peak memory use before GGC: 18805k -> 17609k
Peak memory use after GGC: 17170k
Maximum of released memory in single GGC run: 5454k -> 3332k
Garbage: 127918k -> 115642k
Leak: 7803k -> 7496k
Overhead: 14863k -> 13503k
GGC runs: 535 -> 534
comparing insn-attrtab.c compilation at -O0 level:
Overall memory needed: 81640k
Peak memory use before GGC: 70259k
Peak memory use after GGC: 44999k
Maximum of released memory in single GGC run: 37046k
Garbage: 149918k
Leak: 11332k
Overhead: 19106k
GGC runs: 254
comparing insn-attrtab.c compilation at -O1 level:
Overall memory needed: 114904k -> 114504k
Peak memory use before GGC: 96260k
Peak memory use after GGC: 85581k
Maximum of released memory in single GGC run: 32777k
Garbage: 295377k
Leak: 11556k
Overhead: 36053k
GGC runs: 251
comparing insn-attrtab.c compilation at -O2 level:
Overall memory needed: 125220k
Peak memory use before GGC: 115308k
Peak memory use after GGC: 85547k
Maximum of released memory in single GGC run: 32461k
Garbage: 381553k
Leak: 11670k
Overhead: 47864k
GGC runs: 280
comparing insn-attrtab.c compilation at -O3 level:
Overall memory needed: 125236k
Peak memory use before GGC: 115331k -> 115333k
Peak memory use after GGC: 85570k -> 85572k
Maximum of released memory in single GGC run: 32787k -> 32774k
Garbage: 382209k -> 382072k
Leak: 11692k -> 11686k
Overhead: 47930k -> 47917k
GGC runs: 283 -> 282
comparing Gerald's testcase PR8361 compilation at -O0 level:
Overall memory needed: 118624k
Peak memory use before GGC: 95333k
Peak memory use after GGC: 94386k
Maximum of released memory in single GGC run: 20160k
Garbage: 224282k
Leak: 49424k
Overhead: 36953k
GGC runs: 341
comparing Gerald's testcase PR8361 compilation at -O1 level:
Overall memory needed: 106072k
Peak memory use before GGC: 94843k
Peak memory use after GGC: 93892k
Maximum of released memory in single GGC run: 19796k
Garbage: 597266k
Leak: 55674k
Overhead: 69424k
GGC runs: 521
comparing Gerald's testcase PR8361 compilation at -O2 level:
Overall memory needed: 106064k
Peak memory use before GGC: 94843k
Peak memory use after GGC: 93893k
Maximum of released memory in single GGC run: 19796k
Garbage: 679910k
Leak: 56611k
Overhead: 80631k
GGC runs: 584
comparing Gerald's testcase PR8361 compilation at -O3 level:
Overall memory needed: 108464k
Peak memory use before GGC: 95603k
Peak memory use after GGC: 94656k
Maximum of released memory in single GGC run: 19694k
Garbage: 726345k -> 726348k
Leak: 56846k -> 56843k
Overhead: 84354k -> 84354k
GGC runs: 592
Head of the ChangeLog is:
--- /usr/src/SpecTests/sandbox-britten-memory/x86_64/mem-result/ChangeLog 2005-07-19 14:55:06.000000000 +0000
+++ /usr/src/SpecTests/sandbox-britten-memory/gcc/gcc/ChangeLog 2005-07-19 19:28:59.000000000 +0000
@@ -1,3 +1,15 @@
+2005-07-19 Danny Berlin <dberlin@dberlin.org>
+ Kenneth Zadeck <zadeck@naturalbridge.com>
+
+ * Makefile.in: Removed tree-promote-statics.c
+ * tree-promote-statics.c: Removed.
+ * common.opt: Removed flag-promote-statics.
+ * opts.c: Ditto.
+ * passes.c: Removed tree-promote-statics pass.
+ * tree-pass.h: Ditto.
+ * timevar.def: Removed TV_PROMOTE_STATICS.
+
+
2005-07-19 Gerald Pfeifer <gerald@pfeifer.com>
* config.gcc: Add support for *-*-freebsd7, *-*-freebsd8,
@@ -24,6 +36,11 @@
* config/i386/i386.md (lrint<mode>2): Use temporary
instead of clobbering non-existent memory.
+2005-07-19 Nick Clifton <nickc@redhat.com>
+
+ * config/avr/avr.c (legitimate_address_p): Fix debugging print
+ statement to avoid displaying ASCII control characters.
+
2005-07-19 Ben Elliston <bje@au.ibm.com>
* bt-load.c (link_btr_uses): Fix uninitialised warnings.
The results can be reproduced by building a compiler with
--enable-gather-detailed-mem-stats targetting x86-64
and compiling preprocessed combine.c or testcase from PR8632 with:
-fmem-report --param=ggc-min-heapsize=1024 --param=ggc-min-expand=1 -Ox -Q
The memory consumption summary appears in the dump after detailed listing
of the places they are allocated in. Peak memory consumption is actually
computed by looking for maximal value in {GC XXXX -> YYYY} report.
Your testing script.