[Mlir-commits] [mlir] [mlir][opt][RemoveDeadValues] Fix crash when processing ops with regions that don't implement RegionBranchOpInterface (PR #182711)

Fedor Nikolaev llvmlistbot at llvm.org
Mon Feb 23 08:28:37 PST 2026


================
@@ -511,8 +511,10 @@ static void processBranchOp(BranchOpInterface branchOp, RunLivenessAnalysis &la,
     // Do (2)
     BitVector successorNonLive =
         markLives(operandValues, nonLiveSet, la).flip();
-    collectNonLiveValues(nonLiveSet, successorBlock->getArguments(),
-                         successorNonLive);
+    if (std::distance(successorBlock->pred_begin(),
+                      successorBlock->pred_end()) <= 1)
----------------
felichita wrote:

done, thank you

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


More information about the Mlir-commits mailing list