GCC memory consumption increased by recent patch!
gcctest@suse.de
gcctest@suse.de
Sun Mar 6 02:48:00 GMT 2005
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: 24665k
Peak memory use before GGC: 9359k
Peak memory use after GGC: 8673k
Maximum of released memory in single GGC run: 2865k
Garbage: 41675k
Leak: 6395k
Overhead: 5772k
GGC runs: 327
comparing combine.c compilation at -O1 level:
Overall memory needed: 24521k -> 24509k
Peak memory use before GGC: 8673k
Peak memory use after GGC: 8093k
Maximum of released memory in single GGC run: 2026k
Garbage: 58556k
Leak: 6756k
Overhead: 9886k
GGC runs: 500
comparing combine.c compilation at -O2 level:
Overall memory needed: 29149k -> 29141k
Peak memory use before GGC: 12671k
Peak memory use after GGC: 12544k
Maximum of released memory in single GGC run: 2533k
Garbage: 78269k
Leak: 6594k
Overhead: 14170k
GGC runs: 520
comparing combine.c compilation at -O3 level:
Overall memory needed: 30817k -> 30813k
Peak memory use before GGC: 12713k
Peak memory use after GGC: 12544k
Maximum of released memory in single GGC run: 3392k
Garbage: 105878k
Leak: 7189k
Overhead: 19022k
GGC runs: 582
comparing insn-attrtab.c compilation at -O0 level:
Overall memory needed: 114212k
Peak memory use before GGC: 74821k
Peak memory use after GGC: 45494k
Maximum of released memory in single GGC run: 39413k
Garbage: 152830k
Leak: 10984k
Overhead: 19970k
GGC runs: 273
comparing insn-attrtab.c compilation at -O1 level:
Overall memory needed: 124600k
Peak memory use before GGC: 78641k
Peak memory use after GGC: 70036k
Maximum of released memory in single GGC run: 40782k
Garbage: 369270k
Leak: 11361k
Overhead: 71894k
GGC runs: 398
comparing insn-attrtab.c compilation at -O2 level:
Overall memory needed: 148936k
Peak memory use before GGC: 97678k
Peak memory use after GGC: 83497k
Maximum of released memory in single GGC run: 39163k
Garbage: 486952k
Leak: 11252k
Overhead: 87104k
GGC runs: 342
comparing insn-attrtab.c compilation at -O3 level:
Overall memory allocated via mmap and sbrk increased from 137824k to 147500k, overall 7.02%
Overall memory needed: 137824k -> 147500k
Peak memory use before GGC: 97679k
Peak memory use after GGC: 83499k
Maximum of released memory in single GGC run: 39162k
Garbage: 487762k
Leak: 11287k
Overhead: 87234k
GGC runs: 348
comparing Gerald's testcase PR8361 compilation at -O0 level:
Overall memory needed: 111952k
Peak memory use before GGC: 87325k
Peak memory use after GGC: 85900k
Maximum of released memory in single GGC run: 19511k
Garbage: 246370k
Leak: 55513k
Overhead: 43275k
GGC runs: 366
comparing Gerald's testcase PR8361 compilation at -O1 level:
Overall memory needed: 104033k -> 104041k
Peak memory use before GGC: 86183k
Peak memory use after GGC: 85119k
Maximum of released memory in single GGC run: 18950k
Garbage: 435088k
Leak: 56863k
Overhead: 65172k
GGC runs: 513
comparing Gerald's testcase PR8361 compilation at -O2 level:
Overall memory needed: 104249k
Peak memory use before GGC: 86184k
Peak memory use after GGC: 85119k
Maximum of released memory in single GGC run: 18951k
Garbage: 476277k
Leak: 57427k
Overhead: 74892k
GGC runs: 569
comparing Gerald's testcase PR8361 compilation at -O3 level:
Overall memory needed: 105353k
Peak memory use before GGC: 87323k
Peak memory use after GGC: 86199k
Maximum of released memory in single GGC run: 19400k
Garbage: 481450k
Leak: 57631k
Overhead: 75594k
GGC runs: 557
Head of changelog is:
--- /usr/src/SpecTests/sandbox-britten-memory/x86_64/mem-result/ChangeLog 2005-03-05 16:28:45.000000000 +0000
+++ /usr/src/SpecTests/sandbox-britten-memory/gcc/gcc/ChangeLog 2005-03-06 01:49:48.000000000 +0000
@@ -1,5 +1,27 @@
2005-03-05 Kazu Hirata <kazu@cs.umass.edu>
+ * c-semantics.c (build_stmt): Use TYPE_P instead of
+ IS_NON_TYPE_CODE_CLASS.
+ * tree.h (IS_NON_TYPE_CODE_CLASS): Remove.
+ (NON_TYPE_CHECK): Use TYPE_P instead of
+ IS_NON_TYPE_CODE_CLASS.
+
+ * fold-const.c (fold): Remove handling of binary expressions.
+
+2005-03-05 James A. Morrison <phython@gcc.gnu.org>
+
+ * doc/c-tree.texi: Wrap comments in @r{}.
+ * doc/cpp.texi: Likewise.
+ * doc/cppinternals.texi: Likewise.
+ * doc/extend.texi: Likewise.
+ * doc/md.texi: Likewise.
+ * doc/objc.texi: Likewise.
+ * doc/sourcebuild.texi: Likewise.
+ * doc/tm.texi: Likewise.
+ * doc/tree-ssa.texi
+
+2005-03-05 Kazu Hirata <kazu@cs.umass.edu>
+
* predict.c (apply_return_prediction): Standardize PHI chain
walking.
* tree-ssa.c (ssa_redirect_edge): Likewise.
@@ -21,6 +43,17 @@
* tree-ssa-pre.c (remove_dead_inserted_code): Likewise.
* tree-ssa.c (kill_redundant_phi_nodes): Likewise.
+ * combine.c (simplify_and_const_int): Use gen_int_mode instead
+ of GEN_INT (trunc_int_for_mode (...)).
+ * loop-iv.c (iv_number_of_iterations): Likewise.
+ * postreload.c (reload_cse_move2add): Likewise.
+ * simplify-rtx.c (simplify_const_unary_operation,
+ simplify_const_binary_operation): Likewise.
+ * stor-layout.c (get_mode_bounds): Likewise.
+
+ * fold-const.c (fold_binary): New.
+ (fold): Call fold_binary on binary expressions.
+
2005-03-05 Richard Sandiford <rsandifo@redhat.com>
* doc/invoke.texi: Document new MIPS -msym32 and -mno-sym32 options.
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