[PATCH] D90614: [lld-macho] Handle paired relocs
Greg McGary via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Nov 2 07:51:26 PST 2020
gkm created this revision.
gkm added a reviewer: lld-macho.
Herald added subscribers: llvm-commits, pengfei, kristof.beyls.
Herald added a project: LLVM.
gkm requested review of this revision.
This is a refactor to pave the way for supporting paired-ADDEND for ARM64. The only paired reloc type for X86_64 is SUBTRACTOR. In a later diff, I will add SUBTRACTOR for both X86_64 and ARM64.
- s/`getImplicitAddend`/`getAddend`/ because it handles all forms of addend: implicit, explicit, paired.
- add predicate `bool isPairedReloc()`
- check range of `relInfo.r_symbolnum` is internal, unrelated to user-input, so use `assert()`, not `error()`
- minor cleanups & rearrangements in `InputFile::parseRelocations()`
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D90614
Files:
lld/MachO/Arch/X86_64.cpp
lld/MachO/InputFiles.cpp
lld/MachO/Target.h
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D90614.302283.patch
Type: text/x-patch
Size: 4855 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20201102/bd6b83d2/attachment.bin>
More information about the llvm-commits
mailing list