From abfbac52df836460392186a61619fe266b40fa8c Mon Sep 17 00:00:00 2001 From: Daniel Dunbar Date: Tue, 14 Dec 2010 17:37:16 +0000 Subject: [PATCH] MC/ARM: Fix-up fixup offset for fixup_arm_branch target specific fixup. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@121772 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Target/ARM/ARMMCCodeEmitter.cpp | 2 +- test/MC/ARM/arm_fixups.s | 7 +++++++ 2 files changed, 8 insertions(+), 1 deletion(-) create mode 100644 test/MC/ARM/arm_fixups.s diff --git a/lib/Target/ARM/ARMMCCodeEmitter.cpp b/lib/Target/ARM/ARMMCCodeEmitter.cpp index b82d38ed725..0924591a60c 100644 --- a/lib/Target/ARM/ARMMCCodeEmitter.cpp +++ b/lib/Target/ARM/ARMMCCodeEmitter.cpp @@ -58,7 +58,7 @@ public: { "fixup_arm_adr_pcrel_12", 1, 24, MCFixupKindInfo::FKF_IsPCRel }, { "fixup_t2_adr_pcrel_12", 0, 32, MCFixupKindInfo::FKF_IsPCRel | MCFixupKindInfo::FKF_IsAligned}, -{ "fixup_arm_branch", 1, 24, MCFixupKindInfo::FKF_IsPCRel }, +{ "fixup_arm_branch", 0, 24, MCFixupKindInfo::FKF_IsPCRel }, { "fixup_t2_condbranch", 0, 32, MCFixupKindInfo::FKF_IsPCRel }, { "fixup_t2_uncondbranch", 0, 32, MCFixupKindInfo::FKF_IsPCRel }, { "fixup_arm_thumb_br", 0, 16, MCFixupKindInfo::FKF_IsPCRel }, diff --git a/test/MC/ARM/arm_fixups.s b/test/MC/ARM/arm_fixups.s new file mode 100644 index 00000000000..146de9cf26c --- /dev/null +++ b/test/MC/ARM/arm_fixups.s @@ -0,0 +1,7 @@ +// RUN: llvm-mc -triple arm-unknown-unknown %s --show-encoding > %t +// RUN: FileCheck < %t %s + +// CHECK: bl _printf @ encoding: [A,A,A,0xeb] +// CHECK: @ fixup A - offset: 0, value: _printf, kind: fixup_arm_branch +bl _printf + \ No newline at end of file -- 2.34.1