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.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@226158
91177308-0d34-0410-b5e6-
96231b3b80d8
// 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);