[llvm-branch-commits] [llvm] [SSAUpdaterBulk] Add PHI simplification pass. (PR #135180)

Matt Arsenault via llvm-branch-commits llvm-branch-commits at lists.llvm.org
Sun Apr 13 00:44:48 PDT 2025


================
@@ -222,3 +223,38 @@ void SSAUpdaterBulk::RewriteAllUses(DominatorTree *DT,
     }
   }
 }
+
+// Perform a single pass of simplification over the worklist of PHIs.
+static void SimplifyPass(MutableArrayRef<PHINode *> Worklist) {
+  if (Worklist.empty())
+    return;
+
+  const DataLayout &DL = Worklist.front()->getParent()->getDataLayout();
----------------
arsenm wrote:

Pass this in as an argument? 

https://github.com/llvm/llvm-project/pull/135180


More information about the llvm-branch-commits mailing list