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, 08 Dec 2004 07:10:45 +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: 25329k -> 25265k
Peak memory use before GGC: 9329k -> 9310k
Peak memory use after GGC: 8641k -> 8624k
Maximum of released memory in single GGC run: 2926k -> 2912k
Garbage: 42601k -> 42434k
Leak: 6087k -> 6088k
Overhead: 5743k -> 5717k
GGC runs: 354
comparing combine.c compilation at -O1 level:
Overall memory needed: 26145k -> 26169k
Peak memory use before GGC: 9201k -> 9199k
Peak memory use after GGC: 8723k
Maximum of released memory in single GGC run: 2063k -> 2062k
Garbage: 68067k -> 67984k
Leak: 6484k -> 6484k
Overhead: 10671k -> 10665k
GGC runs: 547 -> 546
comparing combine.c compilation at -O2 level:
Overall memory needed: 29993k -> 29957k
Peak memory use before GGC: 12705k
Peak memory use after GGC: 12578k
Maximum of released memory in single GGC run: 2575k -> 2574k
Garbage: 82364k -> 82177k
Leak: 6305k -> 6299k
Overhead: 14872k -> 14822k
GGC runs: 549 -> 548
comparing combine.c compilation at -O3 level:
Overall memory allocated via mmap and sbrk increased from 20764k to 20804k, overall 0.19%
Overall memory needed: 20764k -> 20804k
Peak memory use before GGC: 12987k
Peak memory use after GGC: 12578k
Maximum of released memory in single GGC run: 3412k -> 3411k
Garbage: 111191k -> 111098k
Leak: 6832k -> 6832k
Overhead: 19887k -> 19898k
GGC runs: 615 -> 616
comparing insn-attrtab.c compilation at -O0 level:
Overall memory needed: 118468k
Peak memory use before GGC: 79386k
Peak memory use after GGC: 46137k
Maximum of released memory in single GGC run: 43335k
Garbage: 162034k -> 161983k
Leak: 10609k
Overhead: 21249k -> 21242k
GGC runs: 295
comparing insn-attrtab.c compilation at -O1 level:
Overall memory needed: 132256k
Peak memory use before GGC: 85238k
Peak memory use after GGC: 70037k
Maximum of released memory in single GGC run: 41132k
Garbage: 449332k -> 449302k
Leak: 10955k
Overhead: 79597k -> 79597k
GGC runs: 429
comparing insn-attrtab.c compilation at -O2 level:
Overall memory needed: 154184k -> 154180k
Peak memory use before GGC: 101254k
Peak memory use after GGC: 85454k
Maximum of released memory in single GGC run: 42175k
Garbage: 496336k -> 496306k
Leak: 10883k -> 10883k
Overhead: 87863k -> 87871k
GGC runs: 363
comparing insn-attrtab.c compilation at -O3 level:
Overall memory needed: 154200k -> 154196k
Peak memory use before GGC: 101255k
Peak memory use after GGC: 85456k
Maximum of released memory in single GGC run: 42175k
Garbage: 497624k -> 497584k
Leak: 10930k -> 10928k
Overhead: 88052k -> 88052k
GGC runs: 371
comparing Gerald's testcase PR8361 compilation at -O0 level:
Overall memory needed: 113252k
Peak memory use before GGC: 89795k
Peak memory use after GGC: 88905k
Maximum of released memory in single GGC run: 19901k
Garbage: 249005k -> 248756k
Leak: 57666k
Overhead: 45421k -> 45379k
GGC runs: 362
comparing Gerald's testcase PR8361 compilation at -O1 level:
Overall memory needed: 95796k
Peak memory use before GGC: 88796k
Peak memory use after GGC: 87822k
Maximum of released memory in single GGC run: 19406k
Garbage: 553631k -> 553002k
Leak: 59700k -> 59700k
Overhead: 115466k -> 115302k
GGC runs: 611
comparing Gerald's testcase PR8361 compilation at -O2 level:
Overall memory needed: 95796k
Peak memory use before GGC: 88796k
Peak memory use after GGC: 87822k
Maximum of released memory in single GGC run: 19405k
Garbage: 602698k -> 601926k
Leak: 60281k -> 60282k
Overhead: 137635k -> 137344k
GGC runs: 655 -> 653
comparing Gerald's testcase PR8361 compilation at -O3 level:
Overall memory needed: 98384k -> 98368k
Peak memory use before GGC: 90197k
Peak memory use after GGC: 88649k
Maximum of released memory in single GGC run: 20099k
Garbage: 642694k -> 642088k
Leak: 60622k -> 60622k
Overhead: 148933k -> 148781k
GGC runs: 647 -> 648
Head of changelog is:
--- /usr/src/SpecTests/sandbox-britten-memory/x86_64/mem-result/ChangeLog 2004-12-08 01:29:17.000000000 +0000
+++ /usr/src/SpecTests/sandbox-britten-memory/gcc/gcc/ChangeLog 2004-12-08 06:05:47.000000000 +0000
@@ -1,3 +1,18 @@
+2004-12-07 Roger Sayle <roger@eyesopen.com>
+
+ PR middle-end/18293
+ * expmed.c (EXACT_POWER_OF_2_OR_ZERO_P): Move definition earlier.
+ (expand_mult): Special case powers of two to avoid synth_mult.
+ * loop.c (product_cheap_p): Handle case where expand_mult does
+ require/generate any instructions (i.e. multiplication by zero).
+
+2004-12-07 Richard Henderson <rth@redhat.com>
+
+ * tree-pretty-print.c (dump_array_domain): Split out from
+ dump_generic_node; fix off-by-one error on zero-based array bounds.
+ (dump_generic_node): Use it.
+ (print_declaration): Likewise.
+
2004-12-08 Richard Guenther <richard.guenther@uni-tuebingen.de>
* doc/invoke.texi: Adjust default values for
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.