declare void @llvm.experimental.guard(i1, ...)
-define i8 @f_basic(i1* %c_ptr) {
+define i8 @f_basic(ptr %c_ptr) {
; CHECK-LABEL: @f_basic(
- %c = load volatile i1, i1* %c_ptr
+ %c = load volatile i1, ptr %c_ptr
call void(i1, ...) @llvm.experimental.guard(i1 %c, i32 1) [ "deopt"(i32 1) ]
ret i8 5
; CHECK-NEXT: ret i8 5
}
-define void @f_void_return_ty(i1* %c_ptr) {
+define void @f_void_return_ty(ptr %c_ptr) {
; CHECK-LABEL: @f_void_return_ty(
- %c = load volatile i1, i1* %c_ptr
+ %c = load volatile i1, ptr %c_ptr
call void(i1, ...) @llvm.experimental.guard(i1 %c, i32 1) [ "deopt"() ]
ret void
; CHECK-NEXT: ret void
}
-define void @f_multiple_args(i1* %c_ptr) {
+define void @f_multiple_args(ptr %c_ptr) {
; CHECK-LABEL: @f_multiple_args(
- %c = load volatile i1, i1* %c_ptr
+ %c = load volatile i1, ptr %c_ptr
call void(i1, ...) @llvm.experimental.guard(i1 %c, i32 1, i32 2, double 500.0) [ "deopt"(i32 2, i32 3) ]
ret void
; CHECK-NEXT: ret void
}
-define i32 @f_zero_args(i1* %c_ptr) {
+define i32 @f_zero_args(ptr %c_ptr) {
; CHECK-LABEL: @f_zero_args(
- %c = load volatile i1, i1* %c_ptr
+ %c = load volatile i1, ptr %c_ptr
call void(i1, ...) @llvm.experimental.guard(i1 %c) [ "deopt"(i32 2, i32 3) ]
ret i32 500
; CHECK-NEXT: ret i32 500
}
-define i8 @f_with_make_implicit_md(i32* %ptr) {
+define i8 @f_with_make_implicit_md(ptr %ptr) {
; CHECK-LABEL: @f_with_make_implicit_md(
; CHECK: br i1 %notNull, label %guarded, label %deopt, !prof !0, !make.implicit !1
; CHECK: deopt:
; CHECK-NEXT: %deoptcall = call i8 (...) @llvm.experimental.deoptimize.i8(i32 1) [ "deopt"(i32 1) ]
; CHECK-NEXT: ret i8 %deoptcall
- %notNull = icmp ne i32* %ptr, null
+ %notNull = icmp ne ptr %ptr, null
call void(i1, ...) @llvm.experimental.guard(i1 %notNull, i32 1) [ "deopt"(i32 1) ], !make.implicit !{}
ret i8 5
}
declare cc99 void @llvm.experimental.guard(i1, ...)
-define i8 @f_basic(i1* %c_ptr) {
+define i8 @f_basic(ptr %c_ptr) {
; CHECK-LABEL: @f_basic(
; CHECK: br i1 %c, label %guarded, label %deopt
; CHECK: deopt:
; CHECK-NEXT: %deoptcall = call cc99 i8 (...) @llvm.experimental.deoptimize.i8() [ "deopt"() ]
; CHECK-NEXT: ret i8 %deoptcall
- %c = load volatile i1, i1* %c_ptr
+ %c = load volatile i1, ptr %c_ptr
call cc99 void(i1, ...) @llvm.experimental.guard(i1 %c) [ "deopt"() ]
ret i8 6
}