summaryrefslogtreecommitdiff
path: root/gcc/sel-sched.c
diff options
context:
space:
mode:
authorabel <abel@138bc75d-0d04-0410-961f-82ee72b054a4>2009-11-13 14:27:13 +0000
committerabel <abel@138bc75d-0d04-0410-961f-82ee72b054a4>2009-11-13 14:27:13 +0000
commitd9ab20389238e942494df234f54a473bb02cec96 (patch)
tree33d70889d193e4a1474e119c509e0e1fcd50b507 /gcc/sel-sched.c
parent375866ee59eebb08077a51c31b8e04251ac7248e (diff)
downloadgcc-d9ab20389238e942494df234f54a473bb02cec96.tar.gz
2009-11-13 Andrey Belevantsev <abel@ispras.ru>
* sched-deps.c (init_deps): New parameter lazy_reg_last. Don't allocate reg_last when in case lazy_reg_last is true. (init_deps_reg_last): New. (free_deps): When max_reg is 0, this context is already freed. * sched-int.h (init_deps_reg_last): Export. (init_deps): Update prototype. * sched-ebb.c (schedule_ebb): Update the call to init_deps. * sched-rgn.c (sched_rgn_compute_dependencies): Likewise. * ddg.c (build_intra_loop_deps): Likewise. * sel-sched-ir.c (copy_deps_context, create_deps_context, reset_deps_context, deps_init_id): Likewise. (init_first_time_insn_data): Lazy allocate INSN_DEPS_CONTEXT. (free_data_for_scheduled_insn): New, break down from ... (free_first_time_insn_data): ... here. (has_dependence_p): Allocate reg_last now, when it is needed. (extend_insn_data): When maximal LUID is big enough, allocate per-insn data in smaller chunks. * sel-sched-ir.h (free_data_for_scheduled_insn): Export. * sel-sched.c (update_seqnos_and_stage): Free INSN_DEPS_CONTEXT in scheduled insn. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@154147 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/sel-sched.c')
-rw-r--r--gcc/sel-sched.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/gcc/sel-sched.c b/gcc/sel-sched.c
index 102dc19187f..05061c7ed71 100644
--- a/gcc/sel-sched.c
+++ b/gcc/sel-sched.c
@@ -7364,6 +7364,12 @@ update_seqnos_and_stage (int min_seqno, int max_seqno,
gcc_assert (INSN_SEQNO (insn) < 0);
INSN_SEQNO (insn) += highest_seqno_in_use + max_seqno - min_seqno + 2;
gcc_assert (INSN_SEQNO (insn) <= new_hs);
+
+ /* When not pipelining, purge unneeded insn info on the scheduled insns.
+ For example, having reg_last array of INSN_DEPS_CONTEXT in memory may
+ require > 1GB of memory e.g. on limit-fnargs.c. */
+ if (! pipelining_p)
+ free_data_for_scheduled_insn (insn);
}
ilist_clear (pscheduled_insns);