[PATCH] D68154: [Dominators][CodeGen] Fix MachineDominatorTree preservation in PHIElimination

Aditya Kumar via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sun Sep 29 11:18:49 PDT 2019


hiraditya added inline comments.


================
Comment at: llvm/lib/CodeGen/PHIElimination.cpp:189
 
+  if (Changed && MDT)
+    MDT->getBase().recalculate(MF);
----------------
hiraditya wrote:
> arsenm wrote:
> > Isn't this basically the same as making it unpreserved? If you aren't going to update at the points it needs, I think it would be better to just stop reporting it as preserved
> +1
Can we put `auto *MDT = getAnalysisIfAvailable<MachineDominatorTree>();` when Changed is true?


Repository:
  rL LLVM

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

https://reviews.llvm.org/D68154





More information about the llvm-commits mailing list