blob: 7072073b66343d03a684b36bc6bdceabe53dfa18 [file]
; RUN: llc -mtriple=amdgpu6.00 -disable-promote-alloca-to-vector -disable-promote-alloca-to-lds < %s
; RUN: llc -mtriple=amdgpu8.02 -disable-promote-alloca-to-vector -disable-promote-alloca-to-lds < %s
; Test that INSERT_SUBREG instructions don't have non-register operands after
; instruction selection.
; Make sure this doesn't crash
; CHECK-LABEL: test:
define amdgpu_kernel void @test(ptr addrspace(1) %out) {
entry:
%tmp0 = alloca [16 x i32], addrspace(5)
%tmp1 = ptrtoint ptr addrspace(5) %tmp0 to i32
%tmp2 = sext i32 %tmp1 to i64
store i64 %tmp2, ptr addrspace(1) %out
ret void
}