r362051 - [PowerPC] Set the default PLT mode on musl to Secure PLT
Fangrui Song via cfe-commits
cfe-commits at lists.llvm.org
Wed May 29 19:13:15 PDT 2019
Author: maskray
Date: Wed May 29 19:13:15 2019
New Revision: 362051
URL: http://llvm.org/viewvc/llvm-project?rev=362051&view=rev
Log:
[PowerPC] Set the default PLT mode on musl to Secure PLT
The musl libc only supports Secure PLT.
Patch by A. Wilcox!
Reviewed By: jhibbits
Differential Revision: https://reviews.llvm.org/D59185
Modified:
cfe/trunk/lib/Driver/ToolChains/Arch/PPC.cpp
Modified: cfe/trunk/lib/Driver/ToolChains/Arch/PPC.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Driver/ToolChains/Arch/PPC.cpp?rev=362051&r1=362050&r2=362051&view=diff
==============================================================================
--- cfe/trunk/lib/Driver/ToolChains/Arch/PPC.cpp (original)
+++ cfe/trunk/lib/Driver/ToolChains/Arch/PPC.cpp Wed May 29 19:13:15 2019
@@ -115,7 +115,7 @@ ppc::ReadGOTPtrMode ppc::getPPCReadGOTPt
const ArgList &Args) {
if (Args.getLastArg(options::OPT_msecure_plt))
return ppc::ReadGOTPtrMode::SecurePlt;
- if (Triple.isOSNetBSD() || Triple.isOSOpenBSD())
+ if (Triple.isOSNetBSD() || Triple.isOSOpenBSD() || Triple.isMusl())
return ppc::ReadGOTPtrMode::SecurePlt;
else
return ppc::ReadGOTPtrMode::Bss;
More information about the cfe-commits
mailing list