GCC memory consumption increased by recent patch!
gcctest@suse.de
gcctest@suse.de
Mon Sep 27 06:40:00 GMT 2004
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 allocated via mmap and sbrk increased from 24169k to 24725k, overall 2.30%
Overall memory needed: 24169k -> 24725k
Peak memory use before GGC: 9296k
Peak memory use after GGC: 8607k
Maximum of released memory in single GGC run: 2870k
Garbage: 42629k -> 42621k
Leak: 6090k
Overhead: 5588k -> 5587k
GGC runs: 363
comparing combine.c compilation at -O1 level:
Overall memory allocated via mmap and sbrk increased from 25629k to 26609k, overall 3.82%
Overall memory needed: 25629k -> 26609k
Peak memory use before GGC: 9377k
Peak memory use after GGC: 8800k
Maximum of released memory in single GGC run: 2031k
Garbage: 69180k -> 69182k
Leak: 6674k
Overhead: 11094k -> 11094k
GGC runs: 575
comparing combine.c compilation at -O2 level:
Overall memory allocated via mmap and sbrk increased from 28929k to 29873k, overall 3.26%
Overall memory needed: 28929k -> 29873k
Peak memory use before GGC: 12772k
Peak memory use after GGC: 12613k
Maximum of released memory in single GGC run: 2525k
Garbage: 84273k -> 84266k
Leak: 6428k
Overhead: 15636k -> 15636k
GGC runs: 571
comparing combine.c compilation at -O3 level:
Overall memory allocated via mmap and sbrk increased from 20544k to 21484k, overall 4.58%
Overall memory needed: 20544k -> 21484k
Peak memory use before GGC: 13044k
Peak memory use after GGC: 12692k
Maximum of released memory in single GGC run: 3362k
Garbage: 112175k -> 112213k
Leak: 6929k
Overhead: 20684k -> 20684k
GGC runs: 637
comparing insn-attrtab.c compilation at -O0 level:
Overall memory needed: 116476k
Peak memory use before GGC: 77101k
Peak memory use after GGC: 45186k
Maximum of released memory in single GGC run: 42129k
Garbage: 159505k -> 159508k
Leak: 10645k
Overhead: 19805k -> 19805k
GGC runs: 310 -> 309
comparing insn-attrtab.c compilation at -O1 level:
Overall memory needed: 133084k
Peak memory use before GGC: 93162k
Peak memory use after GGC: 71529k
Maximum of released memory in single GGC run: 41234k
Garbage: 453085k
Leak: 11078k
Overhead: 73707k
GGC runs: 461
comparing insn-attrtab.c compilation at -O2 level:
Overall memory needed: 207744k -> 207748k
Peak memory use before GGC: 108725k -> 108721k
Peak memory use after GGC: 87092k -> 87088k
Maximum of released memory in single GGC run: 34490k
Garbage: 502447k -> 502463k
Leak: 11218k -> 11210k
Overhead: 83073k -> 83073k
GGC runs: 384
comparing insn-attrtab.c compilation at -O3 level:
Overall memory needed: 207736k -> 207748k
Peak memory use before GGC: 108726k
Peak memory use after GGC: 87093k
Maximum of released memory in single GGC run: 34491k
Garbage: 503617k -> 503615k
Leak: 11256k
Overhead: 83469k -> 83469k
GGC runs: 393
comparing Gerald's testcase PR8361 compilation at -O0 level:
Overall memory needed: 115352k
Peak memory use before GGC: 92231k
Peak memory use after GGC: 90025k
Maximum of released memory in single GGC run: 20139k
Garbage: 265688k -> 265690k
Leak: 60277k
Overhead: 47198k -> 47198k
GGC runs: 378
comparing Gerald's testcase PR8361 compilation at -O1 level:
Overall memory allocated via mmap and sbrk increased from 109352k to 110012k, overall 0.60%
Overall memory needed: 109352k -> 110012k
Peak memory use before GGC: 95751k
Peak memory use after GGC: 88883k
Maximum of released memory in single GGC run: 19570k
Garbage: 594412k -> 594419k
Leak: 62357k
Overhead: 131026k -> 131027k
GGC runs: 605
comparing Gerald's testcase PR8361 compilation at -O2 level:
Overall memory needed: 110316k
Peak memory use before GGC: 95751k
Peak memory use after GGC: 88883k
Maximum of released memory in single GGC run: 19569k
Garbage: 647298k -> 647294k
Leak: 62912k
Overhead: 154285k -> 154281k
GGC runs: 638
comparing Gerald's testcase PR8361 compilation at -O3 level:
Overall memory needed: 108016k -> 107972k
Peak memory use before GGC: 91613k
Peak memory use after GGC: 90197k
Maximum of released memory in single GGC run: 20253k
Garbage: 682715k -> 682659k
Leak: 63333k -> 63341k
Overhead: 163435k -> 163434k
GGC runs: 626
Head of changelog is:
--- /usr/src/SpecTests/sandbox-britten-memory/x86_64/mem-result/ChangeLog 2004-09-27 00:57:09.000000000 +0000
+++ /usr/src/SpecTests/sandbox-britten-memory/gcc/gcc/ChangeLog 2004-09-27 05:31:17.000000000 +0000
@@ -1,3 +1,8 @@
+2004-09-26 Matt Austern <austern@apple.com>
+
+ * ggc-page.c (GGC_QUIRE_SIZE): Bump up from 16 to 256 if we're
+ using mmap.
+
2004-09-26 Zdenek Dvorak <rakdver@atrey.karlin.mff.cuni.cz>
* bitmap.h (EXECUTE_IF_SET_IN_BITMAP, EXECUTE_IF_AND_COMPL_IN_BITMAP,
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.
More information about the Gcc-regression
mailing list