27 lines · plain
1; RUN: llc -mtriple=amdgcn-amd-amdpal -mcpu=gfx950 < %s | FileCheck -check-prefix=PAL %s2 3; GFX950supports upto 160 KB configurable LDS memory.4; This test checks the min and max size of LDS that can be allocated.5 6; PAL: .shader_functions:7; PAL: test_lds_array_i32:8; PAL: .lds_size: 0x280009; PAL: test_lds_i32:10; PAL: .lds_size: 0x411 12 13@lds.i32 = addrspace(3) global i32 poison14@lds.array.i32 = addrspace(3) global [40959 x i32] poison15 16define amdgpu_gfx void @test_lds_i32(i32 %val) {17 store i32 %val, ptr addrspace(3) @lds.i3218 ret void19}20 21define amdgpu_gfx void @test_lds_array_i32() {22 %gep = getelementptr inbounds [40959 x i32], ptr addrspace(3) @lds.array.i32, i32 0, i32 2023 %val = load i32, ptr addrspace(3) %gep24 store i32 %val, ptr addrspace(3) @lds.i3225 ret void26}27