summaryrefslogtreecommitdiff
path: root/mlir/test/Target/LLVMIR/Import/intrinsic.ll
diff options
context:
space:
mode:
Diffstat (limited to 'mlir/test/Target/LLVMIR/Import/intrinsic.ll')
-rw-r--r--mlir/test/Target/LLVMIR/Import/intrinsic.ll9
1 files changed, 9 insertions, 0 deletions
diff --git a/mlir/test/Target/LLVMIR/Import/intrinsic.ll b/mlir/test/Target/LLVMIR/Import/intrinsic.ll
index fadfc124adbd..190362423940 100644
--- a/mlir/test/Target/LLVMIR/Import/intrinsic.ll
+++ b/mlir/test/Target/LLVMIR/Import/intrinsic.ll
@@ -467,6 +467,14 @@ define void @assume(i1 %true) {
ret void
}
+; CHECK-LABEL: @is_constant
+; CHECK-SAME: %[[VAL:[a-zA-Z0-9]+]]
+define void @is_constant(i32 %0) {
+ ; CHECK: "llvm.intr.is.constant"(%[[VAL]]) : (i32) -> i1
+ %2 = call i1 @llvm.is.constant.i32(i32 %0)
+ ret void
+}
+
; CHECK-LABEL: @expect
; CHECK-SAME: %[[VAL:[a-zA-Z0-9]+]]
define void @expect(i32 %0) {
@@ -792,6 +800,7 @@ declare { i32, i1 } @llvm.smul.with.overflow.i32(i32, i32)
declare { <8 x i32>, <8 x i1> } @llvm.smul.with.overflow.v8i32(<8 x i32>, <8 x i32>)
declare { i32, i1 } @llvm.umul.with.overflow.i32(i32, i32)
declare { <8 x i32>, <8 x i1> } @llvm.umul.with.overflow.v8i32(<8 x i32>, <8 x i32>)
+declare i1 @llvm.is.constant.i32(i32)
declare i32 @llvm.expect.i32(i32, i32)
declare i16 @llvm.expect.with.probability.i16(i16, i16, double immarg)
declare token @llvm.coro.id(i32, ptr readnone, ptr nocapture readonly, ptr)