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]

Some aspect of 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: 24585k -> 24589k
    Peak memory use before GGC: 9310k
    Peak memory use after GGC: 8624k
    Maximum of released memory in single GGC run: 2912k
    Garbage: 42437k
    Leak: 6118k
    Overhead: 5748k
    GGC runs: 353

comparing combine.c compilation at -O1 level:
  Overall memory allocated via mmap and sbrk increased from 25501k to 25545k, overall 0.17%
    Overall memory needed: 25501k -> 25545k
    Peak memory use before GGC: 9198k -> 9195k
    Peak memory use after GGC: 8720k -> 8693k
    Maximum of released memory in single GGC run: 2060k
    Garbage: 68015k -> 67948k
    Leak: 6514k
    Overhead: 10697k -> 10667k
    GGC runs: 546 -> 545

comparing combine.c compilation at -O2 level:
    Overall memory needed: 29085k -> 29093k
    Peak memory use before GGC: 12705k
    Peak memory use after GGC: 12578k
    Maximum of released memory in single GGC run: 2574k
    Garbage: 82230k -> 81919k
    Leak: 6331k
    Overhead: 14853k -> 14545k
    GGC runs: 548 -> 546

comparing combine.c compilation at -O3 level:
  Amount of memory still referenced at the end of compilation increased from 6862k to 6878k, overall 0.23%
    Overall memory needed: 31485k -> 31425k
    Peak memory use before GGC: 12987k
    Peak memory use after GGC: 12578k
    Maximum of released memory in single GGC run: 3407k
    Garbage: 111193k -> 110898k
    Leak: 6862k -> 6878k
    Overhead: 19934k -> 19547k
    GGC runs: 615 -> 613

comparing insn-attrtab.c compilation at -O0 level:
    Overall memory needed: 118468k
    Peak memory use before GGC: 79387k
    Peak memory use after GGC: 46137k
    Maximum of released memory in single GGC run: 43336k
    Garbage: 161992k
    Leak: 10634k
    Overhead: 21268k
    GGC runs: 296

comparing insn-attrtab.c compilation at -O1 level:
    Overall memory needed: 129456k
    Peak memory use before GGC: 83952k
    Peak memory use after GGC: 70040k
    Maximum of released memory in single GGC run: 41104k
    Garbage: 445757k -> 445755k
    Leak: 10981k
    Overhead: 79321k -> 79320k
    GGC runs: 430

comparing insn-attrtab.c compilation at -O2 level:
    Overall memory needed: 154068k -> 153936k
    Peak memory use before GGC: 99964k
    Peak memory use after GGC: 85453k
    Maximum of released memory in single GGC run: 42091k
    Garbage: 492648k -> 492647k
    Leak: 10901k
    Overhead: 87595k -> 87595k
    GGC runs: 364

comparing insn-attrtab.c compilation at -O3 level:
    Overall memory needed: 153924k -> 153928k
    Peak memory use before GGC: 99966k
    Peak memory use after GGC: 85455k
    Maximum of released memory in single GGC run: 42091k
    Garbage: 493911k -> 493910k
    Leak: 10944k
    Overhead: 87759k -> 87758k
    GGC runs: 372

comparing Gerald's testcase PR8361 compilation at -O0 level:
    Overall memory needed: 113408k
    Peak memory use before GGC: 89921k
    Peak memory use after GGC: 89026k
    Maximum of released memory in single GGC run: 19894k
    Garbage: 248878k
    Leak: 57792k
    Overhead: 45384k
    GGC runs: 361

comparing Gerald's testcase PR8361 compilation at -O1 level:
  Overall memory allocated via mmap and sbrk increased from 95920k to 106225k, overall 10.74%
  Amount of produced GGC garbage decreased from 552582k to 483979k, overall -14.17%
    Overall memory needed: 95920k -> 106225k
    Peak memory use before GGC: 88923k
    Peak memory use after GGC: 87937k
    Maximum of released memory in single GGC run: 19408k
    Garbage: 552582k -> 483979k
    Leak: 59824k -> 59823k
    Overhead: 115280k -> 71065k
    GGC runs: 610 -> 550

