[Mlir-commits] [mlir] [mlir] Guard sccp pass from crashing with different source type (PR #120656)
donald chen
llvmlistbot at llvm.org
Fri Dec 20 01:19:49 PST 2024
================
@@ -246,3 +246,16 @@ func.func @op_with_region() -> (i32) {
^b:
return %1 : i32
}
+
+// CHECK-LABEL: no_crash_with_different_source_type
+func.func @no_crash_with_different_source_type() {
+ // CHECK: llvm.mlir.constant(0 : index) : i64
+ %0 = llvm.mlir.constant(0 : index) : i64
+ llvm.br ^b1(%0 : i64)
+^b1(%1: i64):
+ llvm.br ^b2
+^b2:
----------------
cxy-1993 wrote:
It is recommended to simplify test by removing these branch ops and bbs
https://github.com/llvm/llvm-project/pull/120656
More information about the Mlir-commits
mailing list