From ef78dbdcc9703ee22ddb8d0aa4cbbb7328a26e1d Mon Sep 17 00:00:00 2001 From: Paul Brook Date: Fri, 29 Jul 2005 17:39:39 +0000 Subject: [PATCH] 2005-07-29 Paul Brook bfd/ * reloc.c: Add BFD_RELOC_ARM_T32_ADD_PC12. * bfd-in2.h: Regenerate. * libbfd.h: Regenerate. gas/ * config/tc-arm.c (T16_32_TAB): Add "addr". Fix encoding of push and pop. (do_t_addr): Implement 32-bit variant. (do_t_push_pop): Make some errors warnings. Handle single register 32-bit case. (insns): Use tCE for adr. (md_pcrel_from_section): Handle BFD_RELOC_ARM_T32_ADD_PC12. (md_apply_fix): Ditto. gas/testsuite/ * gas/arm/thumb32.d: Fix expected output for writeback addressing modes. Add single high reg push/pop test. * gas/asm/thumb32.s: Add single high reg push/pop test. opcodes/ * arm-dis.c: Fix disassebly of thumb2 writeback addressing modes. --- bfd/ChangeLog | 6 ++++++ bfd/bfd-in2.h | 1 + bfd/libbfd.h | 1 + bfd/reloc.c | 2 ++ opcodes/ChangeLog | 4 ++++ opcodes/arm-dis.c | 8 ++++---- 6 files changed, 18 insertions(+), 4 deletions(-) diff --git a/bfd/ChangeLog b/bfd/ChangeLog index c016e7fe70..b52a2eccdb 100644 --- a/bfd/ChangeLog +++ b/bfd/ChangeLog @@ -1,5 +1,11 @@ 2005-07-29 Paul Brook + * reloc.c: Add BFD_RELOC_ARM_T32_ADD_PC12. + * bfd-in2.h: Regenerate. + * libbfd.h: Regenerate. + +2005-07-29 Paul Brook + * reloc.c (BFD_RELOC_ARM_T32_IMM12): Add. * bfd-in2.h: Regeenrate. * libbfd.h: Regenerate. diff --git a/bfd/bfd-in2.h b/bfd/bfd-in2.h index 2db99a4494..e8c597266e 100644 --- a/bfd/bfd-in2.h +++ b/bfd/bfd-in2.h @@ -2881,6 +2881,7 @@ pc-relative or some form of GOT-indirect relocation. */ BFD_RELOC_ARM_ADRL_IMMEDIATE, BFD_RELOC_ARM_T32_IMMEDIATE, BFD_RELOC_ARM_T32_IMM12, + BFD_RELOC_ARM_T32_ADD_PC12, BFD_RELOC_ARM_SHIFT_IMM, BFD_RELOC_ARM_SMI, BFD_RELOC_ARM_SWI, diff --git a/bfd/libbfd.h b/bfd/libbfd.h index 51aa3c976b..62173e0102 100644 --- a/bfd/libbfd.h +++ b/bfd/libbfd.h @@ -1212,6 +1212,7 @@ static const char *const bfd_reloc_code_real_names[] = { "@@uninitialized@@", "BFD_RELOC_ARM_ADRL_IMMEDIATE", "BFD_RELOC_ARM_T32_IMMEDIATE", "BFD_RELOC_ARM_T32_IMM12", + "BFD_RELOC_ARM_T32_ADD_PC12", "BFD_RELOC_ARM_SHIFT_IMM", "BFD_RELOC_ARM_SMI", "BFD_RELOC_ARM_SWI", diff --git a/bfd/reloc.c b/bfd/reloc.c index 7c2ccdbc33..77b4feb4ef 100644 --- a/bfd/reloc.c +++ b/bfd/reloc.c @@ -2738,6 +2738,8 @@ ENUMX ENUMX BFD_RELOC_ARM_T32_IMM12 ENUMX + BFD_RELOC_ARM_T32_ADD_PC12 +ENUMX BFD_RELOC_ARM_SHIFT_IMM ENUMX BFD_RELOC_ARM_SMI diff --git a/opcodes/ChangeLog b/opcodes/ChangeLog index 539252e50f..f02e00717c 100644 --- a/opcodes/ChangeLog +++ b/opcodes/ChangeLog @@ -1,5 +1,9 @@ 2005-07-29 Paul Brook + * arm-dis.c: Fix disassebly of thumb2 writeback addressing modes. + +2005-07-29 Paul Brook + * arm-dis.c (thumb32_opc): Fix addressing mode for tbh. (print_insn_thumb32): Fix decoding of thumb2 'I' operands. diff --git a/opcodes/arm-dis.c b/opcodes/arm-dis.c index 14b9901ea0..dbf91be9e0 100644 --- a/opcodes/arm-dis.c +++ b/opcodes/arm-dis.c @@ -2253,22 +2253,22 @@ print_insn_thumb32 (bfd_vma pc, struct disassemble_info *info, long given) offset = -i8; break; - case 0xB: /* 8-bit + preindex with wb */ + case 0xF: /* 8-bit + preindex with wb */ offset = i8; writeback = TRUE; break; - case 0x9: /* 8-bit - preindex with wb */ + case 0xD: /* 8-bit - preindex with wb */ offset = -i8; writeback = TRUE; break; - case 0xF: /* 8-bit + postindex */ + case 0xB: /* 8-bit + postindex */ offset = i8; postind = TRUE; break; - case 0xD: /* 8-bit - postindex */ + case 0x9: /* 8-bit - postindex */ offset = -i8; postind = TRUE; break; -- 2.11.0