diff options
Diffstat (limited to 'llvm/lib/Target/TargetMachine.cpp')
| -rw-r--r-- | llvm/lib/Target/TargetMachine.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/Target/TargetMachine.cpp b/llvm/lib/Target/TargetMachine.cpp index b39b58d7e02..3a45b3343ca 100644 --- a/llvm/lib/Target/TargetMachine.cpp +++ b/llvm/lib/Target/TargetMachine.cpp @@ -109,7 +109,7 @@ TLSModel::Model TargetMachine::getTLSModel(const GlobalValue *GV) const { bool isLocal = GV->hasLocalLinkage(); bool isDeclaration = GV->isDeclaration(); bool isPIC = getRelocationModel() == Reloc::PIC_; - bool isPIE = Options.PositionIndependentExecutable; + bool isPIE = GV->getParent()->getPIELevel() != PIELevel::Default; // FIXME: what should we do for protected and internal visibility? // For variables, is internal different from hidden? bool isHidden = GV->hasHiddenVisibility(); |

