[Mlir-commits] [mlir] [MLIR][LLVM] Support for indirectbr (PR #135092)

Tobias Gysi llvmlistbot at llvm.org
Thu Apr 10 23:10:49 PDT 2025


================
@@ -1705,6 +1705,65 @@ def LLVM_BlockTagOp : LLVM_Op<"blocktag"> {
   let hasVerifier = 0;
 }
 
+//===----------------------------------------------------------------------===//
+// IndirectBrOp
+//===----------------------------------------------------------------------===//
+
+def LLVM_IndirectBrOp : LLVM_TerminatorOp<"indirectbr",
+    [SameVariadicOperandSize, DeclareOpInterfaceMethods<BranchOpInterface>,
+     Pure]> {
+  let description = [{
+    Transfer control flow to address in `$addr`. A list of possible target
+    blocks in `$successors` can be provided and maybe used as a hint in LLVM:
----------------
gysit wrote:

Also @xlauko @Dinistro more ideas are welcome :)

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


More information about the Mlir-commits mailing list