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: 24389k
    Peak memory use before GGC: 9063k
    Peak memory use after GGC: 8377k
    Maximum of released memory in single GGC run: 2864k
    Garbage: 41736k
    Leak: 5863k
    Overhead: 5545k
    GGC runs: 352

comparing combine.c compilation at -O1 level:
    Overall memory needed: 25361k
    Peak memory use before GGC: 8951k
    Peak memory use after GGC: 8450k
    Maximum of released memory in single GGC run: 2024k
    Garbage: 66726k
    Leak: 6258k
    Overhead: 10311k
    GGC runs: 545

comparing combine.c compilation at -O2 level:
    Overall memory needed: 28845k
    Peak memory use before GGC: 12383k
    Peak memory use after GGC: 12257k
    Maximum of released memory in single GGC run: 2533k
    Garbage: 80657k
    Leak: 6082k
    Overhead: 14119k
    GGC runs: 546

comparing combine.c compilation at -O3 level:
    Overall memory needed: 31345k
    Peak memory use before GGC: 12635k
    Peak memory use after GGC: 12257k
    Maximum of released memory in single GGC run: 3347k
    Garbage: 109133k
    Leak: 6619k
    Overhead: 18983k
    GGC runs: 613

comparing insn-attrtab.c compilation at -O0 level:
    Overall memory needed: 117268k
    Peak memory use before GGC: 77779k
    Peak memory use after GGC: 45259k
    Maximum of released memory in single GGC run: 42606k
    Garbage: 159302k
    Leak: 10433k
    Overhead: 20572k
    GGC runs: 294

comparing insn-attrtab.c compilation at -O1 level:
    Overall memory needed: 128492k
    Peak memory use before GGC: 83296k
    Peak memory use after GGC: 69015k
    Maximum of released memory in single GGC run: 40616k
    Garbage: 441432k
    Leak: 10779k
    Overhead: 77164k
    GGC runs: 431

comparing insn-attrtab.c compilation at -O2 level:
    Overall memory needed: 153116k
    Peak memory use before GGC: 99056k
    Peak memory use after GGC: 84176k
    Maximum of released memory in single GGC run: 41525k
    Garbage: 487966k
    Leak: 10703k
    Overhead: 85264k
    GGC runs: 363

comparing insn-attrtab.c compilation at -O3 level:
    Overall memory needed: 153128k
    Peak memory use before GGC: 99057k
    Peak memory use after GGC: 84178k
    Maximum of released memory in single GGC run: 41525k
    Garbage: 489168k
    Leak: 10745k
    Overhead: 85424k
    GGC runs: 373

comparing Gerald's testcase PR8361 compilation at -O0 level:
  Amount of produced GGC garbage increased from 242698k to 246468k, overall 1.55%
  Amount of memory still referenced at the end of compilation increased from 54798k to 54981k, overall 0.33%
    Overall memory needed: 110796k
    Peak memory use before GGC: 86609k
    Peak memory use after GGC: 85641k
    Maximum of released memory in single GGC run: 19292k
    Garbage: 242698k -> 246468k
    Leak: 54798k -> 54981k
    Overhead: 42333k -> 43128k
    GGC runs: 364 -> 369

comparing Gerald's testcase PR8361 compilation at -O1 level:
    Overall memory needed: 103701k
    Peak memory use before GGC: 85639k
    Peak memory use after GGC: 84690k
    Maximum of released memory in single GGC run: 18904k
    Garbage: 466595k -> 466427k
    Leak: 56726k -> 56728k
    Overhead: 67009k -> 66947k
    GGC runs: 554 -> 553

comparing Gerald's testcase PR8361 compilation at -O2 level:
    Overall memory needed: 103757k -> 103761k
    Peak memory use before GGC: 85639k
    Peak memory use after GGC: 84691k
    Maximum of released memory in single GGC run: 18904k
    Garbage: 500939k -> 500759k
    Leak: 57306k -> 57300k
    Overhead: 76509k -> 76409k
    GGC runs: 598 -> 597

comparing Gerald's testcase PR8361 compilation at -O3 level:
    Overall memory needed: 111449k -> 111441k
    Peak memory use before GGC: 92444k
    Peak memory use after GGC: 85893k
    Maximum of released memory in single GGC run: 19736k
    Garbage: 520836k -> 520652k
    Leak: 57641k -> 57632k
    Overhead: 78275k -> 78248k
    GGC runs: 579

Head of changelog is:

--- /usr/src/SpecTests/sandbox-britten-memory/x86_64/mem-result/ChangeLog	2004-12-31 23:58:19.000000000 +0000
+++ /usr/src/SpecTests/sandbox-britten-memory/gcc/gcc/ChangeLog	2005-01-01 06:51:21.000000000 +0000
@@ -1,3 +1,22 @@
+2004-12-31  Richard Henderson  <rth@redhat.com>
+
+	PR tree-opt/19042
+	* tree-sra.c (decide_block_copy): Force use_block_copy false
+	for complex values.
+
+2004-12-31  Richard Henderson  <rth@redhat.com>
+
+	PR middle-end/17799
+	* function.c (use_register_for_decl): Check DECL_IGNORED_P instead
+	of DECL_ARTIFICIAL.
+	(assign_parms_augmented_arg_list): Set DECL_IGNORED_P.
+	* c-decl.c (build_compound_literal): Likewise.
+	* dwarf2asm.c (dw2_force_const_mem): Likewise.
+	* gimplify.c (create_artificial_label): Likewise.
+	* tree-inline.c (expand_call_inline): Likewise.
+	* var-tracking.c (vt_initialize): Likewise.
+	* tree-outof-ssa.c (create_temp): Copy DECL_IGNORED_P.
+
 2004-12-31  Andrew Pinski  <pinskia@physics.uc.edu>
 
 	PR target/19211
--- /usr/src/SpecTests/sandbox-britten-memory/x86_64/mem-result/ChangeLog.cp	2004-12-31 05:02:47.000000000 +0000
+++ /usr/src/SpecTests/sandbox-britten-memory/gcc/gcc/cp/ChangeLog	2005-01-01 06:51:24.000000000 +0000
@@ -1,3 +1,14 @@
+2004-12-31  Richard Henderson  <rth@redhat.com>
+
+	PR middle-end/17799
+	* call.c (make_temporary_var_for_ref_to_temp): Set DECL_IGNORED_P.
+	* class.c (build_vtable): Don't conditionallize setting it
+	based on DWARF2_DEBUG.
+	(layout_class_type): Set DECL_IGNORED_P.
+	* decl2.c (get_guard): Likewise.
+	* rtti.c (get_tinfo_decl, build_lang_decl): Likewise.
+	* tree.c (build_local_temp): Likewise.
+
 2004-12-30  Mark Mitchell  <mark@codesourcery.com>
 
 	* cp-tree.h (cp_declarator): Split "name" field into

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]