1 # FIXME: This should fail the verifier
3 # REQUIRES: amdgpu-registered-target
4 # RUN: not --crash llc -o - -mtriple=amdgcn-amd-amdhsa -run-pass=none -verify-machineinstrs %s 2>&1 | FileCheck %s
6 # %1 is live out of %bb.1 through the loop edge, and therefore the kill flag is invalid.
8 # CHECK: *** Bad machine code: Virtual register killed in block, but needed live out. ***
11 name: kill_flag_in_loop
14 liveins: $sgpr0, $vgpr0_vgpr1
15 successors: %bb.1(0x80000000)
17 %0:sreg_32 = COPY $sgpr0
18 %1:sreg_32 = S_AND_B32 1, killed %0, implicit-def dead $scc
21 successors: %bb.2(0x40000000), %bb.1(0x40000000)
23 S_CMP_EQ_I32 killed %1:sreg_32, 1, implicit-def $scc
24 S_CBRANCH_SCC0 %bb.2, implicit $scc
28 successors: %bb.3(0x80000000)