llvm-project/llvm/test/MC
Peter Smith 2a92fc9b8e [MC][ELF][ARM] Add relocations for some pc-relative fixups
Add ELF relocations for the following fixups:
fixup_thumb_adr_pcrel_10 -> R_ARM_THM_PC8
fixup_thumb_cp -> R_ARM_THM_PC8
fixup_t2_adr_pcrel_12 -> R_ARM_THM_PREL_11_0
fixup_t2_ldst_pcrel_12 -> R_ARM_THM_PC12

While these relocations are short-ranged there is support in the open
source ELF linker's in binutils and soon to be in LLD. MC will no longer
resolve pc-relative fixups to global symbols due to interpositioning
concerns. We can handle these at link time by implementing the relocations.

The R_ARM_THM_PC8 has some extra encoding rules for addends that llvm-mc
sidesteps by not supporting addends for these instructions, using the wide
Thumb 2 instruction if it is available. I think that this is a reasonable
compromise given that these are rare.

This partiall reverts D72892, the Thumb fixups no longer need to be
evaluated at assembly time.

Differential Revision: https://reviews.llvm.org/D75039
2020-02-28 11:29:29 +00:00
..
AArch64 [AArch64][SVE] Add intrinsics for SVE2 bitwise ternary operations 2020-02-21 12:15:51 -05:00
AMDGPU [AMDGPU] Use @LINE for error checking in gfx10 assembler tests 2020-02-07 18:27:07 +00:00
ARM [MC][ELF][ARM] Add relocations for some pc-relative fixups 2020-02-28 11:29:29 +00:00
AVR [AVR] Don't adjust addresses by 2 for absolute values 2020-02-26 20:32:24 +01:00
AsmParser [AsmParser] Make generic directives and aliases case insensitive. 2020-01-17 11:02:56 +00:00
BPF [lit] Delete empty lines at the end of lit.local.cfg NFC 2019-06-17 09:51:07 +00:00
COFF Revert "Revert "Reland "[Support] make report_fatal_error `abort` instead of `exit`""" 2020-02-13 10:16:06 -08:00
Disassembler [ARM] Add initial support for Custom Datapath Extension (CDE) 2020-02-17 15:39:16 +00:00
ELF [MC][ELF] Error for sh_type, sh_flags or sh_entsize change 2020-02-21 15:44:14 -08:00
Hexagon [Hexagon] v67+ HVX register pairs should support either direction 2020-02-14 12:43:43 -06:00
Lanai [lit] Delete empty lines at the end of lit.local.cfg NFC 2019-06-17 09:51:07 +00:00
MSP430 [lit] Delete empty lines at the end of lit.local.cfg NFC 2019-06-17 09:51:07 +00:00
MachO [MC][ARM] Resolve some pcrel fixups at assembly time (PR44929) 2020-02-27 12:43:29 +01:00
Mips [DebugInfo] Fix printing CIE offsets in EH FDEs. 2020-02-25 17:10:29 +07:00
PowerPC Revert "Revert "Reland "[Support] make report_fatal_error `abort` instead of `exit`""" 2020-02-13 10:16:06 -08:00
RISCV [MC] De-capitalize another set of MCStreamer::Emit* functions 2020-02-14 19:26:52 -08:00
Sparc [lit] Delete empty lines at the end of lit.local.cfg NFC 2019-06-17 09:51:07 +00:00
SystemZ [SystemZ] Improve handling of huge PC relative immediate offsets. 2019-11-04 10:38:18 +01:00
WebAssembly [WebAssembly] Use llvm::Optional to store optional symbol attributes. NFC. 2020-02-19 17:25:33 -08:00
X86 Emit register names in cfi assembly directives 2020-02-25 14:00:01 -05:00