[patch] Arm 64-bit host fix.
Paul Brook
paul@codesourcery.com
Thu Sep 14 15:23:00 GMT 2006
The patch below fixes a failure in thumb_add.s on 64-bit hosts.
Mismatches between the types used was causing the == FAIL check to fail.
Tested with cross to arm-none-eabi on x86 and x86_64.
Ok?
Paul
2006-09-14 Paul Brook <paul@codesourcery.com>
* config/tc-arm.c (thumb32_negate_data_op): Consistently use
unsigned int to avoid 64-bit host problems.
Index: gas/config/tc-arm.c
===================================================================
RCS file: /var/cvsroot/src-cvs/src/gas/config/tc-arm.c,v
retrieving revision 1.250.2.33
diff -u -p -r1.250.2.33 tc-arm.c
--- gas/config/tc-arm.c 14 Sep 2006 13:57:36 -0000 1.250.2.33
+++ gas/config/tc-arm.c 14 Sep 2006 15:14:19 -0000
@@ -17215,11 +17226,11 @@ negate_data_op (unsigned long * instruct
/* Like negate_data_op, but for Thumb-2. */
static unsigned int
-thumb32_negate_data_op (offsetT *instruction, offsetT value)
+thumb32_negate_data_op (offsetT *instruction, unsigned int value)
{
int op, new_inst;
int rd;
- offsetT negated, inverted;
+ unsigned int negated, inverted;
negated = encode_thumb32_immediate (-value);
inverted = encode_thumb32_immediate (~value);
@@ -17280,7 +17291,7 @@ thumb32_negate_data_op (offsetT *instruc
return FAIL;
}
- if (value == FAIL)
+ if (value == (unsigned int)FAIL)
return FAIL;
*instruction &= T2_OPCODE_MASK;
More information about the Binutils
mailing list