1 # RUN: llc -march=amdgcn -mcpu=fiji -verify-machineinstrs -run-pass post-RA-hazard-rec -o - %s | FileCheck -check-prefix=GCN %s
3 # GCN-LABEL: name: vmem_vcc_fallthrough
6 # GCN-NEXT: BUFFER_LOAD_DWORD_OFFEN
8 name: vmem_vcc_fallthrough
13 $sgpr0_sgpr1_sgpr2_sgpr3 = IMPLICIT_DEF
15 $vgpr1 = V_ADDC_U32_e32 $vgpr0, $vgpr0, implicit-def $vcc, implicit $vcc, implicit $exec
18 $vgpr1 = BUFFER_LOAD_DWORD_OFFEN $vgpr0, $sgpr0_sgpr1_sgpr2_sgpr3, $vcc_lo, 0, 0, 0, 0, implicit $exec
20 # GCN-LABEL: name: vmem_vcc_branch_to_next
23 # GCN-NEXT: BUFFER_LOAD_DWORD_OFFEN
25 name: vmem_vcc_branch_to_next
30 $sgpr0_sgpr1_sgpr2_sgpr3 = IMPLICIT_DEF
32 $vgpr1 = V_ADDC_U32_e32 $vgpr0, $vgpr0, implicit-def $vcc, implicit $vcc, implicit $exec
36 $vgpr1 = BUFFER_LOAD_DWORD_OFFEN $vgpr0, $sgpr0_sgpr1_sgpr2_sgpr3, $vcc_lo, 0, 0, 0, 0, implicit $exec
38 # GCN-LABEL: name: vmem_vcc_fallthrough_no_hazard_too_far
40 # GCN-NEXT: BUFFER_LOAD_DWORD_OFFEN
42 name: vmem_vcc_fallthrough_no_hazard_too_far
47 $sgpr0_sgpr1_sgpr2_sgpr3 = IMPLICIT_DEF
49 $vgpr1 = V_ADDC_U32_e32 $vgpr0, $vgpr0, implicit-def $vcc, implicit $vcc, implicit $exec
57 $vgpr1 = BUFFER_LOAD_DWORD_OFFEN $vgpr0, $sgpr0_sgpr1_sgpr2_sgpr3, $vcc_lo, 0, 0, 0, 0, implicit $exec
59 # GCN-LABEL: name: vmem_vcc_fallthrough_no_hazard_nops
61 # GCN-NEXT: BUFFER_LOAD_DWORD_OFFEN
63 name: vmem_vcc_fallthrough_no_hazard_nops
68 $sgpr0_sgpr1_sgpr2_sgpr3 = IMPLICIT_DEF
70 $vgpr1 = V_ADDC_U32_e32 $vgpr0, $vgpr0, implicit-def $vcc, implicit $vcc, implicit $exec
74 $vgpr1 = BUFFER_LOAD_DWORD_OFFEN $vgpr0, $sgpr0_sgpr1_sgpr2_sgpr3, $vcc_lo, 0, 0, 0, 0, implicit $exec
76 # GCN-LABEL: name: vmem_vcc_branch_around
79 # GCN-NEXT: BUFFER_LOAD_DWORD_OFFEN
81 name: vmem_vcc_branch_around
86 $sgpr0_sgpr1_sgpr2_sgpr3 = IMPLICIT_DEF
88 $vgpr1 = V_ADDC_U32_e32 $vgpr0, $vgpr0, implicit-def $vcc, implicit $vcc, implicit $exec
100 $vgpr1 = BUFFER_LOAD_DWORD_OFFEN $vgpr0, $sgpr0_sgpr1_sgpr2_sgpr3, $vcc_lo, 0, 0, 0, 0, implicit $exec
102 # GCN-LABEL: name: vmem_vcc_branch_backedge
104 # GCN-NEXT: BUFFER_LOAD_DWORD_OFFEN
106 name: vmem_vcc_branch_backedge
111 $vgpr0 = IMPLICIT_DEF
112 $sgpr0_sgpr1_sgpr2_sgpr3 = IMPLICIT_DEF
113 $vgpr1 = BUFFER_LOAD_DWORD_OFFEN $vgpr0, $sgpr0_sgpr1_sgpr2_sgpr3, $vcc_lo, 0, 0, 0, 0, implicit $exec
116 $vgpr0 = IMPLICIT_DEF
117 $vgpr1 = V_ADDC_U32_e32 $vgpr0, $vgpr0, implicit-def $vcc, implicit $vcc, implicit $exec
120 # GCN-LABEL: name: vmem_vcc_min_of_two
123 # GCN-NEXT: BUFFER_LOAD_DWORD_OFFEN
125 name: vmem_vcc_min_of_two
130 $sgpr0_sgpr1_sgpr2_sgpr3 = IMPLICIT_DEF
131 $vgpr0 = IMPLICIT_DEF
132 $vgpr1 = V_ADDC_U32_e32 $vgpr0, $vgpr0, implicit-def $vcc, implicit $vcc, implicit $exec
139 $vgpr1 = V_ADDC_U32_e32 $vgpr0, $vgpr0, implicit-def $vcc, implicit $vcc, implicit $exec
142 $vgpr1 = BUFFER_LOAD_DWORD_OFFEN $vgpr0, $sgpr0_sgpr1_sgpr2_sgpr3, $vcc_lo, 0, 0, 0, 0, implicit $exec
144 # GCN-LABEL: name: vmem_vcc_self_loop
146 # GCN-NEXT: BUFFER_LOAD_DWORD_OFFEN
148 name: vmem_vcc_self_loop
153 $vgpr0 = IMPLICIT_DEF
154 $sgpr0_sgpr1_sgpr2_sgpr3 = IMPLICIT_DEF
155 $vgpr1 = BUFFER_LOAD_DWORD_OFFEN $vgpr0, $sgpr0_sgpr1_sgpr2_sgpr3, $vcc_lo, 0, 0, 0, 0, implicit $exec
156 $vgpr1 = V_ADDC_U32_e32 $vgpr0, $vgpr0, implicit-def $vcc, implicit $vcc, implicit $exec
159 # GCN-LABEL: name: vmem_vcc_min_of_two_self_loop1
161 # GCN: $sgpr0 = S_MOV_B32 0
163 # GCN-NEXT: BUFFER_LOAD_DWORD_OFFEN
165 name: vmem_vcc_min_of_two_self_loop1
170 $sgpr0_sgpr1_sgpr2_sgpr3 = IMPLICIT_DEF
171 $vgpr0 = IMPLICIT_DEF
172 $vgpr1 = V_ADDC_U32_e32 $vgpr0, $vgpr0, implicit-def $vcc, implicit $vcc, implicit $exec
178 $vgpr1 = BUFFER_LOAD_DWORD_OFFEN $vgpr0, $sgpr0_sgpr1_sgpr2_sgpr3, $vcc_lo, 0, 0, 0, 0, implicit $exec
179 $vgpr1 = V_ADDC_U32_e32 $vgpr1, $vgpr1, implicit-def $vcc, implicit $vcc, implicit $exec
182 # GCN-LABEL: name: vmem_vcc_min_of_two_self_loop2
184 # GCN: $sgpr0 = S_MOV_B32 0
186 # GCN-NEXT: BUFFER_LOAD_DWORD_OFFEN
188 name: vmem_vcc_min_of_two_self_loop2
193 $sgpr0_sgpr1_sgpr2_sgpr3 = IMPLICIT_DEF
194 $vgpr0 = IMPLICIT_DEF
195 $vgpr1 = V_ADDC_U32_e32 $vgpr0, $vgpr0, implicit-def $vcc, implicit $vcc, implicit $exec
202 $vgpr1 = BUFFER_LOAD_DWORD_OFFEN $vgpr0, $sgpr0_sgpr1_sgpr2_sgpr3, $vcc_lo, 0, 0, 0, 0, implicit $exec
203 $vgpr1 = V_ADDC_U32_e32 $vgpr1, $vgpr1, implicit-def $vcc, implicit $vcc, implicit $exec