Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F103806612
D22913.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
1 KB
Referenced Files
None
Subscribers
None
D22913.diff
View Options
Index: head/contrib/llvm-project/llvm/lib/Target/PowerPC/PPCISelLowering.cpp
===================================================================
--- head/contrib/llvm-project/llvm/lib/Target/PowerPC/PPCISelLowering.cpp
+++ head/contrib/llvm-project/llvm/lib/Target/PowerPC/PPCISelLowering.cpp
@@ -4952,7 +4952,12 @@
if (auto *G = dyn_cast<GlobalAddressSDNode>(Callee))
GV = G->getGlobal();
bool Local = TM.shouldAssumeDSOLocal(*Mod, GV);
- bool UsePlt = !Local && Subtarget.isTargetELF() && !isPPC64;
+ // The PLT is only used in 32-bit ELF PIC mode. Attempting to use the PLT in
+ // a static relocation model causes some versions of GNU LD (2.17.50, at
+ // least) to force BSS-PLT, instead of secure-PLT, even if all objects are
+ // built with secure-PLT.
+ bool UsePlt = !Local && Subtarget.isTargetELF() && !isPPC64 &&
+ Subtarget.getTargetMachine().getRelocationModel() == Reloc::PIC_;
// If the callee is a GlobalAddress/ExternalSymbol node (quite common,
// every direct call is) turn it into a TargetGlobalAddress /
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sat, Nov 30, 5:12 PM (21 h, 35 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
14946254
Default Alt Text
D22913.diff (1 KB)
Attached To
Mode
D22913: Merge commit d3aeac8e2 from llvm git (by Justin Hibbits)
Attached
Detach File
Event Timeline
Log In to Comment