[PATCH] D70570: [PowerPC] Only use PLT annotations if using PIC relocation model

Fangrui Song via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Dec 17 18:18:24 PST 2019


MaskRay accepted this revision.
MaskRay added a comment.
This revision is now accepted and ready to land.

Since I recently picked up some stuff on lld PPC32, I have run powerpc-linux-gnu-gcc many times to observe its behaviors. This matches what I see, but you probably also need @sfertile's thumbs-up.

> because it breaks secure-PLT linking with GNU LD

Can you be more specific? I guess this is because clang emitted R_PPC_PLTREL24 causes GNU ld to fall back to --bss-plt due to a deficiency in its `bfd/elf32-ppc.c:ppc_elf_select_plt_layout` code.

> powerpc-linux-gnu-ld: bss-plt forced due to b.o


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D70570/new/

https://reviews.llvm.org/D70570





More information about the llvm-commits mailing list