aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGlen Nakamura <glen@imodulo.com>2002-09-08 03:42:46 +0000
committerRichard Henderson <rth@gcc.gnu.org>2002-09-07 20:42:46 -0700
commitb96a3fa3970cfa7a81ab2cfb2f3f8fe328dae722 (patch)
treee58b44075fef687cbfd1781d5a651e02ae19726d
parentad9df12ff5182840605b6252b882d36c0f68895c (diff)
downloadgcc-b96a3fa3970cfa7a81ab2cfb2f3f8fe328dae722.zip
gcc-b96a3fa3970cfa7a81ab2cfb2f3f8fe328dae722.tar.gz
gcc-b96a3fa3970cfa7a81ab2cfb2f3f8fe328dae722.tar.bz2
sched-deps.c (sched_analyze_insn): Make sure to add insn to reg_last->sets after flushing the dependency lists to...
* sched-deps.c (sched_analyze_insn): Make sure to add insn to reg_last->sets after flushing the dependency lists to guarantee that subsequent clobbers will be dependent on it. From-SVN: r56929
-rw-r--r--gcc/ChangeLog6
-rw-r--r--gcc/sched-deps.c3
2 files changed, 7 insertions, 2 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 9ca0341..5dadbed 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,9 @@
+2002-09-07 Glen Nakamura <glen@imodulo.com>
+
+ * sched-deps.c (sched_analyze_insn): Make sure to add insn
+ to reg_last->sets after flushing the dependency lists to guarantee
+ that subsequent clobbers will be dependent on it.
+
2002-09-07 Igor Shevlyakov <igor@microunity.com>
* combine.c (simplify_shift_const): Calculate rotate count
diff --git a/gcc/sched-deps.c b/gcc/sched-deps.c
index a5e9c08..32260a8 100644
--- a/gcc/sched-deps.c
+++ b/gcc/sched-deps.c
@@ -1117,8 +1117,6 @@ sched_analyze_insn (deps, x, insn, loop_notes)
EXECUTE_IF_SET_IN_REG_SET (reg_pending_clobbers, 0, i,
{
struct deps_reg *reg_last = &deps->reg_last[i];
- add_dependence_list (insn, reg_last->sets, REG_DEP_OUTPUT);
- add_dependence_list (insn, reg_last->uses, REG_DEP_ANTI);
if (reg_last->uses_length > MAX_PENDING_LIST_LENGTH
|| reg_last->clobbers_length > MAX_PENDING_LIST_LENGTH)
{
@@ -1128,6 +1126,7 @@ sched_analyze_insn (deps, x, insn, loop_notes)
REG_DEP_ANTI);
add_dependence_list_and_free (insn, &reg_last->clobbers,
REG_DEP_OUTPUT);
+ reg_last->sets = alloc_INSN_LIST (insn, reg_last->sets);
reg_last->clobbers_length = 0;
reg_last->uses_length = 0;
}