This is the mail archive of the
gcc-regression@gcc.gnu.org
mailing list for the GCC project.
GCC memory consumption increased by recent patch!
- From: gcctest at suse dot de
- To: jh at suse dot cz, gcc-regression at gcc dot gnu dot org
- Date: Wed, 02 Mar 2005 16:38:20 +0000
- Subject: GCC memory consumption increased by recent patch!
Hi,
Comparing memory consumption on compilation of combine.i and generate-3.4.ii I got:
comparing combine.c compilation at -O0 level:
Overall memory needed: 24657k -> 24665k
Peak memory use before GGC: 9359k
Peak memory use after GGC: 8673k
Maximum of released memory in single GGC run: 2863k -> 2865k
Garbage: 41652k -> 41675k
Leak: 6411k -> 6395k
Overhead: 5772k -> 5772k
GGC runs: 327
comparing combine.c compilation at -O1 level:
Overall memory needed: 24497k -> 24489k
Peak memory use before GGC: 8673k
Peak memory use after GGC: 8093k
Maximum of released memory in single GGC run: 2026k
Garbage: 58477k -> 58507k
Leak: 6755k -> 6756k
Overhead: 9891k -> 9891k
GGC runs: 500
comparing combine.c compilation at -O2 level:
Overall memory needed: 29141k -> 29145k
Peak memory use before GGC: 12670k -> 12671k
Peak memory use after GGC: 12544k
Maximum of released memory in single GGC run: 2596k
Garbage: 77968k -> 77998k
Leak: 6593k
Overhead: 14177k -> 14177k
GGC runs: 516 -> 515
comparing combine.c compilation at -O3 level:
Overall memory needed: 30805k -> 30881k
Peak memory use before GGC: 12773k -> 12680k
Peak memory use after GGC: 12544k
Maximum of released memory in single GGC run: 3426k -> 3427k
Garbage: 105124k -> 105184k
Leak: 7199k -> 7180k
Overhead: 18996k -> 18999k
GGC runs: 579 -> 581
comparing insn-attrtab.c compilation at -O0 level:
Amount of produced GGC garbage increased from 152667k to 152830k, overall 0.11%
Overall memory needed: 114136k -> 114212k
Peak memory use before GGC: 74747k -> 74821k
Peak memory use after GGC: 45494k
Maximum of released memory in single GGC run: 39340k -> 39413k
Garbage: 152667k -> 152830k
Leak: 10984k -> 10984k
Overhead: 19970k
GGC runs: 274 -> 273
comparing insn-attrtab.c compilation at -O1 level:
Overall memory needed: 124660k -> 124600k
Peak memory use before GGC: 78641k
Peak memory use after GGC: 70035k -> 70036k
Maximum of released memory in single GGC run: 40780k -> 40782k
Garbage: 369105k -> 369270k
Leak: 11361k -> 11361k
Overhead: 71894k -> 71894k
GGC runs: 398
comparing insn-attrtab.c compilation at -O2 level:
Overall memory needed: 149180k -> 147452k
Peak memory use before GGC: 97607k -> 97678k
Peak memory use after GGC: 83426k -> 83497k
Maximum of released memory in single GGC run: 39384k -> 39453k
Garbage: 482929k -> 483091k
Leak: 11250k
Overhead: 86927k -> 86926k
GGC runs: 341
comparing insn-attrtab.c compilation at -O3 level:
Overall memory needed: 149196k -> 148932k
Peak memory use before GGC: 97609k -> 97679k
Peak memory use after GGC: 83428k -> 83499k
Maximum of released memory in single GGC run: 39384k -> 39453k
Garbage: 483744k -> 483905k
Leak: 11287k
Overhead: 87058k -> 87057k
GGC runs: 347
comparing Gerald's testcase PR8361 compilation at -O0 level:
Peak amount of GGC memory allocated before garbage collecting increased from 87161k to 87325k, overall 0.19%
Overall memory needed: 111060k -> 111952k
Peak memory use before GGC: 87161k -> 87325k
Peak memory use after GGC: 85900k
Maximum of released memory in single GGC run: 19511k
Garbage: 246197k -> 246370k
Leak: 55513k
Overhead: 43275k -> 43275k
GGC runs: 366
comparing Gerald's testcase PR8361 compilation at -O1 level:
Peak amount of GGC memory allocated before garbage collecting increased from 86019k to 86183k, overall 0.19%
Amount of produced GGC garbage increased from 434149k to 434991k, overall 0.19%
Overall memory needed: 103929k -> 104033k
Peak memory use before GGC: 86019k -> 86183k
Peak memory use after GGC: 85119k
Maximum of released memory in single GGC run: 18950k
Garbage: 434149k -> 434991k
Leak: 56856k -> 56864k
Overhead: 65163k -> 65164k
GGC runs: 512
comparing Gerald's testcase PR8361 compilation at -O2 level:
Peak amount of GGC memory allocated before garbage collecting increased from 86019k to 86184k, overall 0.19%
Amount of produced GGC garbage increased from 477342k to 478256k, overall 0.19%
Overall memory needed: 104137k -> 104249k
Peak memory use before GGC: 86019k -> 86184k
Peak memory use after GGC: 85119k
Maximum of released memory in single GGC run: 18950k -> 18951k
Garbage: 477342k -> 478256k
Leak: 57432k
Overhead: 75173k -> 75179k
GGC runs: 569 -> 571
comparing Gerald's testcase PR8361 compilation at -O3 level:
Peak amount of GGC memory allocated before garbage collecting increased from 87156k to 87323k, overall 0.19%
Amount of produced GGC garbage increased from 482571k to 483490k, overall 0.19%
Overall memory needed: 105213k -> 105349k
Peak memory use before GGC: 87156k -> 87323k
Peak memory use after GGC: 86199k
Maximum of released memory in single GGC run: 19400k
Garbage: 482571k -> 483490k
Leak: 57613k
Overhead: 75880k -> 75879k
GGC runs: 559 -> 558
Head of changelog is:
--- /usr/src/SpecTests/sandbox-britten-memory/x86_64/mem-result/ChangeLog 2005-03-02 06:26:04.000000000 +0000
+++ /usr/src/SpecTests/sandbox-britten-memory/gcc/gcc/ChangeLog 2005-03-02 15:37:51.000000000 +0000
@@ -1,3 +1,31 @@
+2005-03-02 Kazu Hirata <kazu@cs.umass.edu>
+
+ * cfgloop.h, cfgloopanal.c, cfgloopmanip.c, conflict.c,
+ loop-init.c, loop-unroll.c, print-tree.c, reg-notes.def,
+ config/m68k/m68k.c, config/mips/mips.h,
+ config/rs6000/rs6000-protos.h, doc/contrib.texi,
+ doc/include/gcc-common.texi: Update copyright.
+
+2005-03-02 Richard Guenther <rguenth@gcc.gnu.org>
+
+ * cgraph.h (struct cgraph_edge): Add prev_caller and
+ prev_callee fields.
+ (cgraph_node_remove_callees): Export.
+ * cgraph.c (cgraph_create_edge): Initialize prev_caller
+ and prev_callee.
+ (cgraph_edge_remove_callee): New function.
+ (cgraph_edge_remove_caller): Likewise.
+ (cgraph_remove_edge): Use.
+ (cgraph_redirect_edge_callee): Likewise.
+ (cgraph_node_remove_callees): New function.
+ (cgraph_node_remove_callers): Likewise.
+ (cgraph_remove_node): Use.
+ * tree-optimize.c (tree_rest_of_compilation): Use
+ cgraph_node_remove_callees instead of manual loop.
+ * cgraphunit.c (cgraph_finalize_function): Likewise.
+ (cgraph_expand_function): Likewise.
+ (cgraph_remove_unreachable_nodes): Likewise.
+
2005-03-02 Joseph S. Myers <joseph@codesourcery.com>
PR c/8927
I am friendly script caring about memory consumption in GCC. Please contact
jh@suse.cz if something is going wrong.
The results can be reproduced by building 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.
Yours testing script.