aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--gcc/ChangeLog6
-rw-r--r--gcc/combine.c3
2 files changed, 8 insertions, 1 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index e1ab542..0fef1ea 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,5 +1,11 @@
2006-02-24 Roger Sayle <roger@eyesopen.com>
+ PR middle-end/24952
+ * combine.c (try_combine): Explicitly check whether GET_CODE is
+ a SET or a CLOBBER, instead on checking that it isn't a USE.
+
+2006-02-24 Roger Sayle <roger@eyesopen.com>
+
* fold-const.c (fold_comparison): New subroutine of fold_binary
containing transformations common to both the equality and
ordering relational operators, factored out of fold_binary.
diff --git a/gcc/combine.c b/gcc/combine.c
index 9240b32..d6f1079 100644
--- a/gcc/combine.c
+++ b/gcc/combine.c
@@ -3123,7 +3123,8 @@ try_combine (rtx i3, rtx i2, rtx i1, int *new_direct_jump_p)
if (i3_subst_into_i2)
{
for (i = 0; i < XVECLEN (PATTERN (i2), 0); i++)
- if (GET_CODE (XVECEXP (PATTERN (i2), 0, i)) != USE
+ if ((GET_CODE (XVECEXP (PATTERN (i2), 0, i)) == SET
+ || GET_CODE (XVECEXP (PATTERN (i2), 0, i)) == CLOBBER)
&& REG_P (SET_DEST (XVECEXP (PATTERN (i2), 0, i)))
&& SET_DEST (XVECEXP (PATTERN (i2), 0, i)) != i2dest
&& ! find_reg_note (i2, REG_UNUSED,