This is the mail archive of the
gcc-regression@gcc.gnu.org
mailing list for the GCC project.
A recent patch increased 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: Sun, 09 Apr 2006 01:29:27 +0000
- Subject: A recent patch increased 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: 25100k
Peak memory use before GGC: 9541k
Peak memory use after GGC: 8897k
Maximum of released memory in single GGC run: 2636k
Garbage: 39800k
Leak: 6735k
Overhead: 5657k
GGC runs: 314
comparing combine.c compilation at -O1 level:
Overall memory needed: 26892k
Peak memory use before GGC: 17430k
Peak memory use after GGC: 17251k
Maximum of released memory in single GGC run: 2302k
Garbage: 60977k -> 60961k
Leak: 6875k
Overhead: 7145k -> 7145k
GGC runs: 384
comparing combine.c compilation at -O2 level:
Overall memory needed: 26892k
Peak memory use before GGC: 17435k
Peak memory use after GGC: 17251k
Maximum of released memory in single GGC run: 2397k
Garbage: 84971k -> 84964k
Leak: 6992k -> 6984k
Overhead: 9831k -> 9831k
GGC runs: 450
comparing combine.c compilation at -O3 level:
Overall memory needed: 25992k
Peak memory use before GGC: 18548k -> 18547k
Peak memory use after GGC: 17843k -> 17842k
Maximum of released memory in single GGC run: 3544k
Garbage: 115911k -> 115908k
Leak: 7083k -> 7083k
Overhead: 13361k -> 13356k
GGC runs: 507
comparing insn-attrtab.c compilation at -O0 level:
Overall memory needed: 80372k
Peak memory use before GGC: 69292k
Peak memory use after GGC: 44790k
Maximum of released memory in single GGC run: 36009k
Garbage: 144206k
Leak: 10127k
Overhead: 19011k
GGC runs: 244
comparing insn-attrtab.c compilation at -O1 level:
Overall memory needed: 105464k
Peak memory use before GGC: 85351k
Peak memory use after GGC: 79199k
Maximum of released memory in single GGC run: 32294k
Garbage: 288186k
Leak: 10068k
Overhead: 33735k
GGC runs: 240
comparing insn-attrtab.c compilation at -O2 level:
Overall memory needed: 107532k -> 107540k
Peak memory use before GGC: 89783k -> 89782k
Peak memory use after GGC: 81656k -> 81655k
Maximum of released memory in single GGC run: 30744k
Garbage: 336898k -> 336894k
Leak: 10050k
Overhead: 41375k -> 41375k
GGC runs: 266
comparing insn-attrtab.c compilation at -O3 level:
Overall memory needed: 107636k -> 107616k
Peak memory use before GGC: 89809k -> 89808k
Peak memory use after GGC: 81683k -> 81681k
Maximum of released memory in single GGC run: 31076k
Garbage: 337514k -> 337509k
Leak: 10054k
Overhead: 41570k -> 41570k
GGC runs: 270
comparing Gerald's testcase PR8361 compilation at -O0 level:
Overall memory needed: 118260k
Peak memory use before GGC: 95027k
Peak memory use after GGC: 94083k
Maximum of released memory in single GGC run: 20342k
Garbage: 222873k
Leak: 49535k
Overhead: 37086k
GGC runs: 368
comparing Gerald's testcase PR8361 compilation at -O1 level:
Overall memory needed: 115852k
Peak memory use before GGC: 97678k
Peak memory use after GGC: 96698k
Maximum of released memory in single GGC run: 18987k
Garbage: 471297k -> 471300k
Leak: 52822k
Overhead: 52713k -> 52712k
GGC runs: 515
comparing Gerald's testcase PR8361 compilation at -O2 level:
Amount of produced GGC garbage increased from 559146k to 560079k, overall 0.17%
Overall memory needed: 115856k
Peak memory use before GGC: 97678k
Peak memory use after GGC: 96699k
Maximum of released memory in single GGC run: 18987k
Garbage: 559146k -> 560079k
Leak: 53716k -> 53714k
Overhead: 61364k -> 61443k
GGC runs: 597
comparing Gerald's testcase PR8361 compilation at -O3 level:
Overall memory needed: 117128k
Peak memory use before GGC: 98973k
Peak memory use after GGC: 97993k
Maximum of released memory in single GGC run: 19240k
Garbage: 580124k -> 579796k
Leak: 54072k -> 54073k
Overhead: 62473k -> 62461k
GGC runs: 605
Head of the ChangeLog is:
--- /usr/src/SpecTests/sandbox-britten-memory/x86_64/mem-result/ChangeLog 2006-04-07 23:15:30.000000000 +0000
+++ /usr/src/SpecTests/sandbox-britten-memory/gcc/gcc/ChangeLog 2006-04-08 21:57:51.000000000 +0000
@@ -1,3 +1,24 @@
+2006-04-08 Daniel Berlin <dberlin@dberlin.org>
+
+ * tree.h (tree_memory_tag): Add old_used_alone.
+ (SMT_OLD_USED_ALONE): New macro.
+ * tree-ssa-alias.c (recalculate_used_alone): Stop
+ marking things for renaming unnecessarily.
+
+2006-04-08 Kazu Hirata <kazu@codesourcery.com>
+
+ * builtins.c, config/arm/arm.c, config/i386/cygwin.h,
+ config/i386/i386.c, config/ia64/ia64.c, config/s390/fixdfdi.h,
+ config/sh/sh.c, config/sh/sh.h, df-scan.c, except.c,
+ haifa-sched.c, optabs.c, rtl.h, sched-deps.c, sched-int.h,
+ sched-rgn.c, tree-inline.h, tree-ssa-dom.c,
+ tree-ssa-loop-prefetch.c, tree-ssa-operands.c,
+ tree-vect-patterns.c, tree-vrp.c: Fix comment typos. Follow
+ spelling convensions.
+ * config/ia64/ia64.opt, doc/contrib.texi, doc/invoke.texi,
+ doc/passes.texi, doc/tm.texi, doc/tree-ssa.texi: Fix comment
+ typos. Follow spelling conventions.
+
2006-04-07 DJ Delorie <dj@redhat.com>
* config/m32c/m32c.c (m32c_function_arg): Structures are always
--- /usr/src/SpecTests/sandbox-britten-memory/x86_64/mem-result/ChangeLog.cp 2006-04-07 01:41:15.000000000 +0000
+++ /usr/src/SpecTests/sandbox-britten-memory/gcc/gcc/cp/ChangeLog 2006-04-08 20:47:03.000000000 +0000
@@ -1,3 +1,7 @@
+2006-04-08 Kazu Hirata <kazu@codesourcery.com>
+
+ * decl2.c, pt.c, semantics.c: Fix comment typos.
+
2006-04-06 Roger Sayle <roger@eyesopen.com>
* call.c (null_ptr_cst_p): Add explicit TREE_CONSTANT_OVERFLOW check.
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.