[PowerPC] Fix thunk alignment issue when using pc-rel instruction
authorVictor Huang <wei.huang@ibm.com>
Mon, 17 Aug 2020 13:38:05 +0000 (08:38 -0500)
committerVictor Huang <wei.huang@ibm.com>
Mon, 17 Aug 2020 14:09:36 +0000 (09:09 -0500)
commit7b391245d8eab16d1dfabde9f67a97fa9809ab49
tree182b911636a33d5b5382c552e6dc059c57e6a082
parent5b53b17cd307d1b507d28ac19278c1209684f23e
[PowerPC] Fix thunk alignment issue when using pc-rel instruction

Thunk alignment is added in thie patch when using pc-rel instructions
to avoid crossing the 64 byte boundary.

Patched by: nemanjai, NeHuang
Reviewed By: sfertile, MaskRay

Differential Revision: https://reviews.llvm.org/D85973
18 files changed:
lld/ELF/SyntheticSections.cpp
lld/ELF/Thunks.cpp
lld/test/ELF/ppc64-bsymbolic-toc-restore.s
lld/test/ELF/ppc64-call-reach.s
lld/test/ELF/ppc64-dtprel.s
lld/test/ELF/ppc64-ifunc.s
lld/test/ELF/ppc64-local-dynamic.s
lld/test/ELF/ppc64-long-branch-init.s
lld/test/ELF/ppc64-long-branch-rel14.s
lld/test/ELF/ppc64-long-branch.s
lld/test/ELF/ppc64-pcrel-call-to-extern.s
lld/test/ELF/ppc64-pcrel-call-to-toc.s
lld/test/ELF/ppc64-plt-stub-compatible.s
lld/test/ELF/ppc64-plt-stub.s
lld/test/ELF/ppc64-tls-gd.s
lld/test/ELF/ppc64-toc-call-to-pcrel.s
lld/test/ELF/ppc64-toc-restore-recursive-call.s
lld/test/ELF/ppc64-toc-restore.s