aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--gcc/ChangeLog2
-rw-r--r--gcc/loop-iv.c2
2 files changed, 4 insertions, 0 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 13aa778..d1ce533 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -4,6 +4,8 @@
(determine_max_iter): Take additional LOOP arg; all callers changed.
Lose broken logic dealing with PLUS. Try to limit the upper bound by
one using simplifications.
+ (simplify_using_initial_values): Return if the expression becomes
+ invalid due to altered regs.
2007-02-23 DJ Delorie <dj@redhat.com>
diff --git a/gcc/loop-iv.c b/gcc/loop-iv.c
index fb0ec45..21005d3 100644
--- a/gcc/loop-iv.c
+++ b/gcc/loop-iv.c
@@ -1811,6 +1811,8 @@ simplify_using_initial_values (struct loop *loop, enum rtx_code op, rtx *expr)
FREE_REG_SET (altered);
return;
}
+ if (for_each_rtx (expr, altered_reg_used, altered))
+ return;
}
if (!single_pred_p (e->src)