aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGeoffrey Keating <geoffk@redhat.com>2001-12-28 07:52:44 +0000
committerGeoffrey Keating <geoffk@gcc.gnu.org>2001-12-28 07:52:44 +0000
commit2ef1a7f9609e556bde6f458b25abd95adc6ff45a (patch)
tree6ace5950184cf3d94b730d7ca56487d5f8646789
parent19f90fadbcd3565ba91d012c04df729acc917e21 (diff)
downloadgcc-2ef1a7f9609e556bde6f458b25abd95adc6ff45a.zip
gcc-2ef1a7f9609e556bde6f458b25abd95adc6ff45a.tar.gz
gcc-2ef1a7f9609e556bde6f458b25abd95adc6ff45a.tar.bz2
combine.c (try_combine): Mask off sign bits when combining stores to the low and high parts of a...
* combine.c (try_combine): Mask off sign bits when combining stores to the low and high parts of a two-word value. From-SVN: r48339
-rw-r--r--gcc/ChangeLog3
-rw-r--r--gcc/combine.c3
2 files changed, 5 insertions, 1 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 6af9545..b11afd8 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,5 +1,8 @@
2001-12-27 Geoff Keating <geoffk@redhat.com>
+ * combine.c (try_combine): Mask off sign bits when combining
+ stores to the low and high parts of a two-word value.
+
* expr.c (expand_expr): Don't mark memory for non-constants as
constant.
diff --git a/gcc/combine.c b/gcc/combine.c
index 1fa63b8..a25909d 100644
--- a/gcc/combine.c
+++ b/gcc/combine.c
@@ -1650,7 +1650,8 @@ try_combine (i3, i2, i1, new_direct_jump_p)
abort ();
lo &= ~(UWIDE_SHIFT_LEFT_BY_BITS_PER_WORD (1) - 1);
- lo |= INTVAL (SET_SRC (PATTERN (i3)));
+ lo |= (INTVAL (SET_SRC (PATTERN (i3)))
+ & (UWIDE_SHIFT_LEFT_BY_BITS_PER_WORD (1) - 1));
}
else if (HOST_BITS_PER_WIDE_INT == BITS_PER_WORD)
hi = INTVAL (SET_SRC (PATTERN (i3)));