[llvm] r293327 - Update NVVMReflect usage doc to new idiom for adding target-specific early passes.
Justin Lebar via llvm-commits
llvm-commits at lists.llvm.org
Fri Jan 27 11:44:24 PST 2017
Author: jlebar
Date: Fri Jan 27 13:44:24 2017
New Revision: 293327
URL: http://llvm.org/viewvc/llvm-project?rev=293327&view=rev
Log:
Update NVVMReflect usage doc to new idiom for adding target-specific early passes.
Modified:
llvm/trunk/docs/NVPTXUsage.rst
Modified: llvm/trunk/docs/NVPTXUsage.rst
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/docs/NVPTXUsage.rst?rev=293327&r1=293326&r2=293327&view=diff
==============================================================================
--- llvm/trunk/docs/NVPTXUsage.rst (original)
+++ llvm/trunk/docs/NVPTXUsage.rst Fri Jan 27 13:44:24 2017
@@ -334,11 +334,8 @@ manager:
std::unique_ptr<TargetMachine> TM = ...;
PassManagerBuilder PMBuilder(...);
- PMBuilder.addExtension(
- PassManagerBuilder::EP_EarlyAsPossible,
- [&](const PassManagerBuilder &, legacy::PassManagerBase &PM) {
- TM->addEarlyAsPossiblePasses(PM);
- });
+ if (TM)
+ TM->adjustPassManager(PMBuilder);
Reflection Parameters
---------------------
More information about the llvm-commits
mailing list