summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChandler Carruth <chandlerc@gmail.com>2015-01-15 10:42:26 +0000
committerChandler Carruth <chandlerc@gmail.com>2015-01-15 10:42:26 +0000
commita9711a9aa493762b6ea647717bed0cf092fbb68a (patch)
tree88f4bffd9e6cf71e8ebba407de682c009c22800a
parentb98f63dbdb5668cb526e422e5b421dcddc8ff4f3 (diff)
downloadbcm5719-llvm-a9711a9aa493762b6ea647717bed0cf092fbb68a.tar.gz
bcm5719-llvm-a9711a9aa493762b6ea647717bed0cf092fbb68a.zip
[PM] Track an LLVM API update which separates the TargetLibraryInfo
object from the pass that provides access to it. We should probably refactor the createTLI code here in Clang in light of the new structure, but I wanted this patch to be a minimal one that just patches the behavior back together. llvm-svn: 226158
-rw-r--r--clang/lib/CodeGen/BackendUtil.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/clang/lib/CodeGen/BackendUtil.cpp b/clang/lib/CodeGen/BackendUtil.cpp
index 7adbdddf296..ec93bc80af3 100644
--- a/clang/lib/CodeGen/BackendUtil.cpp
+++ b/clang/lib/CodeGen/BackendUtil.cpp
@@ -543,7 +543,8 @@ bool EmitAssemblyHelper::AddEmitPasses(BackendAction Action,
// Add LibraryInfo.
llvm::Triple TargetTriple(TheModule->getTargetTriple());
- PM->add(createTLI(TargetTriple, CodeGenOpts));
+ std::unique_ptr<TargetLibraryInfo> TLI(createTLI(TargetTriple, CodeGenOpts));
+ PM->add(new TargetLibraryInfoWrapperPass(*TLI));
// Add Target specific analysis passes.
TM->addAnalysisPasses(*PM);
OpenPOWER on IntegriCloud