[llvm] ead8463 - [Lint] Convert tests to opaque pointers (NFC)
Nikita Popov via llvm-commits
llvm-commits at lists.llvm.org
Fri Dec 16 03:08:54 PST 2022
Author: Nikita Popov
Date: 2022-12-16T12:08:39+01:00
New Revision: ead84636a31cfa1f028743ed4e7ae3160a08c34d
URL: https://github.com/llvm/llvm-project/commit/ead84636a31cfa1f028743ed4e7ae3160a08c34d
DIFF: https://github.com/llvm/llvm-project/commit/ead84636a31cfa1f028743ed4e7ae3160a08c34d.diff
LOG: [Lint] Convert tests to opaque pointers (NFC)
Added:
Modified:
llvm/test/Analysis/Lint/address-spaces.ll
llvm/test/Analysis/Lint/cppeh-catch-intrinsics-clean.ll
llvm/test/Analysis/Lint/memintrin.ll
llvm/test/Analysis/Lint/noalias-byval.ll
llvm/test/Analysis/Lint/noalias-readonly.ll
llvm/test/Analysis/Lint/noop-cast-expr-no-pointer.ll
llvm/test/Analysis/Lint/tail-call-byval.ll
Removed:
################################################################################
diff --git a/llvm/test/Analysis/Lint/address-spaces.ll b/llvm/test/Analysis/Lint/address-spaces.ll
index 256bbb157c35d..42e5344e8c002 100644
--- a/llvm/test/Analysis/Lint/address-spaces.ll
+++ b/llvm/test/Analysis/Lint/address-spaces.ll
@@ -4,22 +4,22 @@ target datalayout = "p32:32:32-p1:16:16:16-n16:32"
declare void @foo(i64) nounwind
-define i64 @test1(i32 addrspace(1)* %x) nounwind {
- %y = ptrtoint i32 addrspace(1)* %x to i64
+define i64 @test1(ptr addrspace(1) %x) nounwind {
+ %y = ptrtoint ptr addrspace(1) %x to i64
ret i64 %y
}
-define <4 x i64> @test1_vector(<4 x i32 addrspace(1)*> %x) nounwind {
- %y = ptrtoint <4 x i32 addrspace(1)*> %x to <4 x i64>
+define <4 x i64> @test1_vector(<4 x ptr addrspace(1)> %x) nounwind {
+ %y = ptrtoint <4 x ptr addrspace(1)> %x to <4 x i64>
ret <4 x i64> %y
}
-define i32 addrspace(1)* @test2(i64 %x) nounwind {
- %y = inttoptr i64 %x to i32 addrspace(1)*
- ret i32 addrspace(1)* %y
+define ptr addrspace(1) @test2(i64 %x) nounwind {
+ %y = inttoptr i64 %x to ptr addrspace(1)
+ ret ptr addrspace(1) %y
}
-define <4 x i32 addrspace(1)*> @test2_vector(<4 x i64> %x) nounwind {
- %y = inttoptr <4 x i64> %x to <4 x i32 addrspace(1)*>
- ret <4 x i32 addrspace(1)*> %y
+define <4 x ptr addrspace(1)> @test2_vector(<4 x i64> %x) nounwind {
+ %y = inttoptr <4 x i64> %x to <4 x ptr addrspace(1)>
+ ret <4 x ptr addrspace(1)> %y
}
\ No newline at end of file
diff --git a/llvm/test/Analysis/Lint/cppeh-catch-intrinsics-clean.ll b/llvm/test/Analysis/Lint/cppeh-catch-intrinsics-clean.ll
index 67a5edc3e788b..1bc673098f4ec 100644
--- a/llvm/test/Analysis/Lint/cppeh-catch-intrinsics-clean.ll
+++ b/llvm/test/Analysis/Lint/cppeh-catch-intrinsics-clean.ll
@@ -5,29 +5,29 @@
target triple = "x86_64-pc-windows-msvc"
-declare void @llvm.eh.begincatch(i8*, i8*)
+declare void @llvm.eh.begincatch(ptr, ptr)
declare void @llvm.eh.endcatch()
- at _ZTIi = external constant i8*
+ at _ZTIi = external constant ptr
; Function Attrs: uwtable
-define void @test_ref_clean() personality i8* bitcast (i32 (...)* @__CxxFrameHandler3 to i8*) {
+define void @test_ref_clean() personality ptr @__CxxFrameHandler3 {
entry:
invoke void @_Z9may_throwv()
to label %try.cont unwind label %lpad
lpad: ; preds = %entry
- %0 = landingpad { i8*, i32 }
- catch i8* bitcast (i8** @_ZTIi to i8*)
- %exn = extractvalue { i8*, i32 } %0, 0
- %sel = extractvalue { i8*, i32 } %0, 1
- %1 = call i32 @llvm.eh.typeid.for(i8* bitcast (i8** @_ZTIi to i8*))
+ %0 = landingpad { ptr, i32 }
+ catch ptr @_ZTIi
+ %exn = extractvalue { ptr, i32 } %0, 0
+ %sel = extractvalue { ptr, i32 } %0, 1
+ %1 = call i32 @llvm.eh.typeid.for(ptr @_ZTIi)
%matches = icmp eq i32 %sel, %1
br i1 %matches, label %catch, label %eh.resume
catch: ; preds = %lpad
- call void @llvm.eh.begincatch(i8* %exn, i8* null)
+ call void @llvm.eh.begincatch(ptr %exn, ptr null)
call void @_Z10handle_intv()
br label %invoke.cont2
@@ -39,11 +39,11 @@ try.cont: ; preds = %invoke.cont2, %entr
ret void
eh.resume: ; preds = %catch.dispatch
- resume { i8*, i32 } %0
+ resume { ptr, i32 } %0
}
; Function Attrs: uwtable
-define void @test_ref_clean_multibranch() personality i8* bitcast (i32 (...)* @__CxxFrameHandler3 to i8*) {
+define void @test_ref_clean_multibranch() personality ptr @__CxxFrameHandler3 {
entry:
invoke void @_Z9may_throwv()
to label %invoke.cont unwind label %lpad
@@ -53,11 +53,11 @@ invoke.cont:
to label %invoke.cont unwind label %lpad1
lpad: ; preds = %entry
- %0 = landingpad { i8*, i32 }
- catch i8* bitcast (i8** @_ZTIi to i8*)
- %exn = extractvalue { i8*, i32 } %0, 0
- %sel = extractvalue { i8*, i32 } %0, 1
- %1 = call i32 @llvm.eh.typeid.for(i8* bitcast (i8** @_ZTIi to i8*))
+ %0 = landingpad { ptr, i32 }
+ catch ptr @_ZTIi
+ %exn = extractvalue { ptr, i32 } %0, 0
+ %sel = extractvalue { ptr, i32 } %0, 1
+ %1 = call i32 @llvm.eh.typeid.for(ptr @_ZTIi)
%matches = icmp eq i32 %sel, %1
br i1 %matches, label %catch, label %eh.resume
@@ -65,19 +65,19 @@ lpad: ; preds = %entry
to label %try.cont unwind label %lpad
lpad1: ; preds = %entry
- %l1.0 = landingpad { i8*, i32 }
+ %l1.0 = landingpad { ptr, i32 }
cleanup
- catch i8* bitcast (i8** @_ZTIi to i8*)
- %exn1 = extractvalue { i8*, i32 } %l1.0, 0
- %sel1 = extractvalue { i8*, i32 } %l1.0, 1
- %l1.1 = call i32 @llvm.eh.typeid.for(i8* bitcast (i8** @_ZTIi to i8*))
+ catch ptr @_ZTIi
+ %exn1 = extractvalue { ptr, i32 } %l1.0, 0
+ %sel1 = extractvalue { ptr, i32 } %l1.0, 1
+ %l1.1 = call i32 @llvm.eh.typeid.for(ptr @_ZTIi)
%matchesl1 = icmp eq i32 %sel1, %l1.1
br i1 %matchesl1, label %catch, label %eh.resume
catch: ; preds = %lpad, %lpad1
- %exn2 = phi i8* [%exn, %lpad], [%exn1, %lpad1]
+ %exn2 = phi ptr [%exn, %lpad], [%exn1, %lpad1]
%sel2 = phi i32 [%sel, %lpad], [%sel1, %lpad1]
- call void @llvm.eh.begincatch(i8* %exn2, i8* null)
+ call void @llvm.eh.begincatch(ptr %exn2, ptr null)
call void @_Z10handle_intv()
%matches1 = icmp eq i32 %sel2, 0
br i1 %matches1, label %invoke.cont2, label %invoke.cont3
@@ -94,8 +94,8 @@ try.cont: ; preds = %invoke.cont2, %entr
ret void
eh.resume: ; preds = %catch.dispatch
- %lpad.val = insertvalue { i8*, i32 } undef, i32 0, 1
- resume { i8*, i32 } %lpad.val
+ %lpad.val = insertvalue { ptr, i32 } undef, i32 0, 1
+ resume { ptr, i32 } %lpad.val
}
declare void @_Z9may_throwv()
@@ -103,7 +103,7 @@ declare void @_Z9may_throwv()
declare i32 @__CxxFrameHandler3(...)
; Function Attrs: nounwind readnone
-declare i32 @llvm.eh.typeid.for(i8*)
+declare i32 @llvm.eh.typeid.for(ptr)
declare void @_Z10handle_intv()
diff --git a/llvm/test/Analysis/Lint/memintrin.ll b/llvm/test/Analysis/Lint/memintrin.ll
index a9919e192e229..3d2b4a36f828c 100644
--- a/llvm/test/Analysis/Lint/memintrin.ll
+++ b/llvm/test/Analysis/Lint/memintrin.ll
@@ -1,61 +1,56 @@
; RUN: opt -passes=lint -disable-output < %s 2>&1 | FileCheck %s
-declare void @llvm.memcpy.p0i8.p0i8.i32(i8* nocapture writeonly, i8* nocapture readonly, i32, i1) nounwind argmemonly
+declare void @llvm.memcpy.p0.p0.i32(ptr nocapture writeonly, ptr nocapture readonly, i32, i1) nounwind argmemonly
define void @f_memcpy() {
entry:
%dst = alloca [1000 x i8], align 2
%src = alloca [1000 x i8], align 4
- %dst.i8 = bitcast [1000 x i8]* %dst to i8*
- %src.i8 = bitcast [1000 x i8]* %src to i8*
; CHECK: Undefined behavior: Memory reference address is misaligned
-; CHECK-NEXT: call void @llvm.memcpy.p0i8.p0i8.i32(i8* align 8 %dst.i8, i8* align 4 %src.i8, i32 200, i1 false)
- call void @llvm.memcpy.p0i8.p0i8.i32(i8* align 8 %dst.i8, i8* align 4 %src.i8, i32 200, i1 false)
+; CHECK-NEXT: call void @llvm.memcpy.p0.p0.i32(ptr align 8 %dst, ptr align 4 %src, i32 200, i1 false)
+ call void @llvm.memcpy.p0.p0.i32(ptr align 8 %dst, ptr align 4 %src, i32 200, i1 false)
; CHECK: Undefined behavior: Memory reference address is misaligned
-; CHECK-NEXT: call void @llvm.memcpy.p0i8.p0i8.i32(i8* align 2 %dst.i8, i8* align 8 %src.i8, i32 200, i1 false)
- call void @llvm.memcpy.p0i8.p0i8.i32(i8* align 2 %dst.i8, i8* align 8 %src.i8, i32 200, i1 false)
-; CHECK-NOT: @llvm.memcpy.p0i8.p0i8.i32
- call void @llvm.memcpy.p0i8.p0i8.i32(i8* align 1 %dst.i8, i8* align 4 %src.i8, i32 200, i1 false)
- call void @llvm.memcpy.p0i8.p0i8.i32(i8* align 2 %dst.i8, i8* align 2 %src.i8, i32 200, i1 false)
- call void @llvm.memcpy.p0i8.p0i8.i32(i8* align 2 %dst.i8, i8* align 4 %src.i8, i32 200, i1 false)
+; CHECK-NEXT: call void @llvm.memcpy.p0.p0.i32(ptr align 2 %dst, ptr align 8 %src, i32 200, i1 false)
+ call void @llvm.memcpy.p0.p0.i32(ptr align 2 %dst, ptr align 8 %src, i32 200, i1 false)
+; CHECK-NOT: @llvm.memcpy.p0.p0.i32
+ call void @llvm.memcpy.p0.p0.i32(ptr align 1 %dst, ptr align 4 %src, i32 200, i1 false)
+ call void @llvm.memcpy.p0.p0.i32(ptr align 2 %dst, ptr align 2 %src, i32 200, i1 false)
+ call void @llvm.memcpy.p0.p0.i32(ptr align 2 %dst, ptr align 4 %src, i32 200, i1 false)
ret void
}
-declare void @llvm.memmove.p0i8.p0i8.i32(i8* nocapture writeonly, i8* nocapture readonly, i32, i1) nounwind argmemonly
+declare void @llvm.memmove.p0.p0.i32(ptr nocapture writeonly, ptr nocapture readonly, i32, i1) nounwind argmemonly
define void @f_memmove() {
entry:
%dst = alloca [1000 x i8], align 2
%src = alloca [1000 x i8], align 4
- %dst.i8 = bitcast [1000 x i8]* %dst to i8*
- %src.i8 = bitcast [1000 x i8]* %src to i8*
; CHECK: Undefined behavior: Memory reference address is misaligned
-; CHECK-NEXT: call void @llvm.memmove.p0i8.p0i8.i32(i8* align 4 %dst.i8, i8* align 4 %src.i8, i32 200, i1 false)
- call void @llvm.memmove.p0i8.p0i8.i32(i8* align 4 %dst.i8, i8* align 4 %src.i8, i32 200, i1 false)
+; CHECK-NEXT: call void @llvm.memmove.p0.p0.i32(ptr align 4 %dst, ptr align 4 %src, i32 200, i1 false)
+ call void @llvm.memmove.p0.p0.i32(ptr align 4 %dst, ptr align 4 %src, i32 200, i1 false)
; CHECK: Undefined behavior: Memory reference address is misaligned
-; CHECK-NEXT: call void @llvm.memmove.p0i8.p0i8.i32(i8* align 2 %dst.i8, i8* align 8 %src.i8, i32 200, i1 false)
- call void @llvm.memmove.p0i8.p0i8.i32(i8* align 2 %dst.i8, i8* align 8 %src.i8, i32 200, i1 false)
-; CHECK-NOT: @llvm.memmove.p0i8.p0i8.i32
- call void @llvm.memmove.p0i8.p0i8.i32(i8* align 1 %dst.i8, i8* align 4 %src.i8, i32 200, i1 false)
- call void @llvm.memmove.p0i8.p0i8.i32(i8* align 2 %dst.i8, i8* align 2 %src.i8, i32 200, i1 false)
- call void @llvm.memmove.p0i8.p0i8.i32(i8* align 2 %dst.i8, i8* align 4 %src.i8, i32 200, i1 false)
+; CHECK-NEXT: call void @llvm.memmove.p0.p0.i32(ptr align 2 %dst, ptr align 8 %src, i32 200, i1 false)
+ call void @llvm.memmove.p0.p0.i32(ptr align 2 %dst, ptr align 8 %src, i32 200, i1 false)
+; CHECK-NOT: @llvm.memmove.p0.p0.i32
+ call void @llvm.memmove.p0.p0.i32(ptr align 1 %dst, ptr align 4 %src, i32 200, i1 false)
+ call void @llvm.memmove.p0.p0.i32(ptr align 2 %dst, ptr align 2 %src, i32 200, i1 false)
+ call void @llvm.memmove.p0.p0.i32(ptr align 2 %dst, ptr align 4 %src, i32 200, i1 false)
ret void
}
-declare void @llvm.memset.p0i8.i32(i8* nocapture writeonly, i8, i32, i1) nounwind argmemonly
+declare void @llvm.memset.p0.i32(ptr nocapture writeonly, i8, i32, i1) nounwind argmemonly
define void @f_memset() {
entry:
%dst = alloca [1000 x i8], align 2
- %dst.i8 = bitcast [1000 x i8]* %dst to i8*
; CHECK: Undefined behavior: Memory reference address is misaligned
-; CHECK-NEXT: call void @llvm.memset.p0i8.i32(i8* align 4 %dst.i8, i8 55, i32 200, i1 false)
- call void @llvm.memset.p0i8.i32(i8* align 4 %dst.i8, i8 55, i32 200, i1 false)
-; CHECK-NOT: @llvm.memset.p0i8.i32
- call void @llvm.memset.p0i8.i32(i8* align 1 %dst.i8, i8 55, i32 200, i1 false)
- call void @llvm.memset.p0i8.i32(i8* align 2 %dst.i8, i8 55, i32 200, i1 false)
+; CHECK-NEXT: call void @llvm.memset.p0.i32(ptr align 4 %dst, i8 55, i32 200, i1 false)
+ call void @llvm.memset.p0.i32(ptr align 4 %dst, i8 55, i32 200, i1 false)
+; CHECK-NOT: @llvm.memset.p0.i32
+ call void @llvm.memset.p0.i32(ptr align 1 %dst, i8 55, i32 200, i1 false)
+ call void @llvm.memset.p0.i32(ptr align 2 %dst, i8 55, i32 200, i1 false)
ret void
}
diff --git a/llvm/test/Analysis/Lint/noalias-byval.ll b/llvm/test/Analysis/Lint/noalias-byval.ll
index f87f649eb12ac..6850058c35365 100644
--- a/llvm/test/Analysis/Lint/noalias-byval.ll
+++ b/llvm/test/Analysis/Lint/noalias-byval.ll
@@ -3,39 +3,35 @@
%s = type { i8 }
; Function Attrs: argmemonly nounwind
-declare void @llvm.memcpy.p0i8.p0i8.i32(i8* nocapture writeonly, i8* nocapture readonly, i32, i1) #0
+declare void @llvm.memcpy.p0.p0.i32(ptr nocapture writeonly, ptr nocapture readonly, i32, i1) #0
; Function Attrs: argmemonly nounwind
-declare void @llvm.memset.p0i8.i32(i8* nocapture writeonly, i8, i32, i1) #0
+declare void @llvm.memset.p0.i32(ptr nocapture writeonly, i8, i32, i1) #0
-declare void @f1(%s* noalias nocapture sret(%s), %s* nocapture readnone)
+declare void @f1(ptr noalias nocapture sret(%s), ptr nocapture readnone)
define void @f2() {
entry:
%c = alloca %s
%tmp = alloca %s
- %0 = bitcast %s* %c to i8*
- %1 = bitcast %s* %tmp to i8*
- call void @llvm.memset.p0i8.i32(i8* %0, i8 0, i32 1, i1 false)
- call void @f1(%s* sret(%s) %c, %s* %c)
+ call void @llvm.memset.p0.i32(ptr %c, i8 0, i32 1, i1 false)
+ call void @f1(ptr sret(%s) %c, ptr %c)
ret void
}
; Lint should complain about us passing %c to both arguments since one of them
; is noalias.
; CHECK: Unusual: noalias argument aliases another argument
-; CHECK-NEXT: call void @f1(%s* sret(%s) %c, %s* %c)
+; CHECK-NEXT: call void @f1(ptr sret(%s) %c, ptr %c)
-declare void @f3(%s* noalias nocapture sret(%s), %s* byval(%s) nocapture readnone)
+declare void @f3(ptr noalias nocapture sret(%s), ptr byval(%s) nocapture readnone)
define void @f4() {
entry:
%c = alloca %s
%tmp = alloca %s
- %0 = bitcast %s* %c to i8*
- %1 = bitcast %s* %tmp to i8*
- call void @llvm.memset.p0i8.i32(i8* %0, i8 0, i32 1, i1 false)
- call void @f3(%s* sret(%s) %c, %s* byval(%s) %c)
+ call void @llvm.memset.p0.i32(ptr %c, i8 0, i32 1, i1 false)
+ call void @f3(ptr sret(%s) %c, ptr byval(%s) %c)
ret void
}
@@ -43,6 +39,6 @@ entry:
; noalias, since the other one is byval, effectively copying the data to the
; stack instead of passing the pointer itself.
; CHECK-NOT: Unusual: noalias argument aliases another argument
-; CHECK-NOT: call void @f3(%s* sret(%s) %c, %s* byval(%s) %c)
+; CHECK-NOT: call void @f3(ptr sret(%s) %c, ptr byval(%s) %c)
attributes #0 = { argmemonly nounwind }
diff --git a/llvm/test/Analysis/Lint/noalias-readonly.ll b/llvm/test/Analysis/Lint/noalias-readonly.ll
index ade4a17c4db28..05bd9dc697e17 100644
--- a/llvm/test/Analysis/Lint/noalias-readonly.ll
+++ b/llvm/test/Analysis/Lint/noalias-readonly.ll
@@ -1,40 +1,40 @@
; RUN: opt < %s -passes=lint -disable-output 2>&1 | FileCheck %s
-declare void @f1(i8* noalias readonly, i8*)
+declare void @f1(ptr noalias readonly, ptr)
-define void @f2(i8* %a) {
+define void @f2(ptr %a) {
entry:
- call void @f1(i8* %a, i8* %a)
+ call void @f1(ptr %a, ptr %a)
ret void
}
; Lint should complain about us passing %a to both arguments, since the noalias
; argument may depend on writes to the other.
; CHECK: Unusual: noalias argument aliases another argument
-; CHECK-NEXT: call void @f1(i8* %a, i8* %a)
+; CHECK-NEXT: call void @f1(ptr %a, ptr %a)
-declare void @f3(i8* noalias, i8* readonly)
+declare void @f3(ptr noalias, ptr readonly)
-define void @f4(i8* %a) {
+define void @f4(ptr %a) {
entry:
- call void @f3(i8* %a, i8* %a)
+ call void @f3(ptr %a, ptr %a)
ret void
}
; Lint should complain about us passing %a to both arguments, since writes to
; the noalias argument may cause a dependency for the other.
; CHECK: Unusual: noalias argument aliases another argument
-; CHECK-NEXT: call void @f3(i8* %a, i8* %a)
+; CHECK-NEXT: call void @f3(ptr %a, ptr %a)
-declare void @f5(i8* noalias readonly, i8* readonly)
+declare void @f5(ptr noalias readonly, ptr readonly)
-define void @f6(i8* %a) {
+define void @f6(ptr %a) {
entry:
- call void @f5(i8* %a, i8* %a)
+ call void @f5(ptr %a, ptr %a)
ret void
}
; Lint should not complain about passing %a to both arguments even if one is
; noalias, since they are both readonly and thus have no dependence.
; CHECK-NOT: Unusual: noalias argument aliases another argument
-; CHECK-NOT: call void @f5(i8* %a, i8* %a)
+; CHECK-NOT: call void @f5(ptr %a, ptr %a)
diff --git a/llvm/test/Analysis/Lint/noop-cast-expr-no-pointer.ll b/llvm/test/Analysis/Lint/noop-cast-expr-no-pointer.ll
index 07066d193721f..d29fa0eb54752 100644
--- a/llvm/test/Analysis/Lint/noop-cast-expr-no-pointer.ll
+++ b/llvm/test/Analysis/Lint/noop-cast-expr-no-pointer.ll
@@ -7,14 +7,14 @@
define void @test1() {
entry:
- tail call void @f1(i16 zext (i1 icmp eq (i32* getelementptr inbounds ([2 x i32], [2 x i32]* @g_2, i64 0, i64 0), i32* getelementptr inbounds ([3 x i32], [3 x i32]* @g_1, i64 0, i64 1)) to i16))
+ tail call void @f1(i16 zext (i1 icmp eq (ptr @g_2, ptr getelementptr inbounds ([3 x i32], ptr @g_1, i64 0, i64 1)) to i16))
ret void
}
declare void @f1(i16)
define void @test2() {
- tail call void inttoptr (i64 sext (i32 ptrtoint (void ()* @f2 to i32) to i64) to void ()*)()
+ tail call void inttoptr (i64 sext (i32 ptrtoint (ptr @f2 to i32) to i64) to ptr)()
ret void
}
diff --git a/llvm/test/Analysis/Lint/tail-call-byval.ll b/llvm/test/Analysis/Lint/tail-call-byval.ll
index bd75f269fdfd2..f82df2f44f83e 100644
--- a/llvm/test/Analysis/Lint/tail-call-byval.ll
+++ b/llvm/test/Analysis/Lint/tail-call-byval.ll
@@ -2,25 +2,25 @@
%s = type { i8 }
-declare void @f1(%s*)
+declare void @f1(ptr)
define void @f2() {
entry:
%c = alloca %s
- tail call void @f1(%s* %c)
+ tail call void @f1(ptr %c)
ret void
}
; Lint should complain about the tail call passing the alloca'd value %c to f1.
; CHECK: Undefined behavior: Call with "tail" keyword references alloca
-; CHECK-NEXT: tail call void @f1(%s* %c)
+; CHECK-NEXT: tail call void @f1(ptr %c)
-declare void @f3(%s* byval(%s))
+declare void @f3(ptr byval(%s))
define void @f4() {
entry:
%c = alloca %s
- tail call void @f3(%s* byval(%s) %c)
+ tail call void @f3(ptr byval(%s) %c)
ret void
}
@@ -28,6 +28,6 @@ entry:
; byval, effectively copying the data to the stack instead of leaking the
; pointer itself.
; CHECK-NOT: Undefined behavior: Call with "tail" keyword references alloca
-; CHECK-NOT: tail call void @f3(%s* byval(%s) %c)
+; CHECK-NOT: tail call void @f3(ptr byval(%s) %c)
More information about the llvm-commits
mailing list