This is the mail archive of the
gcc-regression@gcc.gnu.org
mailing list for the GCC project.
A recent patch increased GCC's memory consumption!
- From: gcctest at suse dot de
- To: jh at suse dot cz, gcc-regression at gcc dot gnu dot org
- Date: Tue, 07 Feb 2006 13:20:23 +0000
- Subject: A recent patch increased GCC's memory consumption!
Hi,
I am a friendly script caring about memory consumption in GCC. Please
contact jh@suse.cz if something is going wrong.
Comparing memory consumption on compilation of combine.i, insn-attrtab.i,
and generate-3.4.ii I got:
comparing combine.c compilation at -O0 level:
Overall memory needed: 25324k
Peak memory use before GGC: 9566k
Peak memory use after GGC: 8913k -> 8914k
Maximum of released memory in single GGC run: 2649k
Garbage: 40060k -> 40064k
Leak: 6740k -> 6740k
Overhead: 5738k -> 5738k
GGC runs: 313
comparing combine.c compilation at -O1 level:
Overall memory needed: 26892k -> 26900k
Peak memory use before GGC: 17434k -> 17435k
Peak memory use after GGC: 17255k -> 17256k
Maximum of released memory in single GGC run: 2309k -> 2310k
Garbage: 62589k -> 62590k
Leak: 6889k -> 6889k
Overhead: 7488k -> 7488k
GGC runs: 393
comparing combine.c compilation at -O2 level:
Overall memory needed: 26892k -> 26900k
Peak memory use before GGC: 17436k -> 17438k
Peak memory use after GGC: 17255k -> 17256k
Maximum of released memory in single GGC run: 2410k
Garbage: 83409k -> 83419k
Leak: 6977k -> 6975k
Overhead: 10316k -> 10317k
GGC runs: 451
comparing combine.c compilation at -O3 level:
Overall memory needed: 26892k -> 26900k
Peak memory use before GGC: 18414k
Peak memory use after GGC: 17970k
Maximum of released memory in single GGC run: 3385k -> 3384k
Garbage: 115499k -> 115525k
Leak: 7040k -> 7041k
Overhead: 14088k -> 14093k
GGC runs: 502 -> 503
comparing insn-attrtab.c compilation at -O0 level:
Amount of produced GGC garbage increased from 146427k to 146687k, overall 0.18%
Overall memory needed: 80948k
Peak memory use before GGC: 69508k
Peak memory use after GGC: 45044k -> 45045k
Maximum of released memory in single GGC run: 36220k
Garbage: 146427k -> 146687k
Leak: 10131k -> 9892k
Overhead: 19750k -> 19751k
GGC runs: 247
comparing insn-attrtab.c compilation at -O1 level:
Overall memory needed: 109164k -> 109564k
Peak memory use before GGC: 91973k -> 91975k
Peak memory use after GGC: 81071k -> 81073k
Maximum of released memory in single GGC run: 32143k -> 32142k
Garbage: 296462k -> 296454k
Leak: 10054k -> 10055k
Overhead: 36102k -> 36102k
GGC runs: 245
comparing insn-attrtab.c compilation at -O2 level:
Overall memory needed: 122560k -> 122556k
Peak memory use before GGC: 109356k -> 109357k
Peak memory use after GGC: 80974k
Maximum of released memory in single GGC run: 31578k -> 31577k
Garbage: 381029k -> 381033k
Leak: 10156k -> 10157k
Overhead: 47872k -> 47872k
GGC runs: 274
comparing insn-attrtab.c compilation at -O3 level:
Overall memory needed: 122616k -> 122612k
Peak memory use before GGC: 109382k -> 109385k
Peak memory use after GGC: 80999k -> 81002k
Maximum of released memory in single GGC run: 31908k
Garbage: 381630k -> 381623k
Leak: 10160k -> 10161k
Overhead: 48069k -> 48069k
GGC runs: 276
comparing Gerald's testcase PR8361 compilation at -O0 level:
Overall memory needed: 118424k
Peak memory use before GGC: 95198k
Peak memory use after GGC: 94250k
Maximum of released memory in single GGC run: 20356k
Garbage: 223714k
Leak: 49472k
Overhead: 37113k
GGC runs: 369
comparing Gerald's testcase PR8361 compilation at -O1 level:
Overall memory needed: 108528k
Peak memory use before GGC: 95331k
Peak memory use after GGC: 93251k
Maximum of released memory in single GGC run: 20233k
Garbage: 565076k
Leak: 52291k
Overhead: 63655k
GGC runs: 531
comparing Gerald's testcase PR8361 compilation at -O2 level:
Overall memory needed: 108532k
Peak memory use before GGC: 95331k
Peak memory use after GGC: 93252k
Maximum of released memory in single GGC run: 20232k
Garbage: 690223k
Leak: 53426k
Overhead: 77124k
GGC runs: 617
comparing Gerald's testcase PR8361 compilation at -O3 level:
Overall memory needed: 114280k
Peak memory use before GGC: 96797k
Peak memory use after GGC: 94327k
Maximum of released memory in single GGC run: 20729k
Garbage: 753221k
Leak: 54359k
Overhead: 81858k
GGC runs: 626
Head of the ChangeLog is:
--- /usr/src/SpecTests/sandbox-britten-memory/x86_64/mem-result/ChangeLog 2006-02-07 01:47:30.000000000 +0000
+++ /usr/src/SpecTests/sandbox-britten-memory/gcc/gcc/ChangeLog 2006-02-07 12:11:05.000000000 +0000
@@ -1,3 +1,33 @@
+2006-02-07 Pete Steinmetz <steinmtz@us.ibm.com>
+
+ * sched-rgn.c (compute_dom_prob_ps, compute_trg_info): Eradicate
+ use of float in probability computations. Use edge probabilities
+ in place of statically computed probabilities.
+ (min_spec_prob): New static variable.
+ (schedule_insns): Initialize it.
+ (GET_SRC_PROB): Removed.
+ * doc/invoke.texi (min-sched-prob): Renamed to min-spec-prob.
+
+2006-02-07 Alexandre Oliva <aoliva@redhat.com>
+
+ PR debug/24444
+ * config/ia64/unwind-ia64.c: Revert last change.
+ * config/ia64/ia64.h (ARG_POINTER_CFA_OFFSET): Removed.
+ (INCOMING_FRAME_SP_OFFSET): Define.
+
+2006-02-06 Roger Sayle <roger@eyesopen.com>
+
+ * config/ia64/ia64.c (hfa_element_mode): Don't handle CHAR_TYPE.
+
+2006-02-07 Ben Elliston <bje@au.ibm.com>
+
+ * config/i386/i386.c (ix86_scalar_mode_supported_p): New.
+ (TARGET_SCALAR_MODE_SUPPORTED_P): Define hook.
+ (classify_argument): Handle SDmode, DDmode, TDmode for 64-bit.
+ (ix86_return_in_memory): Handle TDmode.
+ (ix86_libcall_value): Handle SDmode, DDmode, TDmode.
+ (ix86_value_regno): Return non-TDmode decimal float modes in %eax.
+
2006-02-06 Richard Sandiford <richard@codesourcery.com>
* reorg.c (dbr_schedule): Use dump_file instead of file.
--- /usr/src/SpecTests/sandbox-britten-memory/x86_64/mem-result/ChangeLog.cp 2006-02-04 21:55:35.000000000 +0000
+++ /usr/src/SpecTests/sandbox-britten-memory/gcc/gcc/cp/ChangeLog 2006-02-07 12:11:05.000000000 +0000
@@ -1,3 +1,10 @@
+2006-02-06 Roger Sayle <roger@eyesopen.com>
+
+ * decl.c (grokdeclarator): Don't bother checking for CHAR_TYPE.
+ * rtti.c (typeinfo_in_lib_p): Likewise.
+ * cp-tree.h (INTEGRAL_CODE_P, CP_INTEGRAL_TYPE_P): Likewise.
+ * name-lookup.c (arg_assoc_type): Likewise.
+
2006-02-04 Gabriel Dos Reis <gdr@integrable-solutions.net>
* cp-tree.h (tf_warn_or_error): New substituion flag.
The results can be reproduced by building a 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.
Your testing script.