1 # RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx900 -verify-machineinstrs -run-pass post-RA-sched %s -o - | FileCheck -check-prefix=GCN %s
3 # WAVE_BARRIER and SI_MASKED_UNREACHABLE are not really instructions.
4 # To fix the hazard (m0 def followed by V_INTERP), the scheduler
5 # should move another instruction into the slot.
7 # CHECK-LABEL: name: hazard_wave_barrier
9 # GCN: $m0 = S_MOV_B32 killed renamable $sgpr0
10 # GCN-NEXT: WAVE_BARRIER
11 # GCN-NEXT: S_MOV_B32 0
12 # GCN-NEXT: V_INTERP_MOV_F32
13 name: hazard_wave_barrier
14 tracksRegLiveness: true
19 $m0 = S_MOV_B32 killed renamable $sgpr0
21 renamable $vgpr0 = V_INTERP_MOV_F32 2, 0, 0, implicit $mode, implicit $m0, implicit $exec
22 renamable $sgpr1 = S_MOV_B32 0
26 # GCN-LABEL: name: hazard-masked-unreachable
28 # GCN: $m0 = S_MOV_B32 killed renamable $sgpr0
29 # GCN-NEXT: SI_MASKED_UNREACHABLE
30 # GCN-NEXT: S_MOV_B32 0
31 # GCN-NEXT: V_INTERP_MOV_F32
33 name: hazard-masked-unreachable
34 tracksRegLiveness: true
39 $m0 = S_MOV_B32 killed renamable $sgpr0
41 renamable $vgpr0 = V_INTERP_MOV_F32 2, 0, 0, implicit $mode, implicit $m0, implicit $exec
42 renamable $sgpr1 = S_MOV_B32 0