summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Target/X86/X86Subtarget.cpp
diff options
context:
space:
mode:
authorAnton Korobeynikov <asl@math.spbu.ru>2008-01-20 13:58:16 +0000
committerAnton Korobeynikov <asl@math.spbu.ru>2008-01-20 13:58:16 +0000
commit28d4302807459c75a5f453c675b0d5dcddf02ee5 (patch)
tree824e8b20566865a0ca4496dbfb92af7ec8eff9d9 /llvm/lib/Target/X86/X86Subtarget.cpp
parentfe3bef091f4322602ed5a8da432dc10910096b45 (diff)
downloadbcm5719-llvm-28d4302807459c75a5f453c675b0d5dcddf02ee5.tar.gz
bcm5719-llvm-28d4302807459c75a5f453c675b0d5dcddf02ee5.zip
Enable PIC codegen on x86-64/linux
llvm-svn: 46198
Diffstat (limited to 'llvm/lib/Target/X86/X86Subtarget.cpp')
-rw-r--r--llvm/lib/Target/X86/X86Subtarget.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/Target/X86/X86Subtarget.cpp b/llvm/lib/Target/X86/X86Subtarget.cpp
index 6efe540fabd..1480332ef0c 100644
--- a/llvm/lib/Target/X86/X86Subtarget.cpp
+++ b/llvm/lib/Target/X86/X86Subtarget.cpp
@@ -41,7 +41,7 @@ bool X86Subtarget::GVRequiresExtraLoad(const GlobalValue* GV,
return (!isDirectCall &&
(GV->hasWeakLinkage() || GV->hasLinkOnceLinkage() ||
(GV->isDeclaration() && !GV->hasNotBeenReadFromBitcode())));
- } else if (TM.getRelocationModel() == Reloc::PIC_ && isPICStyleGOT()) {
+ } else if (isTargetELF()) {
// Extra load is needed for all non-statics.
return (!isDirectCall &&
(GV->isDeclaration() || !GV->hasInternalLinkage()));
OpenPOWER on IntegriCloud