1*9880d681SAndroid Build Coastguard Worker; RUN: llc -march=amdgcn -mcpu=SI -mattr=-promote-alloca -verify-machineinstrs < %s 2*9880d681SAndroid Build Coastguard Worker; RUN: llc -march=amdgcn -mcpu=tonga -mattr=-promote-alloca -verify-machineinstrs < %s 3*9880d681SAndroid Build Coastguard Worker 4*9880d681SAndroid Build Coastguard Worker; Test that INSERT_SUBREG instructions don't have non-register operands after 5*9880d681SAndroid Build Coastguard Worker; instruction selection. 6*9880d681SAndroid Build Coastguard Worker 7*9880d681SAndroid Build Coastguard Worker; Make sure this doesn't crash 8*9880d681SAndroid Build Coastguard Worker; CHECK-LABEL: test: 9*9880d681SAndroid Build Coastguard Workerdefine void @test(i64 addrspace(1)* %out) { 10*9880d681SAndroid Build Coastguard Workerentry: 11*9880d681SAndroid Build Coastguard Worker %tmp0 = alloca [16 x i32] 12*9880d681SAndroid Build Coastguard Worker %tmp1 = ptrtoint [16 x i32]* %tmp0 to i32 13*9880d681SAndroid Build Coastguard Worker %tmp2 = sext i32 %tmp1 to i64 14*9880d681SAndroid Build Coastguard Worker store i64 %tmp2, i64 addrspace(1)* %out 15*9880d681SAndroid Build Coastguard Worker ret void 16*9880d681SAndroid Build Coastguard Worker} 17