From 229c466bc8fbb44326fee7f3b11038aaa8f5f369 Mon Sep 17 00:00:00 2001 From: Christudasan Devadasan Date: Thu, 15 Dec 2022 23:16:53 +0530 Subject: [PATCH] [AMDGPU] Test fixup Changing cast_lds_gv into a kernel function to lower the LDS usage appropriately. The LDS lowering is currently won't happen for orphan device functions. --- llvm/test/CodeGen/AMDGPU/addrspacecast-known-non-null.ll | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/llvm/test/CodeGen/AMDGPU/addrspacecast-known-non-null.ll b/llvm/test/CodeGen/AMDGPU/addrspacecast-known-non-null.ll index 95d35c3..7cf5648 100644 --- a/llvm/test/CodeGen/AMDGPU/addrspacecast-known-non-null.ll +++ b/llvm/test/CodeGen/AMDGPU/addrspacecast-known-non-null.ll @@ -25,10 +25,11 @@ define void @cast_alloca() { ; CHECK-LABEL: {{^}}cast_lds_gv: ; CHECK: s_mov_b64 s[{{[0-9]+}}:[[HIREG:[0-9]+]]], src_shared_base +; CHECK: v_mov_b32_e32 v0, 0 ; CHECK: v_mov_b32_e32 v1, s[[HIREG]] ; CHECK-NOT: v0 ; CHECK-NOT: v1 -define void @cast_lds_gv() { +define amdgpu_kernel void @cast_lds_gv() { %cast = addrspacecast ptr addrspace(3) @lds to ptr call void @flat_user(ptr %cast) ret void -- 2.7.4