aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorRoger Sayle <roger@eyesopen.com>2004-01-28 01:37:28 +0000
committerRoger Sayle <sayle@gcc.gnu.org>2004-01-28 01:37:28 +0000
commit4cce9dd84a4d942ad6a443038aa80f301aa3784a (patch)
treef37ee05d8f3f230e770e13da4c32b29a90ffea11 /gcc
parentc4ef652567d278d63cd55d7730db2808eb098564 (diff)
downloadgcc-4cce9dd84a4d942ad6a443038aa80f301aa3784a.zip
gcc-4cce9dd84a4d942ad6a443038aa80f301aa3784a.tar.gz
gcc-4cce9dd84a4d942ad6a443038aa80f301aa3784a.tar.bz2
pa.c (emit_move_sequence): Check that operand1 is a CONST_INT before using INTVAL.
* config/pa/pa.c (emit_move_sequence): Check that operand1 is a CONST_INT before using INTVAL. From-SVN: r76776
Diffstat (limited to 'gcc')
-rw-r--r--gcc/ChangeLog5
-rw-r--r--gcc/config/pa/pa.c5
2 files changed, 9 insertions, 1 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 9b73990..0b68192 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,8 @@
+2004-01-27 Roger Sayle <roger@eyesopen.com>
+
+ * config/pa/pa.c (emit_move_sequence): Check that operand1 is a
+ CONST_INT before using INTVAL.
+
2004-01-27 Ulrich Weigand <uweigand@de.ibm.com>
* config/s390/s390.h (TARGET_DEFAULT): Default to !TARGET_BACKCHAIN.
diff --git a/gcc/config/pa/pa.c b/gcc/config/pa/pa.c
index 9328531..31883ce 100644
--- a/gcc/config/pa/pa.c
+++ b/gcc/config/pa/pa.c
@@ -1990,10 +1990,13 @@ emit_move_sequence (rtx *operands, enum machine_mode mode, rtx scratch_reg)
{
rtx insn, temp;
rtx op1 = operand1;
- HOST_WIDE_INT value = INTVAL (operand1);
+ HOST_WIDE_INT value = 0;
HOST_WIDE_INT insv = 0;
int insert = 0;
+ if (GET_CODE (operand1) == CONST_INT)
+ value = INTVAL (operand1);
+
if (TARGET_64BIT
&& GET_CODE (operand1) == CONST_INT
&& HOST_BITS_PER_WIDE_INT > 32