[Mlir-commits] [mlir] [mlir][Interfaces] Document completeness requirement of `RegionBranchOpInterface` (PR #202018)

Mehdi Amini llvmlistbot at llvm.org
Tue Jun 9 02:13:24 PDT 2026


================
@@ -234,6 +243,13 @@ def RegionBranchOpInterface : OpInterface<"RegionBranchOpInterface"> {
         returns the successor regions when branching from the region indicated
         by `point`.
 
+        The returned successors must include every region successor that
+        control flow could reach from `point`. Omitting a successor that is
+        possible from `point` is an incorrect implementation and may cause
+        analyses/transformations to produce incorrect results. It is acceptable
+        to over-approximate by reporting successors that turn out to be
+        infeasible at runtime.
----------------
joker-eph wrote:

Very first sentence is already saying "Returns all potential region successor ..." ; not clear to me what extra information we get here.

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


More information about the Mlir-commits mailing list