1 ; RUN: llc -O0 -mtriple=spirv32-unknown-unknown %s -o - | FileCheck %s
4 ; CHECK: %[[FooArg:.*]] = OpVariable
5 ; CHECK: OpLifetimeStart %[[FooArg]], 0
6 ; CHECK: OpCopyMemorySized
8 ; CHECK: OpInBoundsPtrAccessChain
9 ; CHECK: OpLifetimeStop %[[FooArg]], 0
11 %tprange = type { %tparray }
12 %tparray = type { [2 x i64] }
14 define spir_func void @foo(ptr noundef byval(%tprange) align 8 %_arg_UserRange) {
15 %RoundedRangeKernel = alloca %tprange, align 8
16 call void @llvm.lifetime.start.p0(i64 72, ptr nonnull %RoundedRangeKernel) #7
17 call void @llvm.memcpy.p0.p0.i64(ptr align 8 %RoundedRangeKernel, ptr align 8 %_arg_UserRange, i64 16, i1 false)
18 %KernelFunc = getelementptr inbounds i8, ptr %RoundedRangeKernel, i64 16
19 call void @llvm.lifetime.end.p0(i64 72, ptr nonnull %RoundedRangeKernel) #7
23 declare void @llvm.lifetime.start.p0(i64 immarg, ptr nocapture)
24 declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg)
25 declare void @llvm.lifetime.end.p0(i64 immarg, ptr nocapture)