From 6b5005514a577a56afe785ccb52fb141374c186a Mon Sep 17 00:00:00 2001 From: Justin Lebar Date: Fri, 27 Jan 2017 19:44:24 +0000 Subject: [PATCH] Update NVVMReflect usage doc to new idiom for adding target-specific early passes. llvm-svn: 293327 --- llvm/docs/NVPTXUsage.rst | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/llvm/docs/NVPTXUsage.rst b/llvm/docs/NVPTXUsage.rst index 37b433d..159fe07 100644 --- a/llvm/docs/NVPTXUsage.rst +++ b/llvm/docs/NVPTXUsage.rst @@ -334,11 +334,8 @@ manager: std::unique_ptr TM = ...; PassManagerBuilder PMBuilder(...); - PMBuilder.addExtension( - PassManagerBuilder::EP_EarlyAsPossible, - [&](const PassManagerBuilder &, legacy::PassManagerBase &PM) { - TM->addEarlyAsPossiblePasses(PM); - }); + if (TM) + TM->adjustPassManager(PMBuilder); Reflection Parameters --------------------- -- 2.7.4