This is the mail archive of the
gcc-regression@gcc.gnu.org
mailing list for the GCC project.
GCC memory consumption increased by recent patch!
- From: gcctest at suse dot de
- To: jh at suse dot cz, gcc-regression at gcc dot gnu dot org
- Date: Wed, 27 Oct 2004 21:30:26 +0000
- Subject: 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: 25253k -> 25257k
Peak memory use before GGC: 9336k
Peak memory use after GGC: 8648k
Maximum of released memory in single GGC run: 2930k
Garbage: 42982k
Leak: 6094k
Overhead: 5657k
GGC runs: 364
comparing combine.c compilation at -O1 level:
Amount of produced GGC garbage increased from 72112k to 72491k, overall 0.53%
Overall memory needed: 26609k -> 26617k
Peak memory use before GGC: 9293k -> 9298k
Peak memory use after GGC: 8736k -> 8737k
Maximum of released memory in single GGC run: 2065k -> 2066k
Garbage: 72112k -> 72491k
Leak: 6490k -> 6486k
Overhead: 11176k -> 11329k
GGC runs: 576 -> 579
comparing combine.c compilation at -O2 level:
Amount of produced GGC garbage increased from 87362k to 87883k, overall 0.60%
Overall memory needed: 29861k -> 29869k
Peak memory use before GGC: 12738k
Peak memory use after GGC: 12612k
Maximum of released memory in single GGC run: 2584k
Garbage: 87362k -> 87883k
Leak: 6310k
Overhead: 15730k -> 15972k
GGC runs: 576 -> 578
comparing combine.c compilation at -O3 level:
Amount of produced GGC garbage increased from 117244k to 117819k, overall 0.49%
Overall memory needed: 21428k -> 21448k
Peak memory use before GGC: 13179k
Peak memory use after GGC: 12612k
Maximum of released memory in single GGC run: 3419k
Garbage: 117244k -> 117819k
Leak: 6921k -> 6886k
Overhead: 20806k -> 21060k
GGC runs: 642 -> 647
comparing insn-attrtab.c compilation at -O0 level:
Overall memory needed: 118640k
Peak memory use before GGC: 79535k
Peak memory use after GGC: 46181k
Maximum of released memory in single GGC run: 43441k
Garbage: 163180k
Leak: 10646k
Overhead: 20460k
GGC runs: 307
comparing insn-attrtab.c compilation at -O1 level:
Overall memory needed: 131300k -> 131180k
Peak memory use before GGC: 89943k
Peak memory use after GGC: 70593k
Maximum of released memory in single GGC run: 42003k
Garbage: 462869k -> 463117k
Leak: 10990k
Overhead: 73908k -> 74020k
GGC runs: 465
comparing insn-attrtab.c compilation at -O2 level:
Overall memory needed: 206068k -> 206072k
Peak memory use before GGC: 105510k
Peak memory use after GGC: 86160k
Maximum of released memory in single GGC run: 35801k
Garbage: 512522k -> 512773k
Leak: 10910k
Overhead: 82004k -> 82117k
GGC runs: 384 -> 386
comparing insn-attrtab.c compilation at -O3 level:
Overall memory needed: 206068k -> 206076k
Peak memory use before GGC: 105512k
Peak memory use after GGC: 86162k
Maximum of released memory in single GGC run: 35801k
Garbage: 513811k -> 514062k
Leak: 10954k
Overhead: 82187k -> 82301k
GGC runs: 393 -> 395
comparing Gerald's testcase PR8361 compilation at -O0 level:
Overall memory needed: 112008k
Peak memory use before GGC: 88772k
Peak memory use after GGC: 87648k
Maximum of released memory in single GGC run: 19623k
Garbage: 253933k
Leak: 57113k
Overhead: 45784k
GGC runs: 369
comparing Gerald's testcase PR8361 compilation at -O1 level:
Amount of produced GGC garbage increased from 584766k to 599311k, overall 2.49%
Overall memory needed: 94572k
Peak memory use before GGC: 87755k
Peak memory use after GGC: 86603k
Maximum of released memory in single GGC run: 19231k
Garbage: 584766k -> 599311k
Leak: 59038k -> 59038k
Overhead: 125427k -> 129821k
GGC runs: 624 -> 633
comparing Gerald's testcase PR8361 compilation at -O2 level:
Amount of produced GGC garbage increased from 639086k to 655494k, overall 2.57%
Overall memory needed: 95408k
Peak memory use before GGC: 87755k
Peak memory use after GGC: 86604k
Maximum of released memory in single GGC run: 19231k
Garbage: 639086k -> 655494k
Leak: 59622k -> 59622k
Overhead: 149133k -> 154205k
GGC runs: 661 -> 684
comparing Gerald's testcase PR8361 compilation at -O3 level:
Overall memory allocated via mmap and sbrk increased from 102524k to 102700k, overall 0.17%
Amount of produced GGC garbage increased from 685451k to 701318k, overall 2.31%
Overall memory needed: 102524k -> 102700k
Peak memory use before GGC: 94818k
Peak memory use after GGC: 87983k
Maximum of released memory in single GGC run: 19962k
Garbage: 685451k -> 701318k
Leak: 59961k -> 59968k
Overhead: 160825k -> 165909k
GGC runs: 650 -> 664
Head of changelog is:
--- /usr/src/SpecTests/sandbox-britten-memory/x86_64/mem-result/ChangeLog 2004-10-27 15:50:18.000000000 +0000
+++ /usr/src/SpecTests/sandbox-britten-memory/gcc/gcc/ChangeLog 2004-10-27 20:25:32.000000000 +0000
@@ -1,3 +1,147 @@
+2004-10-27 David Edelsohn <edelsohn@gnu.org>
+
+ PR target/17956
+ * config/rs6000/rs6000.md (maxsf3): Add !flag_trapping_math to
+ final condition.
+ (minsf3): Same.
+ (maxdf3): Same.
+ (mindf3): Same.
+
+2004-10-27 Kazu Hirata <kazu@cs.umass.edu>
+
+ * tree-cfg.c (thread_jumps): Speed up by reordering the two
+ conditions for entering basic blocks into worklist.
+
+2004-10-27 Kazu Hirata <kazu@cs.umass.edu>
+
+ * tree-cfg.c (thread_jumps): Speed up by pretending to have
+ ENTRY_BLOCK_PTR in worklist.
+
+2004-10-27 Kazu Hirata <kazu@cs.umass.edu>
+
+ * tree-ssa-dce.c (mark_stmt_if_obviously_necessary)
+ <GOTO_EXPR>: Don't let an explicit GOTO_EXPR slip through.
+
+2004-10-27 Daniel Berlin <dberlin@dberlin.org>
+
+ Fix PR tree-optimization/17133
+
+ * tree-cfg.c (rewrite_to_new_ssa_names_bb): Also rewrite must
+ def kill operand.
+
+ * tree-flow-inline.h: V_MUST_DEF_OP became V_MUST_DEF_RESULT.
+ (get_v_must_def_result_ptr): Modify for new structure of
+ v_must_defs array.
+ (get_v_must_def_kill_ptr): New.
+ (op_iter_next_use): Add support for the kill that occurs in V_MUST_DEFs.
+ (op_iter_next_tree): Ditto. Also V_MAY_DEF_OP became V_MAY_DEF_RESULT.
+ (op_iter_next_def): V_MAY_DEF_OP became V_MAY_DEF_RESULT.
+ (op_iter_init): Initialize new mustu members.
+ (op_iter_next_mustdef): New function.
+ (op_iter_init_mustdef): Ditto.
+
+ * tree-flow.h (rewrite_def_def_chains): New function.
+
+ * tree-into-ssa.c (mark_def_sites): Handle mustdefkill operands.
+ (ssa_mark_def_sites): Ditto.
+ (rewrite_stmt): Ditto.
+ (ssa_rewrite_stmt): Ditto.
+ (rewrite_blocks): Factor out from rewrite_into_ssa.
+ (mark_def_block_sites): Ditto.
+ (rewrite_def_def_chains): New function, just rewrites def-def
+ chains without phi node insertion.
+
+ * tree-pass.h (TODO_fix_def_def_chains): New todo flag.
+
+ * tree-optimize.c (execute_todo): Handle TODO_fix_def_def_chains.
+
+ * tree-pretty-print.c (dump_vops): Print out MUST_DEF's so that
+ they include the rhs now.
+
+ * tree-ssa-ccp.c (visit_assignment): V_MUST_DEF_OP became
+ V_MUST_DEF_RESULT.
+
+ * tree-ssa-dce.c (mark_operand_necessary): Add phionly argument.
+ Update callers.
+ (mark_really_necessary_kill_operand_phis): New function.
+ (perform_tree_ssa_dce): Call it.
+ (pass_dce): Add TODO_fix_def_def_chains.
+ (pass_cd_dce): Ditto.
+
+ * tree-ssa-loop-im.c (determine_max_movement): Look at kills as
+ well.
+ (rewrite_mem_refs): Ditto.
+
+ * tree-ssa-loop-manip.c (find_uses_to_rename_stmt): Look at kills
+ as well.
+
+ * tree-ssa-operands.c (allocate_v_may_def_optype):
+ v_may_def_operand_type_t became v_def_use_operand_type_t.
+ (allocate_v_must_def_optype) Ditto.
+ (finalize_ssa_v_must_defs): Update for new operand type, as well
+ as setting the use portion as well.
+ (copy_virtual_operands): Copy the kill operand as well.
+ (create_ssa_artficial_load_stmt): V_MUST_DEF_OP became
+ V_MUST_DEF_RESULT.
+
+ * tree-ssa-operands.h (v_may_def_operand_type): Renamed to
+ v_def_use_operand_type.
+ (v_must_def_optype_d): Use v_def_use_operand_type.
+ (V_MUST_DEF_OP_*): Renamed to V_MUST_DEF_RESULT_*
+ (V_MUST_DEF_KILL_*): New macros.
+ (struct ssa_operand_iterator_d): Add num_v_mustu and v_mustu_i
+ members.
+ Rename existing must_i and num_v_must members to mustd_i and
+ num_v_mustd.
+ (SSA_OP_VMUSTDEFKILL): New flag.
+ (SSA_OP_VIRTUAL_KILLS): New flag.
+ (SSA_OP_ALL_OPERANDS): Add in SSA_OP_ALL_KILLS.
+ (SSA_OP_ALL_KILLS): New flag.
+ (FOR_EACH_SSA_MUSTDEF_OPERAND): New macro.
+
+ * tree-ssa.c (verify_ssa): Verify virtual kills as well.
+
+ * tree-vectorizer.c (vect_create_data_ref_ptr): V_MUST_DEF_OP
+ became V_MUST_DEF_RESULT.
+ (rename_variables_in_bb): Rename kill pointer as well.
+
+ * tree-dfa.c (compute_immediate_uses_for_stmt): Add kills into the
+ immediate uses.
+
+2004-10-27 Richard Sandiford <rsandifo@redhat.com>
+
+ * dbxout.c (dbxout_source_line): Move declaration of begin_label to
+ the block that needs it.
+
+2004-10-27 Zack Weinberg <zack@codesourcery.com>
+
+ * dbxout.c (dbxout_finish_complex_stabs): Mark 'line' variable
+ ATTRIBUTE_UNUSED.
+
+2004-10-27 Zack Weinberg <zack@codesourcery.com>
+
+ * c-lex.c (cb_def_pragma): Clean up code for making location
+ palatable to diagnostic.c.
+
+2004-10-27 Steven Bosscher <stevenb@suse.de>
+
+ PR tree-optimization/17757
+ * tree-phinodes.c (remove_phi_arg_num): Don't remove PHIs
+ without any PHI arguments left. Make sure the argument that
+ we're supposed to remove exists at all.
+
+2004-10-27 Paul Brook <paul@codesourcery.com>
+
+ * configure.ac: Don't test for [build] __cxa_atexit when building a
+ cross compiler.
+ * configure: Regenerate.
+
+2004-10-27 Paul Brook <paul@codeosurcery.com>
+
+ * configure.ac: Use build_exeext not host_exeext when lookin for
+ target tools.
+ * configure: Regenerate.
+
2004-10-27 Andreas Krebbel <krebbel1@de.ibm.com>
* config/s390/s390.md ("*subdf3_cc"): Replaced plus by minus.
@@ -6,7 +150,7 @@
patch originally created by Kelley Cook <kcook@gcc.gnu.org>
PR middle-end/14684
- * opts.c (OPT_fprofile_generate): Default to -funroll-loops
+ * opts.c (OPT_fprofile_generate): Default to -funroll-loops
to match -fprofile-use.
2004-10-27 Kazu Hirata <kazu@cs.umass.edu>
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.