mirror of
https://github.com/capstone-engine/llvm-capstone.git
synced 2024-12-14 03:29:57 +00:00
9d6ec280fc
For each R_X86_64_(REX_)GOTPCRELX relocation, check that the offset to the symbol is representable with 2^32 signed offset. If not, add a GOT entry for it and set its expr to R_GOT_PC so that we emit the GOT load instead of the relaxed lea. Do this in finalizeAddressDependentContent() where we iteratively attempt this (e.g. RISCV uses this for relaxation, ARM uses this to insert thunks). Decided not to do the opposite of inserting GOT entries initially and removing them when relaxable because removing GOT entries isn't simple. One drawback of this approach is that if we see any GOTPCRELX relocation, we'll create an empty .got even if it's not required in the end. Reviewed By: MaskRay Differential Revision: https://reviews.llvm.org/D157020 |
||
---|---|---|
.. | ||
COFF | ||
ELF | ||
MachO | ||
MinGW | ||
Unit | ||
wasm | ||
CMakeLists.txt | ||
lit.cfg.py | ||
lit.site.cfg.py.in |