diff options
author | Jiong Wang <jiong.wang@arm.com> | 2014-07-15 10:15:43 +0100 |
---|---|---|
committer | Jiong Wang <jiong.wang@arm.com> | 2014-07-15 10:15:43 +0100 |
commit | 19f2f6a9c4aeb0e37d448cb5593164e25ab055a9 (patch) | |
tree | c0641978c05fc4489b2aded90ba5d3df0ec85bd1 /gas/config | |
parent | d6f18fe6cac35e68f86bda603620ebacaf59b1e6 (diff) | |
download | gdb-19f2f6a9c4aeb0e37d448cb5593164e25ab055a9.zip gdb-19f2f6a9c4aeb0e37d448cb5593164e25ab055a9.tar.gz gdb-19f2f6a9c4aeb0e37d448cb5593164e25ab055a9.tar.bz2 |
[ARM] Fix 32-bit host build failure.
gas/
* config/tc-arm.c (add_to_lit_pool): Use "inst.operands[1].imm" for * sign
extension. Casting the type of imm1 and imm2 to offsetT. Fix one logic
error when checking X_op.
Diffstat (limited to 'gas/config')
-rw-r--r-- | gas/config/tc-arm.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/gas/config/tc-arm.c b/gas/config/tc-arm.c index 2f13238..7fb8b23 100644 --- a/gas/config/tc-arm.c +++ b/gas/config/tc-arm.c @@ -3198,7 +3198,7 @@ add_to_lit_pool (unsigned int nbytes) imm1 = inst.operands[1].imm; imm2 = (inst.operands[1].regisimm ? inst.operands[1].reg : inst.reloc.exp.X_unsigned ? 0 - : ((int64_t)(imm1)) >> 32); + : ((int64_t) inst.operands[1].imm) >> 32); if (target_big_endian) { imm1 = imm2; @@ -3237,11 +3237,11 @@ add_to_lit_pool (unsigned int nbytes) && !(pool_size & 0x7) && ((entry + 1) != pool->next_free_entry) && (pool->literals[entry].X_op == O_constant) - && (pool->literals[entry].X_add_number == imm1) + && (pool->literals[entry].X_add_number == (offsetT) imm1) && (pool->literals[entry].X_unsigned == inst.reloc.exp.X_unsigned) && (pool->literals[entry + 1].X_op == O_constant) - && (pool->literals[entry + 1].X_add_number == imm2) + && (pool->literals[entry + 1].X_add_number == (offsetT) imm2) && (pool->literals[entry + 1].X_unsigned == inst.reloc.exp.X_unsigned)) break; @@ -3275,8 +3275,8 @@ add_to_lit_pool (unsigned int nbytes) We also check to make sure the literal operand is a constant number. */ - if (!(inst.reloc.exp.X_op == O_constant) - || (inst.reloc.exp.X_op == O_big)) + if (!(inst.reloc.exp.X_op == O_constant + || inst.reloc.exp.X_op == O_big)) { inst.error = _("invalid type for literal pool"); return FAIL; |