This is the mail archive of the gcc-regression@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

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
    Peak memory use before GGC: 9329k
    Peak memory use after GGC: 8641k
    Maximum of released memory in single GGC run: 2926k
    Garbage: 42601k
    Leak: 6088k
    Overhead: 5744k
    GGC runs: 354

comparing combine.c compilation at -O1 level:
    Overall memory needed: 25877k -> 25881k
    Peak memory use before GGC: 9200k -> 9201k
    Peak memory use after GGC: 8722k -> 8723k
    Maximum of released memory in single GGC run: 2063k
    Garbage: 68059k -> 68067k
    Leak: 6485k
    Overhead: 10671k -> 10672k
    GGC runs: 547

comparing combine.c compilation at -O2 level:
    Overall memory needed: 29977k
    Peak memory use before GGC: 12705k
    Peak memory use after GGC: 12578k
    Maximum of released memory in single GGC run: 2575k
    Garbage: 82359k -> 82364k
    Leak: 6305k
    Overhead: 14872k -> 14873k
    GGC runs: 549

comparing combine.c compilation at -O3 level:
  Overall memory allocated via mmap and sbrk increased from 20732k to 20764k, overall 0.15%
    Overall memory needed: 20732k -> 20764k
    Peak memory use before GGC: 12993k -> 12987k
    Peak memory use after GGC: 12578k
    Maximum of released memory in single GGC run: 3412k
    Garbage: 111144k -> 111191k
    Leak: 6833k
    Overhead: 19881k -> 19888k
    GGC runs: 616 -> 615

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
    Leak: 10610k
    Overhead: 21250k
    GGC runs: 295

comparing insn-attrtab.c compilation at -O1 level:
  Overall memory allocated via mmap and sbrk increased from 132096k to 132256k, overall 0.12%
    Overall memory needed: 132096k -> 132256k
    Peak memory use before GGC: 85228k -> 85238k
    Peak memory use after GGC: 70033k -> 70037k
    Maximum of released memory in single GGC run: 41128k -> 41132k
    Garbage: 449315k -> 449332k
    Leak: 10956k
    Overhead: 79591k -> 79598k
    GGC runs: 429

comparing insn-attrtab.c compilation at -O2 level:
    Overall memory needed: 154220k -> 154184k
    Peak memory use before GGC: 101239k -> 101254k
    Peak memory use after GGC: 85446k -> 85454k
    Maximum of released memory in single GGC run: 42306k -> 42175k
    Garbage: 496293k -> 496336k
    Leak: 10876k -> 10884k
    Overhead: 87852k -> 87864k
    GGC runs: 362 -> 363

comparing insn-attrtab.c compilation at -O3 level:
    Overall memory needed: 154224k -> 154200k
    Peak memory use before GGC: 101241k -> 101255k
    Peak memory use after GGC: 85448k -> 85456k
    Maximum of released memory in single GGC run: 42306k -> 42175k
    Garbage: 497581k -> 497624k
    Leak: 10923k -> 10931k
    Overhead: 88040k -> 88052k
    GGC runs: 370 -> 371

comparing Gerald's testcase PR8361 compilation at -O0 level:
    Overall memory needed: 113028k -> 113024k
    Peak memory use before GGC: 89585k
    Peak memory use after GGC: 88693k
    Maximum of released memory in single GGC run: 19771k
    Garbage: 249003k
    Leak: 57281k
    Overhead: 45237k
    GGC runs: 361

comparing Gerald's testcase PR8361 compilation at -O1 level:
    Overall memory needed: 95584k
    Peak memory use before GGC: 88601k
    Peak memory use after GGC: 87616k
    Maximum of released memory in single GGC run: 19411k
    Garbage: 553613k -> 553651k
    Leak: 59314k -> 59317k
    Overhead: 115278k -> 115285k
    GGC runs: 611

comparing Gerald's testcase PR8361 compilation at -O2 level:
    Overall memory needed: 95584k
    Peak memory use before GGC: 88602k
    Peak memory use after GGC: 87617k
    Maximum of released memory in single GGC run: 19411k
    Garbage: 602650k -> 602729k
    Leak: 59897k -> 59890k
    Overhead: 137450k -> 137455k
    GGC runs: 655

comparing Gerald's testcase PR8361 compilation at -O3 level:
    Overall memory needed: 103248k
    Peak memory use before GGC: 95700k
    Peak memory use after GGC: 88917k
    Maximum of released memory in single GGC run: 20229k
    Garbage: 642910k -> 642727k
    Leak: 60237k -> 60230k
    Overhead: 148799k -> 148752k
    GGC runs: 650

Head of changelog is:

--- /usr/src/SpecTests/sandbox-britten-memory/x86_64/mem-result/ChangeLog	2004-12-06 20:03:44.000000000 +0000
+++ /usr/src/SpecTests/sandbox-britten-memory/gcc/gcc/ChangeLog	2004-12-06 21:19:23.000000000 +0000
@@ -1,3 +1,15 @@
+2004-12-06  Zdenek Dvorak  <dvorakz@suse.cz>
+	    Kazu Hirata  <kazu@cs.umass.edu>
+
+	PR tree-optimization/18601
+	* tree-cfg.c (thread_jumps, thread_jumps_from_bb): Removed.
+	(tree_forwarder_block_p): Do not consider blocks that are its own
+	successors forwarders.
+	(cleanup_forwarder_blocks, remove_forwarder_block): New functions.
+	(cleanup_tree_cfg): Use cleanup_forwarder_blocks instead of
+	thread_jumps.
+	* tree-flow.h (bb_ann_d): Remove forwardable.
+
 2004-12-06  Kazu Hirata  <kazu@cs.umass.edu>
 
 	* expr.c (expand_expr_real_1): Remove an "if" whose condition

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.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]