[PATCH] D99599: [NewPM] Add an option to dump pass structure
Teresa Johnson via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Apr 16 12:15:59 PDT 2021
tejohnson added inline comments.
================
Comment at: llvm/lib/Passes/StandardInstrumentations.cpp:55
+static cl::opt<bool>
+ DebugPassStructure("debug-pass-structure", cl::Hidden, cl::init(false),
+ cl::desc("Print pass structure information."));
----------------
I noticed that in clang there is an -fdebug-pass-structure that eventually gets translated to the old PM's -debug-pass=Structure. Perhaps that should specify this internal option in the case of the new PM?
================
Comment at: llvm/lib/Passes/StandardInstrumentations.cpp:923
+ if (!Msg.isTriviallyEmpty()) {
+ for (int I = 0; I < Ident; ++I)
+ dbgs() << " ";
----------------
Can you instead use something like:
dbgs().indent(Ident) << Msg;
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D99599/new/
https://reviews.llvm.org/D99599
More information about the llvm-commits
mailing list