Some aspect of GCC memory consumption increased by recent patch
gcctest@suse.de
gcctest@suse.de
Sat Sep 18 03:26:00 GMT 2004
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: 17776k
Peak memory use before GGC: 9294k
Peak memory use after GGC: 8606k
Maximum of released memory in single GGC run: 2870k
Garbage: 42611k
Leak: 6103k
Overhead: 5586k
GGC runs: 365
comparing combine.c compilation at -O1 level:
Overall memory needed: 18448k
Peak memory use before GGC: 9645k -> 9638k
Peak memory use after GGC: 8804k
Maximum of released memory in single GGC run: 2034k
Garbage: 72813k -> 72435k
Leak: 6665k -> 6669k
Overhead: 12303k -> 12198k
GGC runs: 590 -> 588
comparing combine.c compilation at -O2 level:
Overall memory needed: 21928k -> 21848k
Peak memory use before GGC: 12769k
Peak memory use after GGC: 12610k
Maximum of released memory in single GGC run: 2578k
Garbage: 88700k -> 87845k
Leak: 6424k
Overhead: 17052k -> 16685k
GGC runs: 582 -> 580
comparing combine.c compilation at -O3 level:
Amount of memory still referenced at the end of compilation increased from 6934k to 6950k, overall 0.23%
Overall memory needed: 26680k -> 26304k
Peak memory use before GGC: 13103k -> 13097k
Peak memory use after GGC: 12739k
Maximum of released memory in single GGC run: 3447k
Garbage: 117770k -> 116948k
Leak: 6934k -> 6950k
Overhead: 22131k -> 21813k
GGC runs: 644 -> 643
comparing insn-attrtab.c compilation at -O0 level:
Overall memory needed: 132860k
Peak memory use before GGC: 77100k
Peak memory use after GGC: 45185k
Maximum of released memory in single GGC run: 42129k
Garbage: 159511k
Leak: 10618k
Overhead: 19798k
GGC runs: 310
comparing insn-attrtab.c compilation at -O1 level:
Overall memory needed: 149896k -> 149952k
Peak memory use before GGC: 97456k -> 97424k
Peak memory use after GGC: 71693k
Maximum of released memory in single GGC run: 41239k
Garbage: 490782k -> 490292k
Leak: 11051k
Overhead: 85748k -> 85512k
GGC runs: 467
comparing insn-attrtab.c compilation at -O2 level:
Ovarall memory allocated via mmap and sbrk decreased from 240896k to 224524k, overall -7.29%
Overall memory needed: 240896k -> 224524k
Peak memory use before GGC: 113009k -> 112977k
Peak memory use after GGC: 87246k
Maximum of released memory in single GGC run: 35988k
Garbage: 543369k -> 542877k
Leak: 11207k
Overhead: 95861k -> 95625k
GGC runs: 389
comparing insn-attrtab.c compilation at -O3 level:
Overall memory needed: 224508k -> 224660k
Peak memory use before GGC: 113009k -> 112978k
Peak memory use after GGC: 87246k
Maximum of released memory in single GGC run: 35988k
Garbage: 544511k -> 544017k
Leak: 11247k
Overhead: 96263k -> 96026k
GGC runs: 396
comparing Gerald's testcase PR8361 compilation at -O0 level:
Overall memory needed: 114840k
Peak memory use before GGC: 92007k
Peak memory use after GGC: 90474k
Maximum of released memory in single GGC run: 20897k
Garbage: 274940k
Leak: 59854k
Overhead: 35160k
GGC runs: 556
comparing Gerald's testcase PR8361 compilation at -O1 level:
Overall memory needed: 126308k -> 126168k
Peak memory use before GGC: 96400k
Peak memory use after GGC: 89739k
Maximum of released memory in single GGC run: 20070k
Garbage: 656192k -> 645990k
Leak: 62359k -> 62367k
Overhead: 136569k -> 130425k
GGC runs: 807 -> 805
comparing Gerald's testcase PR8361 compilation at -O2 level:
Overall memory needed: 127396k -> 127244k
Peak memory use before GGC: 96400k
Peak memory use after GGC: 89740k
Maximum of released memory in single GGC run: 20070k
Garbage: 720692k -> 707068k
Leak: 62927k
Overhead: 164909k -> 156492k
GGC runs: 841 -> 837
comparing Gerald's testcase PR8361 compilation at -O3 level:
Overall memory needed: 125836k -> 125612k
Peak memory use before GGC: 92672k -> 92495k
Peak memory use after GGC: 90674k
Maximum of released memory in single GGC run: 20814k
Garbage: 761403k -> 746726k
Leak: 63334k
Overhead: 176387k -> 167574k
GGC runs: 833 -> 827
Head of changelog is:
--- /usr/src/SpecTests/sandbox-britten-memory/x86_64/mem-result/ChangeLog 2004-09-17 19:18:21.000000000 +0000
+++ /usr/src/SpecTests/sandbox-britten-memory/gcc/gcc/ChangeLog 2004-09-18 02:14:13.000000000 +0000
@@ -1,10 +1,102 @@
+2004-09-17 Zack Weinberg <zack@codesourcery.com>
+
+ * Makefile.in (c-parse.o): Depend on $(C_PRAGMA_H).
+ * objc/Make-lang.in (objc/objc-parse.o): Likewise.
+
+2004-09-17 Jones Desougi <jones@ingate.com>
+
+ * configure.ac: Replace AC_COMPILE_CHECK_SIZEOF with AC_CHECK_SIZEOF.
+ * configure, config.in: Regenerate.
+
+2004-09-17 Zack Weinberg <zack@codesourcery.com>
+
+ * tree.c, tree.h (tree_class_strings): Make array const.
+ Reindent per coding convention. Move asterisk to proper place
+ per coding convention.
+
+2004-09-18 Andreas Schwab <schwab@suse.de>
+
+ * Makefile.in (gimple-low.o): Depend on $(EXPR_H).
+ (tree-vectorizer.o): Likewise.
+ (targhooks.o): Likewise.
+
+2004-09-17 Jeffrey D. Oldham <oldham@codesourcery.com>
+ Zack Weinberg <zack@codesourcery.com>
+
+ * alias.c (find_base_decl): Remove unreachable case '3' block.
+ * expr.c (safe_from_p): Abort if passed a type.
+ * tree-gimple.c (recalculate_side_effects): Abort if passed
+ anything other than an expression.
+ * tree-ssa-pre.c (phi_translate): Return expr immediately if
+ is_gimple_min_invariant is true for it. Reorder cases for clarity.
+ Abort on un-handled tree classes.
+ (valid_in_set): Likewise.
+ * tree.c (tree_code_class_strings): New static data.
+
+ * tree.h (enum tree_code_class): New.
+ (tree_code_class_strings): Declare.
+ (TREE_CODE_CLASS_STRING, EXCEPTIONAL_CLASS_P, CONSTANT_CLASS_P)
+ (REFERENCE_CLASS_P, COMPARISON_CLASS_P, UNARY_CLASS_P, BINARY_CLASS_P)
+ (STATEMENT_CLASS_P, EXPRESSION_CLASS_P, IS_TYPE_OR_DECL_P): New macros.
+ (TYPE_P, DECL_P, IS_NON_TYPE_CODE_CLASS, IS_EXPR_CODE_CLASS)
+ (checking macros, EXPR_LOCATION, SET_EXPR_LOCATION, EXPR_LOCUS): Update.
+
+ * tree.def, c-common.def, objc/objc-tree.def: Use
+ tree_code_class enumeration constants instead of code letters.
+
+ * alias.c, builtins.c, c-common.c, c-format.c, c-lang.c, c-pragma.c
+ * c-typeck.c, cgraphunit.c, convert.c, dbxout.c, dwarf2out.c
+ * emit-rtl.c expr.c, fold-const.c, gimplify.c, lambda-code.c
+ * langhooks.c, langhooks.h, predict.c, print-tree.c, reload1.c, stmt.c
+ * tree-browser.c, tree-cfg.c, tree-chrec.c, tree-complex.c, tree-dfa.c
+ * tree-dump.c, tree-eh.c, tree-gimple.c, tree-inline.c, tree-nested.c
+ * tree-outof-ssa.c, tree-pretty-print.c, tree-sra.c, tree-ssa-ccp.c
+ * tree-ssa-dce.c, tree-ssa-dom.c, tree-ssa-forwprop.c, tree-ssa-live.c
+ * tree-ssa-loop-im.c, tree-ssa-loop-ivopts.c, tree-ssa-operands.c
+ * tree-ssa-phiopt.c, tree-ssa-pre.c, tree-ssa-propagate.c
+ * tree-ssa.c, tree-ssanames.c, tree-tailcall.c, tree.c, varasm.c
+ * config/sol2-c.c, config/arm/arm.c, config/i386/winnt.c
+ * config/pa/pa.c, config/pa/pa.h, config/sh/sh.c, objc/objc-lang.c
+ Update to match.
+
+ * LANGUAGES: Add note about change.
+
+2004-09-17 Diego Novillo <dnovillo@redhat.com>
+
+ PR tree-optimization/17319
+ * tree-ssa-alias.c (compute_points_to_and_addr_escape): Also
+ examine pointers on the LHS of an assignment.
+ (collect_points_to_info_r): Handle RETURN_EXPR.
+
+2004-09-17 Jeff Law <law@redhat.com>
+
+ * tree-ssa-dom.c (const_and_copies_stack): New.
+ (dom_walk_block_data): Remove const_and_copies field.
+ (record_const_or_copy): No longer need to pass in varray_type *.
+ Use CONST_AND_COPIES_STACK rather than passed in block local stack.
+ Callers updated.
+ (record_equality): Similarly.
+ (restore_vars_to_original_value): Similarly. Revamp to use new
+ single global stack rather than per-block stacks.
+ (tree_ssa_dominator_optimize): Initialize the CONST_AND_COPIES_STACK.
+ (thread_across_edge): Remove now unused parameters.
+ (dom_opt_initialize_block_local_data): No longer test the block
+ local CONST_AND_COPIES.
+ (dom_opt_initialize_block): Push a marker on CONST_AND_COPIES_STACK.
+
+2004-09-17 Jan Hubicka <jh@suse.cz>
+
+ PR tree-optimization/17509
+ * tree-optimize.c (update_inlined_to_pointers): New function.
+ (tree_rest_of_compilation): Use it.
+
2004-09-17 Devang Patel <dpatel@apple.com>
* dbxout.c (get_lang_number): New.
(dbxout_init): Include lang number in N_SO stab.
* dbxout.h (N_SO_AS, N_SO_C, N_SO_ANSI_C, N_SO_CC, N_SO_FORTRAN,
N_SO_PASCAL, N_SO_FORTRAN90, N_SO_OBJC, N_SO_OBJCPLUS): New #define.
-
+
2004-09-17 Diego Novillo <dnovillo@redhat.com>
PR tree-optimization/17273
@@ -34,7 +126,7 @@
2004-09-17 Sylvain Pion <Sylvain.Pion@sophia.inria.fr>
- * doc/extend.texi: Fix duplicated word.
+ * doc/extend.texi: Fix duplicated word.
2004-09-17 Toon Moene <toon@moene.indiv.nluug.nl>
@@ -86,7 +178,7 @@
2004-09-17 Steven Bosscher <stevenb@suse.de>
- PR tree-optimization/17513
+ PR tree-optimization/17513
* cfgexpand.c (construct_init_block): Clear EDGE_EXECUTABLE
for successors of the entry block.
@@ -179,11 +271,11 @@
2004-09-16 Andrew MacLeod <amacleod@redhat.com>
PR tree-optimization/17517
- * tree-ssa-copyrename.c (copy_rename_partition_coalesce): Don't
+ * tree-ssa-copyrename.c (copy_rename_partition_coalesce): Don't
coalesce same-root variables without checking for abnormal PHI usage.
2004-09-16 Daniel Berlin <dberlin@dberlin.org>
-
+
* cfgloop.h (duplicate_loop): Add prototype.
* cfgloopmanip.c (duplicate_loop): Make non-static.
* lambda-code.c (perfect_nestify): Factor out test whether
@@ -200,7 +292,7 @@
loop invariant as well.
(perfect_nestify): new function.
(gcc_loop_to_lambda_loop): New parameters to track lower bounds,
- upper bounds, and steps.
+ upper bounds, and steps.
Set outerinductionvar properly.
(gcc_loopnest_to_lambda_loopnest): Add loops and need_perfect
parameters.
@@ -225,9 +317,9 @@
2004-09-16 Sebastian Pop <pop@cri.ensmp.fr>
* tree-loop-linear.c (gather_interchange_stats): Add more comments.
- Gather also strides of accessed data. Pass in the data references
+ Gather also strides of accessed data. Pass in the data references
array.
- (try_interchange_loops): Add a new heuristic for handling the temporal
+ (try_interchange_loops): Add a new heuristic for handling the temporal
locality. Pass in the data references array.
(linear_transform_loops): Pass the data references array to
try_interchange_loops.
@@ -340,7 +432,7 @@
* Makefile.in (tree-ssa-dom.o): Depend on tree-ssa-propagate.h.
* tree-ssa-dom.c (cprop_into_stmt): Recompute TREE_INVARIANT
- after propagating into an ADDR_EXPR.
+ after propagating into an ADDR_EXPR.
2004-09-15 Andrew Pinski <apinski@apple.com>
@@ -558,7 +650,7 @@
2004-09-14 Jeff Law <law@redhat.com>
* tree-ssa-dom.c (stmts_to_rescan): Move from a block-local
- to a global varray.
+ to a global varray.
(tree_ssa_dominator_optimize): Allocate stmts_to_rescan.
(dom_opt_initialize_block_local_data): No longer test state
of stmts_to_rescan.
@@ -795,7 +887,7 @@
PR tree-optimization/17400
* tree-ssa-copyrename.c (copy_rename_partition_coalesce): Don't
coalesce partitions when one occurs in an abnormal PHI.
-
+
2004-09-13 Andrew Pinski <apinski@apple.com>
* config/rs6000/darwin.h (ASM_OUTPUT_COMMON): Change variable size's
--- /usr/src/SpecTests/sandbox-britten-memory/x86_64/mem-result/ChangeLog.cp 2004-09-17 09:31:34.000000000 +0000
+++ /usr/src/SpecTests/sandbox-britten-memory/gcc/gcc/cp/ChangeLog 2004-09-18 02:18:55.000000000 +0000
@@ -1,3 +1,12 @@
+2004-09-17 Jeffrey D. Oldham <oldham@codesourcery.com>
+ Zack Weinberg <zack@codesourcery.com>
+
+ * cp-tree.def: Use tree_code_class enumeration constants
+ instead of code letters.
+ * call.c, class.c, cp-gimplify.c, cp-lang.c, cxx-pretty-print.c
+ * mangle.c, pt.c, semantics.c, tree.c, typeck.c:
+ Update for new tree-class enumeration constants.
+
2004-09-16 Mark Mitchell <mark@codesourcery.com>
PR c++/16002
@@ -16,7 +25,7 @@
2004-09-16 Andrew MacLeod <amacleod@redhat.com>
- * error.c (dump_decl): Make sure there is lang_specific info before
+ * error.c (dump_decl): Make sure there is lang_specific info before
checking for DTOR and CTOR decls.
2004-09-16 Nathan Sidwell <nathan@codesourcery.com>
@@ -106,9 +115,9 @@
2004-09-11 Richard Henderson <rth@redhat.com>
PR c++/17404
- * pt.c (cur_stmt_expr): Move from tsubst_expr.
- (tsubst_expr) <case STMT_EXPR>: Move ...
- (tsubst_copy_and_build): ... here.
+ * pt.c (cur_stmt_expr): Move from tsubst_expr.
+ (tsubst_expr) <case STMT_EXPR>: Move ...
+ (tsubst_copy_and_build): ... here.
2004-09-10 Zack Weinberg <zack@codesourcery.com>
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