1 # NOTE: Assertions have been autogenerated by utils/update_mir_test_checks.py
3 # RUN: llc -march=amdgcn -mcpu=fiji -run-pass=instruction-select -global-isel-abort=2 -pass-remarks-missed='gisel*' -verify-machineinstrs %s -o - 2>%t | FileCheck -check-prefix=GFX8 %s
4 # RUN: FileCheck -check-prefixes=ERR-GFX8,ERR %s < %t
6 # RUN: llc -march=amdgcn -mcpu=gfx900 -run-pass=instruction-select -global-isel-abort=2 -pass-remarks-missed='gisel*' -verify-machineinstrs %s -o - 2>%t | FileCheck -check-prefix=GFX9 %s
7 # RUN: FileCheck -check-prefixes=ERR-GFX910,ERR %s < %t
9 # RUN: llc -march=amdgcn -mcpu=gfx1010 -run-pass=instruction-select -global-isel-abort=2 -pass-remarks-missed='gisel*' -verify-machineinstrs %s -o - 2>%t | FileCheck -check-prefix=GFX10 %s
10 # RUN: FileCheck -check-prefixes=ERR-GFX910,ERR %s < %t
13 # ERR: remark: <unknown>:0:0: cannot select: %4:sgpr(s16) = G_SHL %2:sgpr, %3:sgpr(s16) (in function: shl_s16_s16_ss)
14 # ERR-NEXT: remark: <unknown>:0:0: cannot select: %3:vgpr(s16) = G_SHL %2:vgpr, %1:vgpr(s32) (in function: shl_s16_s32_vv)
15 # ERR-NEXT: remark: <unknown>:0:0: cannot select: %5:vgpr(s64) = G_ZEXT %4:vgpr(s16) (in function: shl_s16_vv_zext_to_s64)
16 # ERR-NEXT: remark: <unknown>:0:0: cannot select: %3:sgpr(s16) = G_SHL %2:sgpr, %1:sgpr(s32) (in function: shl_s16_s32_ss)
17 # ERR-NEXT: remark: <unknown>:0:0: cannot select: %3:vgpr(s16) = G_SHL %2:sgpr, %1:vgpr(s32) (in function: shl_s16_s32_sv)
18 # ERR-NEXT: remark: <unknown>:0:0: cannot select: %3:vgpr(s16) = G_SHL %2:vgpr, %1:sgpr(s32) (in function: shl_s16_s32_vs)
28 liveins: $sgpr0, $sgpr1
30 ; GFX8-LABEL: name: shl_s16_s16_ss
31 ; GFX8: [[COPY:%[0-9]+]]:sgpr(s32) = COPY $sgpr0
32 ; GFX8: [[COPY1:%[0-9]+]]:sgpr(s32) = COPY $sgpr1
33 ; GFX8: [[TRUNC:%[0-9]+]]:sgpr(s16) = G_TRUNC [[COPY]](s32)
34 ; GFX8: [[TRUNC1:%[0-9]+]]:sgpr(s16) = G_TRUNC [[COPY1]](s32)
35 ; GFX8: [[SHL:%[0-9]+]]:sgpr(s16) = G_SHL [[TRUNC]], [[TRUNC1]](s16)
36 ; GFX8: S_ENDPGM 0, implicit [[SHL]](s16)
37 ; GFX9-LABEL: name: shl_s16_s16_ss
38 ; GFX9: [[COPY:%[0-9]+]]:sgpr(s32) = COPY $sgpr0
39 ; GFX9: [[COPY1:%[0-9]+]]:sgpr(s32) = COPY $sgpr1
40 ; GFX9: [[TRUNC:%[0-9]+]]:sgpr(s16) = G_TRUNC [[COPY]](s32)
41 ; GFX9: [[TRUNC1:%[0-9]+]]:sgpr(s16) = G_TRUNC [[COPY1]](s32)
42 ; GFX9: [[SHL:%[0-9]+]]:sgpr(s16) = G_SHL [[TRUNC]], [[TRUNC1]](s16)
43 ; GFX9: S_ENDPGM 0, implicit [[SHL]](s16)
44 ; GFX10-LABEL: name: shl_s16_s16_ss
45 ; GFX10: [[COPY:%[0-9]+]]:sgpr(s32) = COPY $sgpr0
46 ; GFX10: [[COPY1:%[0-9]+]]:sgpr(s32) = COPY $sgpr1
47 ; GFX10: [[TRUNC:%[0-9]+]]:sgpr(s16) = G_TRUNC [[COPY]](s32)
48 ; GFX10: [[TRUNC1:%[0-9]+]]:sgpr(s16) = G_TRUNC [[COPY1]](s32)
49 ; GFX10: [[SHL:%[0-9]+]]:sgpr(s16) = G_SHL [[TRUNC]], [[TRUNC1]](s16)
50 ; GFX10: S_ENDPGM 0, implicit [[SHL]](s16)
51 %0:sgpr(s32) = COPY $sgpr0
52 %1:sgpr(s32) = COPY $sgpr1
53 %2:sgpr(s16) = G_TRUNC %0
54 %3:sgpr(s16) = G_TRUNC %1
55 %4:sgpr(s16) = G_SHL %2, %3
56 S_ENDPGM 0, implicit %4
66 liveins: $sgpr0, $vgpr0
67 ; GFX8-LABEL: name: shl_s16_s16_vs
68 ; GFX8: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
69 ; GFX8: [[COPY1:%[0-9]+]]:sreg_32 = COPY $sgpr0
70 ; GFX8: [[V_LSHLREV_B16_e64_:%[0-9]+]]:vgpr_32 = V_LSHLREV_B16_e64 [[COPY1]], [[COPY]], implicit $exec
71 ; GFX8: S_ENDPGM 0, implicit [[V_LSHLREV_B16_e64_]]
72 ; GFX9-LABEL: name: shl_s16_s16_vs
73 ; GFX9: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
74 ; GFX9: [[COPY1:%[0-9]+]]:sreg_32 = COPY $sgpr0
75 ; GFX9: [[V_LSHLREV_B16_e64_:%[0-9]+]]:vgpr_32 = V_LSHLREV_B16_e64 [[COPY1]], [[COPY]], implicit $exec
76 ; GFX9: S_ENDPGM 0, implicit [[V_LSHLREV_B16_e64_]]
77 ; GFX10-LABEL: name: shl_s16_s16_vs
78 ; GFX10: $vcc_hi = IMPLICIT_DEF
79 ; GFX10: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
80 ; GFX10: [[COPY1:%[0-9]+]]:sreg_32 = COPY $sgpr0
81 ; GFX10: [[V_LSHLREV_B16_e64_:%[0-9]+]]:vgpr_32 = V_LSHLREV_B16_e64 [[COPY1]], [[COPY]], implicit $exec
82 ; GFX10: S_ENDPGM 0, implicit [[V_LSHLREV_B16_e64_]]
83 %0:vgpr(s32) = COPY $vgpr0
84 %1:sgpr(s32) = COPY $sgpr0
85 %2:vgpr(s16) = G_TRUNC %0
86 %3:sgpr(s16) = G_TRUNC %1
87 %4:vgpr(s16) = G_SHL %2, %3
88 S_ENDPGM 0, implicit %4
98 liveins: $vgpr0, $vgpr1
100 ; GFX8-LABEL: name: shl_s16_s32_vv
101 ; GFX8: [[COPY:%[0-9]+]]:vgpr(s32) = COPY $vgpr0
102 ; GFX8: [[COPY1:%[0-9]+]]:vgpr(s32) = COPY $vgpr1
103 ; GFX8: [[TRUNC:%[0-9]+]]:vgpr(s16) = G_TRUNC [[COPY]](s32)
104 ; GFX8: [[SHL:%[0-9]+]]:vgpr(s16) = G_SHL [[TRUNC]], [[COPY1]](s32)
105 ; GFX8: S_ENDPGM 0, implicit [[SHL]](s16)
106 ; GFX9-LABEL: name: shl_s16_s32_vv
107 ; GFX9: [[COPY:%[0-9]+]]:vgpr(s32) = COPY $vgpr0
108 ; GFX9: [[COPY1:%[0-9]+]]:vgpr(s32) = COPY $vgpr1
109 ; GFX9: [[TRUNC:%[0-9]+]]:vgpr(s16) = G_TRUNC [[COPY]](s32)
110 ; GFX9: [[SHL:%[0-9]+]]:vgpr(s16) = G_SHL [[TRUNC]], [[COPY1]](s32)
111 ; GFX9: S_ENDPGM 0, implicit [[SHL]](s16)
112 ; GFX10-LABEL: name: shl_s16_s32_vv
113 ; GFX10: [[COPY:%[0-9]+]]:vgpr(s32) = COPY $vgpr0
114 ; GFX10: [[COPY1:%[0-9]+]]:vgpr(s32) = COPY $vgpr1
115 ; GFX10: [[TRUNC:%[0-9]+]]:vgpr(s16) = G_TRUNC [[COPY]](s32)
116 ; GFX10: [[SHL:%[0-9]+]]:vgpr(s16) = G_SHL [[TRUNC]], [[COPY1]](s32)
117 ; GFX10: S_ENDPGM 0, implicit [[SHL]](s16)
118 %0:vgpr(s32) = COPY $vgpr0
119 %1:vgpr(s32) = COPY $vgpr1
120 %2:vgpr(s16) = G_TRUNC %0
121 %3:vgpr(s16) = G_SHL %2, %1
122 S_ENDPGM 0, implicit %3
128 regBankSelected: true
132 liveins: $vgpr0, $vgpr1
134 ; GFX8-LABEL: name: shl_s16_s16_vv
135 ; GFX8: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
136 ; GFX8: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr1
137 ; GFX8: [[V_LSHLREV_B16_e64_:%[0-9]+]]:vgpr_32 = V_LSHLREV_B16_e64 [[COPY1]], [[COPY]], implicit $exec
138 ; GFX8: S_ENDPGM 0, implicit [[V_LSHLREV_B16_e64_]]
139 ; GFX9-LABEL: name: shl_s16_s16_vv
140 ; GFX9: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
141 ; GFX9: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr1
142 ; GFX9: [[V_LSHLREV_B16_e64_:%[0-9]+]]:vgpr_32 = V_LSHLREV_B16_e64 [[COPY1]], [[COPY]], implicit $exec
143 ; GFX9: S_ENDPGM 0, implicit [[V_LSHLREV_B16_e64_]]
144 ; GFX10-LABEL: name: shl_s16_s16_vv
145 ; GFX10: $vcc_hi = IMPLICIT_DEF
146 ; GFX10: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
147 ; GFX10: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr1
148 ; GFX10: [[V_LSHLREV_B16_e64_:%[0-9]+]]:vgpr_32 = V_LSHLREV_B16_e64 [[COPY1]], [[COPY]], implicit $exec
149 ; GFX10: S_ENDPGM 0, implicit [[V_LSHLREV_B16_e64_]]
150 %0:vgpr(s32) = COPY $vgpr0
151 %1:vgpr(s32) = COPY $vgpr1
152 %2:vgpr(s16) = G_TRUNC %0
153 %3:vgpr(s16) = G_TRUNC %1
154 %4:vgpr(s16) = G_SHL %2, %3
155 S_ENDPGM 0, implicit %4
159 name: shl_s16_s16_vv_zext_to_s32
161 regBankSelected: true
165 liveins: $vgpr0, $vgpr1
167 ; GFX8-LABEL: name: shl_s16_s16_vv_zext_to_s32
168 ; GFX8: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
169 ; GFX8: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr1
170 ; GFX8: [[V_LSHLREV_B16_e64_:%[0-9]+]]:vgpr_32 = V_LSHLREV_B16_e64 [[COPY1]], [[COPY]], implicit $exec
171 ; GFX8: [[V_BFE_U32_:%[0-9]+]]:vgpr_32 = V_BFE_U32 [[V_LSHLREV_B16_e64_]], 0, 16, implicit $exec
172 ; GFX8: S_ENDPGM 0, implicit [[V_BFE_U32_]]
173 ; GFX9-LABEL: name: shl_s16_s16_vv_zext_to_s32
174 ; GFX9: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
175 ; GFX9: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr1
176 ; GFX9: [[V_LSHLREV_B16_e64_:%[0-9]+]]:vgpr_32 = V_LSHLREV_B16_e64 [[COPY1]], [[COPY]], implicit $exec
177 ; GFX9: [[V_BFE_U32_:%[0-9]+]]:vgpr_32 = V_BFE_U32 [[V_LSHLREV_B16_e64_]], 0, 16, implicit $exec
178 ; GFX9: S_ENDPGM 0, implicit [[V_BFE_U32_]]
179 ; GFX10-LABEL: name: shl_s16_s16_vv_zext_to_s32
180 ; GFX10: $vcc_hi = IMPLICIT_DEF
181 ; GFX10: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
182 ; GFX10: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr1
183 ; GFX10: [[V_LSHLREV_B16_e64_:%[0-9]+]]:vgpr_32 = V_LSHLREV_B16_e64 [[COPY1]], [[COPY]], implicit $exec
184 ; GFX10: [[V_BFE_U32_:%[0-9]+]]:vgpr_32 = V_BFE_U32 [[V_LSHLREV_B16_e64_]], 0, 16, implicit $exec
185 ; GFX10: S_ENDPGM 0, implicit [[V_BFE_U32_]]
186 %0:vgpr(s32) = COPY $vgpr0
187 %1:vgpr(s32) = COPY $vgpr1
188 %2:vgpr(s16) = G_TRUNC %0
189 %3:vgpr(s16) = G_TRUNC %1
190 %4:vgpr(s16) = G_SHL %2, %3
191 %5:vgpr(s32) = G_ZEXT %4
192 S_ENDPGM 0, implicit %5
196 name: shl_s16_vv_zext_to_s64
198 regBankSelected: true
202 liveins: $vgpr0, $vgpr1
204 ; GFX8-LABEL: name: shl_s16_vv_zext_to_s64
205 ; GFX8: [[COPY:%[0-9]+]]:vgpr(s32) = COPY $vgpr0
206 ; GFX8: [[COPY1:%[0-9]+]]:vgpr(s32) = COPY $vgpr1
207 ; GFX8: [[TRUNC:%[0-9]+]]:vgpr(s16) = G_TRUNC [[COPY]](s32)
208 ; GFX8: [[TRUNC1:%[0-9]+]]:vgpr(s16) = G_TRUNC [[COPY1]](s32)
209 ; GFX8: [[SHL:%[0-9]+]]:vgpr(s16) = G_SHL [[TRUNC]], [[TRUNC1]](s16)
210 ; GFX8: [[ZEXT:%[0-9]+]]:vgpr(s64) = G_ZEXT [[SHL]](s16)
211 ; GFX8: S_ENDPGM 0, implicit [[ZEXT]](s64)
212 ; GFX9-LABEL: name: shl_s16_vv_zext_to_s64
213 ; GFX9: [[COPY:%[0-9]+]]:vgpr(s32) = COPY $vgpr0
214 ; GFX9: [[COPY1:%[0-9]+]]:vgpr(s32) = COPY $vgpr1
215 ; GFX9: [[TRUNC:%[0-9]+]]:vgpr(s16) = G_TRUNC [[COPY]](s32)
216 ; GFX9: [[TRUNC1:%[0-9]+]]:vgpr(s16) = G_TRUNC [[COPY1]](s32)
217 ; GFX9: [[SHL:%[0-9]+]]:vgpr(s16) = G_SHL [[TRUNC]], [[TRUNC1]](s16)
218 ; GFX9: [[ZEXT:%[0-9]+]]:vgpr(s64) = G_ZEXT [[SHL]](s16)
219 ; GFX9: S_ENDPGM 0, implicit [[ZEXT]](s64)
220 ; GFX10-LABEL: name: shl_s16_vv_zext_to_s64
221 ; GFX10: [[COPY:%[0-9]+]]:vgpr(s32) = COPY $vgpr0
222 ; GFX10: [[COPY1:%[0-9]+]]:vgpr(s32) = COPY $vgpr1
223 ; GFX10: [[TRUNC:%[0-9]+]]:vgpr(s16) = G_TRUNC [[COPY]](s32)
224 ; GFX10: [[TRUNC1:%[0-9]+]]:vgpr(s16) = G_TRUNC [[COPY1]](s32)
225 ; GFX10: [[SHL:%[0-9]+]]:vgpr(s16) = G_SHL [[TRUNC]], [[TRUNC1]](s16)
226 ; GFX10: [[ZEXT:%[0-9]+]]:vgpr(s64) = G_ZEXT [[SHL]](s16)
227 ; GFX10: S_ENDPGM 0, implicit [[ZEXT]](s64)
228 %0:vgpr(s32) = COPY $vgpr0
229 %1:vgpr(s32) = COPY $vgpr1
230 %2:vgpr(s16) = G_TRUNC %0
231 %3:vgpr(s16) = G_TRUNC %1
232 %4:vgpr(s16) = G_SHL %2, %3
233 %5:vgpr(s64) = G_ZEXT %4
234 S_ENDPGM 0, implicit %5
240 regBankSelected: true
244 liveins: $sgpr0, $sgpr1
246 ; GFX8-LABEL: name: shl_s16_s32_ss
247 ; GFX8: [[COPY:%[0-9]+]]:sgpr(s32) = COPY $sgpr0
248 ; GFX8: [[COPY1:%[0-9]+]]:sgpr(s32) = COPY $sgpr1
249 ; GFX8: [[TRUNC:%[0-9]+]]:sgpr(s16) = G_TRUNC [[COPY]](s32)
250 ; GFX8: [[SHL:%[0-9]+]]:sgpr(s16) = G_SHL [[TRUNC]], [[COPY1]](s32)
251 ; GFX8: S_ENDPGM 0, implicit [[SHL]](s16)
252 ; GFX9-LABEL: name: shl_s16_s32_ss
253 ; GFX9: [[COPY:%[0-9]+]]:sgpr(s32) = COPY $sgpr0
254 ; GFX9: [[COPY1:%[0-9]+]]:sgpr(s32) = COPY $sgpr1
255 ; GFX9: [[TRUNC:%[0-9]+]]:sgpr(s16) = G_TRUNC [[COPY]](s32)
256 ; GFX9: [[SHL:%[0-9]+]]:sgpr(s16) = G_SHL [[TRUNC]], [[COPY1]](s32)
257 ; GFX9: S_ENDPGM 0, implicit [[SHL]](s16)
258 ; GFX10-LABEL: name: shl_s16_s32_ss
259 ; GFX10: [[COPY:%[0-9]+]]:sgpr(s32) = COPY $sgpr0
260 ; GFX10: [[COPY1:%[0-9]+]]:sgpr(s32) = COPY $sgpr1
261 ; GFX10: [[TRUNC:%[0-9]+]]:sgpr(s16) = G_TRUNC [[COPY]](s32)
262 ; GFX10: [[SHL:%[0-9]+]]:sgpr(s16) = G_SHL [[TRUNC]], [[COPY1]](s32)
263 ; GFX10: S_ENDPGM 0, implicit [[SHL]](s16)
264 %0:sgpr(s32) = COPY $sgpr0
265 %1:sgpr(s32) = COPY $sgpr1
266 %2:sgpr(s16) = G_TRUNC %0
267 %3:sgpr(s16) = G_SHL %2, %1
268 S_ENDPGM 0, implicit %3
274 regBankSelected: true
278 liveins: $sgpr0, $vgpr0
279 ; GFX8-LABEL: name: shl_s16_s32_sv
280 ; GFX8: [[COPY:%[0-9]+]]:sgpr(s32) = COPY $sgpr0
281 ; GFX8: [[COPY1:%[0-9]+]]:vgpr(s32) = COPY $vgpr0
282 ; GFX8: [[TRUNC:%[0-9]+]]:sgpr(s16) = G_TRUNC [[COPY]](s32)
283 ; GFX8: [[SHL:%[0-9]+]]:vgpr(s16) = G_SHL [[TRUNC]], [[COPY1]](s32)
284 ; GFX8: S_ENDPGM 0, implicit [[SHL]](s16)
285 ; GFX9-LABEL: name: shl_s16_s32_sv
286 ; GFX9: [[COPY:%[0-9]+]]:sgpr(s32) = COPY $sgpr0
287 ; GFX9: [[COPY1:%[0-9]+]]:vgpr(s32) = COPY $vgpr0
288 ; GFX9: [[TRUNC:%[0-9]+]]:sgpr(s16) = G_TRUNC [[COPY]](s32)
289 ; GFX9: [[SHL:%[0-9]+]]:vgpr(s16) = G_SHL [[TRUNC]], [[COPY1]](s32)
290 ; GFX9: S_ENDPGM 0, implicit [[SHL]](s16)
291 ; GFX10-LABEL: name: shl_s16_s32_sv
292 ; GFX10: [[COPY:%[0-9]+]]:sgpr(s32) = COPY $sgpr0
293 ; GFX10: [[COPY1:%[0-9]+]]:vgpr(s32) = COPY $vgpr0
294 ; GFX10: [[TRUNC:%[0-9]+]]:sgpr(s16) = G_TRUNC [[COPY]](s32)
295 ; GFX10: [[SHL:%[0-9]+]]:vgpr(s16) = G_SHL [[TRUNC]], [[COPY1]](s32)
296 ; GFX10: S_ENDPGM 0, implicit [[SHL]](s16)
297 %0:sgpr(s32) = COPY $sgpr0
298 %1:vgpr(s32) = COPY $vgpr0
299 %2:sgpr(s16) = G_TRUNC %0
300 %3:vgpr(s16) = G_SHL %2, %1
301 S_ENDPGM 0, implicit %3
307 regBankSelected: true
311 liveins: $sgpr0, $vgpr0
312 ; GFX8-LABEL: name: shl_s16_s16_sv
313 ; GFX8: [[COPY:%[0-9]+]]:sreg_32 = COPY $sgpr0
314 ; GFX8: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr0
315 ; GFX8: [[V_LSHLREV_B16_e64_:%[0-9]+]]:vgpr_32 = V_LSHLREV_B16_e64 [[COPY1]], [[COPY]], implicit $exec
316 ; GFX8: S_ENDPGM 0, implicit [[V_LSHLREV_B16_e64_]]
317 ; GFX9-LABEL: name: shl_s16_s16_sv
318 ; GFX9: [[COPY:%[0-9]+]]:sreg_32 = COPY $sgpr0
319 ; GFX9: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr0
320 ; GFX9: [[V_LSHLREV_B16_e64_:%[0-9]+]]:vgpr_32 = V_LSHLREV_B16_e64 [[COPY1]], [[COPY]], implicit $exec
321 ; GFX9: S_ENDPGM 0, implicit [[V_LSHLREV_B16_e64_]]
322 ; GFX10-LABEL: name: shl_s16_s16_sv
323 ; GFX10: $vcc_hi = IMPLICIT_DEF
324 ; GFX10: [[COPY:%[0-9]+]]:sreg_32 = COPY $sgpr0
325 ; GFX10: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr0
326 ; GFX10: [[V_LSHLREV_B16_e64_:%[0-9]+]]:vgpr_32 = V_LSHLREV_B16_e64 [[COPY1]], [[COPY]], implicit $exec
327 ; GFX10: S_ENDPGM 0, implicit [[V_LSHLREV_B16_e64_]]
328 %0:sgpr(s32) = COPY $sgpr0
329 %1:vgpr(s32) = COPY $vgpr0
330 %2:sgpr(s16) = G_TRUNC %0
331 %3:vgpr(s16) = G_TRUNC %1
332 %4:vgpr(s16) = G_SHL %2, %3
333 S_ENDPGM 0, implicit %4
339 regBankSelected: true
343 liveins: $sgpr0, $vgpr0
344 ; GFX8-LABEL: name: shl_s16_s32_vs
345 ; GFX8: [[COPY:%[0-9]+]]:vgpr(s32) = COPY $vgpr0
346 ; GFX8: [[COPY1:%[0-9]+]]:sgpr(s32) = COPY $sgpr0
347 ; GFX8: [[TRUNC:%[0-9]+]]:vgpr(s16) = G_TRUNC [[COPY]](s32)
348 ; GFX8: [[SHL:%[0-9]+]]:vgpr(s16) = G_SHL [[TRUNC]], [[COPY1]](s32)
349 ; GFX8: S_ENDPGM 0, implicit [[SHL]](s16)
350 ; GFX9-LABEL: name: shl_s16_s32_vs
351 ; GFX9: [[COPY:%[0-9]+]]:vgpr(s32) = COPY $vgpr0
352 ; GFX9: [[COPY1:%[0-9]+]]:sgpr(s32) = COPY $sgpr0
353 ; GFX9: [[TRUNC:%[0-9]+]]:vgpr(s16) = G_TRUNC [[COPY]](s32)
354 ; GFX9: [[SHL:%[0-9]+]]:vgpr(s16) = G_SHL [[TRUNC]], [[COPY1]](s32)
355 ; GFX9: S_ENDPGM 0, implicit [[SHL]](s16)
356 ; GFX10-LABEL: name: shl_s16_s32_vs
357 ; GFX10: [[COPY:%[0-9]+]]:vgpr(s32) = COPY $vgpr0
358 ; GFX10: [[COPY1:%[0-9]+]]:sgpr(s32) = COPY $sgpr0
359 ; GFX10: [[TRUNC:%[0-9]+]]:vgpr(s16) = G_TRUNC [[COPY]](s32)
360 ; GFX10: [[SHL:%[0-9]+]]:vgpr(s16) = G_SHL [[TRUNC]], [[COPY1]](s32)
361 ; GFX10: S_ENDPGM 0, implicit [[SHL]](s16)
362 %0:vgpr(s32) = COPY $vgpr0
363 %1:sgpr(s32) = COPY $sgpr0
364 %2:vgpr(s16) = G_TRUNC %0
365 %3:vgpr(s16) = G_SHL %2, %1
366 S_ENDPGM 0, implicit %3