[PATCH] D53384: [PowerPC] Make no-PIC default to match GCC - CLANG
Stefan Pintilie via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Oct 17 12:38:58 PDT 2018
stefanp created this revision.
stefanp added reviewers: nemanjai, kbarton, sfertile, syzaara, lei, hfinkel, joerg.
Herald added a subscriber: jsji.
Ran a quick test and determined that for GCC the default option is `-fno-PIC` for both ELFv1 and ELFv2. We are currently using `-fPIC` as the default for LLVM.
Would like to revert to what GCC is doing on PowerPC.
NOTE: This patch does not yet include test case updates. Currently working on those updates and will further update this patch at that time. In the meantime I put up this patch to make sure that this is in fact what we want to do.
https://reviews.llvm.org/D53384
Files:
lib/Driver/ToolChains/Gnu.cpp
Index: lib/Driver/ToolChains/Gnu.cpp
===================================================================
--- lib/Driver/ToolChains/Gnu.cpp
+++ lib/Driver/ToolChains/Gnu.cpp
@@ -2370,7 +2370,7 @@
return getTriple().isOSWindows();
case llvm::Triple::ppc64:
case llvm::Triple::ppc64le:
- return !getTriple().isOSBinFormatMachO() && !getTriple().isMacOSX();
+ return getTriple().isOSFreeBSD();
case llvm::Triple::mips64:
case llvm::Triple::mips64el:
return true;
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D53384.170030.patch
Type: text/x-patch
Size: 487 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20181017/9fcfec33/attachment.bin>
More information about the llvm-commits
mailing list