aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--gcc/ChangeLog6
-rw-r--r--gcc/combine.c2
2 files changed, 7 insertions, 1 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 033fc4b..f5cfca8 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,9 @@
+2002-06-28 Stephen Clarke <stephen.clarke@superh.com>
+
+ * combine.c (combine_simplify_rtx): Pass the mode of the
+ shift count, not the shift operation when trying to simplify
+ a shift on a SHIFT_COUNT_TRUNCATED target.
+
2002-06-28 Stephane Carrez <stcarrez@nerim.fr>
* config/m68hc11/m68hc11.md ("*addsi3"): Use 'o' constraint to
diff --git a/gcc/combine.c b/gcc/combine.c
index ea12b13..c94eddc 100644
--- a/gcc/combine.c
+++ b/gcc/combine.c
@@ -4583,7 +4583,7 @@ combine_simplify_rtx (x, op0_mode, last, in_dest)
#ifdef SHIFT_COUNT_TRUNCATED
else if (SHIFT_COUNT_TRUNCATED && GET_CODE (XEXP (x, 1)) != REG)
SUBST (XEXP (x, 1),
- force_to_mode (XEXP (x, 1), GET_MODE (x),
+ force_to_mode (XEXP (x, 1), GET_MODE (XEXP (x, 1)),
((HOST_WIDE_INT) 1
<< exact_log2 (GET_MODE_BITSIZE (GET_MODE (x))))
- 1,