comparing Gerald's testcase PR8361 compilation at -O2 level:
  Overall memory allocated via mmap and sbrk increased from 95920k to 106285k, overall 10.81%
  Amount of produced GGC garbage decreased from 601773k to 518760k, overall -16.00%
    Overall memory needed: 95920k -> 106285k
    Peak memory use before GGC: 88923k
    Peak memory use after GGC: 87938k
    Maximum of released memory in single GGC run: 19408k
    Garbage: 601773k -> 518760k
    Leak: 60405k -> 60405k
    Overhead: 137310k -> 80693k
    GGC runs: 651 -> 590

comparing Gerald's testcase PR8361 compilation at -O3 level:
  Overall memory allocated via mmap and sbrk increased from 98572k to 107933k, overall 9.50%
  Amount of produced GGC garbage decreased from 641712k to 539487k, overall -18.95%
    Overall memory needed: 98572k -> 107933k
    Peak memory use before GGC: 90319k
    Peak memory use after GGC: 88770k
    Maximum of released memory in single GGC run: 20096k
    Garbage: 641712k -> 539487k
    Leak: 60736k -> 60737k
    Overhead: 148688k -> 82417k
    GGC runs: 645 -> 575

Head of changelog is:

--- /usr/src/SpecTests/sandbox-britten-memory/x86_64/mem-result/ChangeLog	2004-12-20 12:59:20.000000000 +0000
+++ /usr/src/SpecTests/sandbox-britten-memory/gcc/gcc/ChangeLog	2004-12-21 00:05:16.000000000 +0000
@@ -1,3 +1,37 @@
+2004-12-20  Eric Botcazou  <ebotcazou@libertysurf.fr>
+
+	PR middle-end/18776
+	* expr.c (write_complex_part): Use a subreg if the original object
+	is a hard reg that spans an even number of regs or a MEM.
+	(read_complex_part): Likewise.
+
+2004-12-20  Mark Mitchell  <mark@codesourcery.com>
+
+	* Makefile.in (install-common): Do not install the specs file
+	unless SPECS is defined.
+
+2004-12-20  Zdenek Dvorak  <dvorakz@suse.cz>
+
+	PR rtl-optimization/18942
+	* simplify-rtx.c (simplify_relational_operation_1): Simplify
+	x + cst1 == cst2 to x == cst2 - cst1.  Made static.
+
+2004-12-20  Matt Austern  <austern@apple.com>
+
+	PR c++/19044
+	* c-common.c (set_builtin_user_assembler_name): New.
+	* c-common.h (set_builtin_user_assembler_name): Declare.
+	* c-decl.c (finish_decl): Use set_builtin_user_assembler_name
+	
+2004-12-20  Diego Novillo  <dnovillo@redhat.com>
+
+	PR tree-optimization/19080
+
+	Merge from tree-cleanup-branch
+
+	* tree-flow-inline.h (clear_call_clobbered): New function.
+	* tree-ssa-alias.c (init_alias_info): Call it.
+
 2004-12-20  Richard Henderson  <rth@redhat.com>
 
 	* config/i386/i386.md (sse2_movsd): Remove ix86_binary_operator_ok
--- /usr/src/SpecTests/sandbox-britten-memory/x86_64/mem-result/ChangeLog.cp	2004-12-20 02:27:51.000000000 +0000
+++ /usr/src/SpecTests/sandbox-britten-memory/gcc/gcc/cp/ChangeLog	2004-12-21 00:05:18.000000000 +0000
@@ -1,3 +1,8 @@
+2004-12-20  Matt Austern <austern@apple.com>
+
+	PR c++/19044
+	* decl.c (make_rtl_for_nonlocal_decl): Use set_builtin_user_assembler_name
+	
 2004-12-19  Mark Mitchell  <mark@codesourcery.com>
 
 	* cp-tree.h (note_decl_for_pch): New function.

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]