[PATCH] D71519: [ELF] Add IpltSection

Fangrui Song via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sat Dec 14 18:13:05 PST 2019


MaskRay created this revision.
MaskRay added reviewers: grimar, peter.smith, ruiu.
Herald added subscribers: llvm-commits, luismarques, apazos, sameer.abuasal, pzheng, s.egerton, lenary, jsji, jocewei, PkmX, the_o, brucehoult, MartinMosbeck, rogfer01, edward-jones, zzheng, jrtc27, niosHD, sabuasal, simoncook, johnrusso, rbar, asb, kbarton, arichardson, nemanjai, emaste.
Herald added a reviewer: espindola.
Herald added a project: LLVM.
MaskRay added a parent revision: D71518: [ELF] Delete relOff from TargetInfo::writePLT.
Herald added a subscriber: wuzish.
MaskRay added a child revision: D71520: [ELF] Rename .plt to .iplt and decrease EM_PPC64 alignment of .glink to 4.

PltSection is used by both PLT and IPLT. Some of its actions are
dispatched on `isIplt`. Create IpltSection to untangle its rules.

Change PltSection::isNeeded so that it will be retained if -z
retpolineplt and IPLT is not empty.  This simplifies the logic that
creates a canonical PLT for a non-preemptible IFUNC.

Unlike other targets, PPC64 cannot use the same code sequence for PLT
and IPLT. This change helps make a future PPC64 patch (D71509 <https://reviews.llvm.org/D71509>) more
isolated.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D71519

Files:
  lld/ELF/Arch/AArch64.cpp
  lld/ELF/Arch/ARM.cpp
  lld/ELF/Arch/PPC.cpp
  lld/ELF/Arch/PPC64.cpp
  lld/ELF/Arch/RISCV.cpp
  lld/ELF/Arch/X86.cpp
  lld/ELF/Arch/X86_64.cpp
  lld/ELF/Relocations.cpp
  lld/ELF/Symbols.cpp
  lld/ELF/SyntheticSections.cpp
  lld/ELF/SyntheticSections.h
  lld/ELF/Target.h
  lld/ELF/Writer.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D71519.233950.patch
Type: text/x-patch
Size: 12573 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20191215/528cc086/attachment-0001.bin>


More information about the llvm-commits mailing list