[PATCH] D99599: [NewPM] Add an option to dump pass structure

Teresa Johnson via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Apr 28 08:14:57 PDT 2021


tejohnson added inline comments.


================
Comment at: llvm/include/llvm/IR/PassManagerImpl.h:77
 
-    PI.runAfterAnalysis(P, IR);
+    if (ID != PassInstrumentationAnalysis::ID())
+      PI.runAfterAnalysis(P, IR);
----------------
evgeny777 wrote:
> tejohnson wrote:
> > What is this check needed for?
> For runBeforeAnalysis and runAfterAnalysis to be in sync. See if block above:
> ```
> if (ID != PassInstrumentationAnalysis::ID()) {
>       PI = getResult<PassInstrumentationAnalysis>(IR, ExtraArgs...);
>       PI.runBeforeAnalysis(P, IR);
> }
> ```
Sure I saw that above. But I guess my question is what is the practical effect of this change, i.e. why is it needed with your other changes in this patch when it wasn't needed before?


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D99599/new/

https://reviews.llvm.org/D99599



More information about the llvm-commits mailing list