r318140 - [NewPassManager] Pass the -fdebug-pass-manager flag setting into the Analysis managers to match what we do in opt
Craig Topper via cfe-commits
cfe-commits at lists.llvm.org
Tue Nov 14 00:48:28 PST 2017
Author: ctopper
Date: Tue Nov 14 00:48:28 2017
New Revision: 318140
URL: http://llvm.org/viewvc/llvm-project?rev=318140&view=rev
Log:
[NewPassManager] Pass the -fdebug-pass-manager flag setting into the Analysis managers to match what we do in opt
Summary: Currently the -fdebug-pass-manager flag for clang doesn't enable the debug logging in the analysis managers. This is different than what the switch does when passed to opt.
Reviewers: chandlerc
Reviewed By: chandlerc
Subscribers: cfe-commits
Differential Revision: https://reviews.llvm.org/D40007
Modified:
cfe/trunk/lib/CodeGen/BackendUtil.cpp
Modified: cfe/trunk/lib/CodeGen/BackendUtil.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/CodeGen/BackendUtil.cpp?rev=318140&r1=318139&r2=318140&view=diff
==============================================================================
--- cfe/trunk/lib/CodeGen/BackendUtil.cpp (original)
+++ cfe/trunk/lib/CodeGen/BackendUtil.cpp Tue Nov 14 00:48:28 2017
@@ -867,10 +867,10 @@ void EmitAssemblyHelper::EmitAssemblyWit
PassBuilder PB(TM.get(), PGOOpt);
- LoopAnalysisManager LAM;
- FunctionAnalysisManager FAM;
- CGSCCAnalysisManager CGAM;
- ModuleAnalysisManager MAM;
+ LoopAnalysisManager LAM(CodeGenOpts.DebugPassManager);
+ FunctionAnalysisManager FAM(CodeGenOpts.DebugPassManager);
+ CGSCCAnalysisManager CGAM(CodeGenOpts.DebugPassManager);
+ ModuleAnalysisManager MAM(CodeGenOpts.DebugPassManager);
// Register the AA manager first so that our version is the one used.
FAM.registerPass([&] { return PB.buildDefaultAAPipeline(); });
More information about the cfe-commits
mailing list