blob: 85f76a0659022a5fc770673ce48c6c1f4bad78b9 [file] [log] [blame]
Fangrui Song9e9907f2024-01-16 21:54:58 -08001; RUN: llc -mtriple=amdgcn -mcpu=tahiti -verify-machineinstrs< %s
2; RUN: llc -mtriple=amdgcn -mcpu=tonga -verify-machineinstrs< %s
Matt Arsenaulta2438bd2013-10-08 18:06:36 +00003
Tom Stellard162a9472014-08-21 20:40:58 +00004; This tests for a bug that caused a crash in
5; AMDGPUDAGToDAGISel::SelectMUBUFScratch() which is used for selecting
6; scratch loads and stores.
Tom Stellard79243d92014-10-01 17:15:17 +00007; CHECK-LABEL: {{^}}store_vector_ptrs:
Nikita Popovbdf2fbb2022-12-19 12:39:01 +01008define amdgpu_kernel void @store_vector_ptrs(ptr addrspace(5) %out, <4 x ptr addrspace(5)> %array) nounwind {
9 %p = getelementptr [1024 x i32], <4 x ptr addrspace(5)> %array, <4 x i16> zeroinitializer, <4 x i16> <i16 16, i16 16, i16 16, i16 16>
10 store <4 x ptr addrspace(5)> %p, ptr addrspace(5) %out
Matt Arsenaulta2438bd2013-10-08 18:06:36 +000011 ret void
Tom Stellard162a9472014-08-21 20:40:58 +000012}