1 # NOTE: Assertions have been autogenerated by utils/update_mir_test_checks.py
2 # RUN: llc -march=amdgcn -mcpu=fiji -run-pass=amdgpu-regbankselect %s -verify-machineinstrs -o - -regbankselect-fast | FileCheck %s
3 # RUN: llc -march=amdgcn -mcpu=fiji -run-pass=amdgpu-regbankselect %s -verify-machineinstrs -o - -regbankselect-greedy | FileCheck %s
11 liveins: $sgpr0, $sgpr1
12 ; CHECK-LABEL: name: xor_s32_ss
13 ; CHECK: liveins: $sgpr0, $sgpr1
15 ; CHECK-NEXT: [[COPY:%[0-9]+]]:sgpr(s32) = COPY $sgpr0
16 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:sgpr(s32) = COPY $sgpr1
17 ; CHECK-NEXT: [[XOR:%[0-9]+]]:sgpr(s32) = G_XOR [[COPY]], [[COPY1]]
18 %0:_(s32) = COPY $sgpr0
19 %1:_(s32) = COPY $sgpr1
20 %2:_(s32) = G_XOR %0, %1
29 liveins: $sgpr0, $vgpr0
30 ; CHECK-LABEL: name: xor_s32_sv
31 ; CHECK: liveins: $sgpr0, $vgpr0
33 ; CHECK-NEXT: [[COPY:%[0-9]+]]:sgpr(s32) = COPY $sgpr0
34 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:vgpr(s32) = COPY $vgpr0
35 ; CHECK-NEXT: [[COPY2:%[0-9]+]]:vgpr(s32) = COPY [[COPY]](s32)
36 ; CHECK-NEXT: [[XOR:%[0-9]+]]:vgpr(s32) = G_XOR [[COPY2]], [[COPY1]]
37 %0:_(s32) = COPY $sgpr0
38 %1:_(s32) = COPY $vgpr0
39 %2:_(s32) = G_XOR %0, %1
48 liveins: $sgpr0, $vgpr0
49 ; CHECK-LABEL: name: xor_s32_vs
50 ; CHECK: liveins: $sgpr0, $vgpr0
52 ; CHECK-NEXT: [[COPY:%[0-9]+]]:vgpr(s32) = COPY $vgpr0
53 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:sgpr(s32) = COPY $sgpr0
54 ; CHECK-NEXT: [[COPY2:%[0-9]+]]:vgpr(s32) = COPY [[COPY1]](s32)
55 ; CHECK-NEXT: [[XOR:%[0-9]+]]:vgpr(s32) = G_XOR [[COPY]], [[COPY2]]
56 %0:_(s32) = COPY $vgpr0
57 %1:_(s32) = COPY $sgpr0
58 %2:_(s32) = G_XOR %0, %1
67 liveins: $vgpr0, $vgpr1
68 ; CHECK-LABEL: name: xor_s32_vv
69 ; CHECK: liveins: $vgpr0, $vgpr1
71 ; CHECK-NEXT: [[COPY:%[0-9]+]]:vgpr(s32) = COPY $vgpr0
72 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:vgpr(s32) = COPY $vgpr1
73 ; CHECK-NEXT: [[XOR:%[0-9]+]]:vgpr(s32) = G_XOR [[COPY]], [[COPY1]]
74 %0:_(s32) = COPY $vgpr0
75 %1:_(s32) = COPY $vgpr1
76 %2:_(s32) = G_XOR %0, %1
85 liveins: $sgpr0, $sgpr1
86 ; CHECK-LABEL: name: xor_i1_scc_scc
87 ; CHECK: liveins: $sgpr0, $sgpr1
89 ; CHECK-NEXT: [[COPY:%[0-9]+]]:sgpr(s32) = COPY $sgpr0
90 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:sgpr(s32) = COPY $sgpr1
91 ; CHECK-NEXT: [[C:%[0-9]+]]:sgpr(s32) = G_CONSTANT i32 0
92 ; CHECK-NEXT: [[ICMP:%[0-9]+]]:sgpr(s32) = G_ICMP intpred(ne), [[COPY]](s32), [[C]]
93 ; CHECK-NEXT: [[TRUNC:%[0-9]+]]:sgpr(s1) = G_TRUNC [[ICMP]](s32)
94 ; CHECK-NEXT: [[ICMP1:%[0-9]+]]:sgpr(s32) = G_ICMP intpred(ne), [[COPY1]](s32), [[C]]
95 ; CHECK-NEXT: [[TRUNC1:%[0-9]+]]:sgpr(s1) = G_TRUNC [[ICMP1]](s32)
96 ; CHECK-NEXT: [[ANYEXT:%[0-9]+]]:sgpr(s32) = G_ANYEXT [[TRUNC]](s1)
97 ; CHECK-NEXT: [[ANYEXT1:%[0-9]+]]:sgpr(s32) = G_ANYEXT [[TRUNC1]](s1)
98 ; CHECK-NEXT: [[XOR:%[0-9]+]]:sgpr(s32) = G_XOR [[ANYEXT]], [[ANYEXT1]]
99 ; CHECK-NEXT: [[TRUNC2:%[0-9]+]]:sgpr(s1) = G_TRUNC [[XOR]](s32)
100 ; CHECK-NEXT: S_NOP 0, implicit [[TRUNC2]](s1)
101 %0:_(s32) = COPY $sgpr0
102 %1:_(s32) = COPY $sgpr1
103 %2:_(s32) = G_CONSTANT i32 0
104 %4:_(s1) = G_ICMP intpred(ne), %0, %2
105 %5:_(s1) = G_ICMP intpred(ne), %1, %2
106 %6:_(s1) = G_XOR %4, %5
116 liveins: $vgpr0, $vgpr1
117 ; CHECK-LABEL: name: xor_i1_vcc_vcc
118 ; CHECK: liveins: $vgpr0, $vgpr1
120 ; CHECK-NEXT: [[COPY:%[0-9]+]]:vgpr(s32) = COPY $vgpr0
121 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:vgpr(s32) = COPY $vgpr1
122 ; CHECK-NEXT: [[C:%[0-9]+]]:sgpr(s32) = G_CONSTANT i32 0
123 ; CHECK-NEXT: [[COPY2:%[0-9]+]]:vgpr(s32) = COPY [[C]](s32)
124 ; CHECK-NEXT: [[ICMP:%[0-9]+]]:vcc(s1) = G_ICMP intpred(ne), [[COPY]](s32), [[COPY2]]
125 ; CHECK-NEXT: [[COPY3:%[0-9]+]]:vgpr(s32) = COPY [[C]](s32)
126 ; CHECK-NEXT: [[ICMP1:%[0-9]+]]:vcc(s1) = G_ICMP intpred(ne), [[COPY1]](s32), [[COPY3]]
127 ; CHECK-NEXT: [[XOR:%[0-9]+]]:vcc(s1) = G_XOR [[ICMP]], [[ICMP1]]
128 ; CHECK-NEXT: S_NOP 0, implicit [[XOR]](s1)
129 %0:_(s32) = COPY $vgpr0
130 %1:_(s32) = COPY $vgpr1
131 %2:_(s32) = G_CONSTANT i32 0
132 %4:_(s1) = G_ICMP intpred(ne), %0, %2
133 %5:_(s1) = G_ICMP intpred(ne), %1, %2
134 %6:_(s1) = G_XOR %4, %5
144 liveins: $sgpr0, $vgpr0
145 ; CHECK-LABEL: name: xor_i1_scc_vcc
146 ; CHECK: liveins: $sgpr0, $vgpr0
148 ; CHECK-NEXT: [[COPY:%[0-9]+]]:sgpr(s32) = COPY $sgpr0
149 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:vgpr(s32) = COPY $vgpr0
150 ; CHECK-NEXT: [[C:%[0-9]+]]:sgpr(s32) = G_CONSTANT i32 0
151 ; CHECK-NEXT: [[ICMP:%[0-9]+]]:sgpr(s32) = G_ICMP intpred(ne), [[COPY]](s32), [[C]]
152 ; CHECK-NEXT: [[TRUNC:%[0-9]+]]:sgpr(s1) = G_TRUNC [[ICMP]](s32)
153 ; CHECK-NEXT: [[COPY2:%[0-9]+]]:vgpr(s32) = COPY [[C]](s32)
154 ; CHECK-NEXT: [[ICMP1:%[0-9]+]]:vcc(s1) = G_ICMP intpred(ne), [[COPY1]](s32), [[COPY2]]
155 ; CHECK-NEXT: [[COPY3:%[0-9]+]]:vcc(s1) = COPY [[TRUNC]](s1)
156 ; CHECK-NEXT: [[XOR:%[0-9]+]]:vcc(s1) = G_XOR [[COPY3]], [[ICMP1]]
157 ; CHECK-NEXT: S_NOP 0, implicit [[XOR]](s1)
158 %0:_(s32) = COPY $sgpr0
159 %1:_(s32) = COPY $vgpr0
160 %2:_(s32) = G_CONSTANT i32 0
161 %4:_(s1) = G_ICMP intpred(ne), %0, %2
162 %5:_(s1) = G_ICMP intpred(ne), %1, %2
163 %6:_(s1) = G_XOR %4, %5
168 name: xor_i1_sgpr_trunc_sgpr_trunc
172 liveins: $sgpr0, $sgpr1
173 ; CHECK-LABEL: name: xor_i1_sgpr_trunc_sgpr_trunc
174 ; CHECK: liveins: $sgpr0, $sgpr1
176 ; CHECK-NEXT: [[COPY:%[0-9]+]]:sgpr(s32) = COPY $sgpr0
177 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:sgpr(s32) = COPY $sgpr1
178 ; CHECK-NEXT: [[TRUNC:%[0-9]+]]:sgpr(s1) = G_TRUNC [[COPY]](s32)
179 ; CHECK-NEXT: [[TRUNC1:%[0-9]+]]:sgpr(s1) = G_TRUNC [[COPY1]](s32)
180 ; CHECK-NEXT: [[ANYEXT:%[0-9]+]]:sgpr(s32) = G_ANYEXT [[TRUNC]](s1)
181 ; CHECK-NEXT: [[ANYEXT1:%[0-9]+]]:sgpr(s32) = G_ANYEXT [[TRUNC1]](s1)
182 ; CHECK-NEXT: [[XOR:%[0-9]+]]:sgpr(s32) = G_XOR [[ANYEXT]], [[ANYEXT1]]
183 ; CHECK-NEXT: [[TRUNC2:%[0-9]+]]:sgpr(s1) = G_TRUNC [[XOR]](s32)
184 ; CHECK-NEXT: S_NOP 0, implicit [[TRUNC2]](s1)
185 %0:_(s32) = COPY $sgpr0
186 %1:_(s32) = COPY $sgpr1
187 %2:_(s1) = G_TRUNC %0
188 %3:_(s1) = G_TRUNC %1
189 %4:_(s1) = G_XOR %2, %3
195 name: xor_i1_trunc_scc
199 liveins: $sgpr0, $sgpr1
200 ; CHECK-LABEL: name: xor_i1_trunc_scc
201 ; CHECK: liveins: $sgpr0, $sgpr1
203 ; CHECK-NEXT: [[COPY:%[0-9]+]]:sgpr(s32) = COPY $sgpr0
204 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:sgpr(s32) = COPY $sgpr1
205 ; CHECK-NEXT: [[TRUNC:%[0-9]+]]:sgpr(s1) = G_TRUNC [[COPY]](s32)
206 ; CHECK-NEXT: [[ICMP:%[0-9]+]]:sgpr(s32) = G_ICMP intpred(ne), [[COPY]](s32), [[COPY1]]
207 ; CHECK-NEXT: [[TRUNC1:%[0-9]+]]:sgpr(s1) = G_TRUNC [[ICMP]](s32)
208 ; CHECK-NEXT: [[ANYEXT:%[0-9]+]]:sgpr(s32) = G_ANYEXT [[TRUNC]](s1)
209 ; CHECK-NEXT: [[ANYEXT1:%[0-9]+]]:sgpr(s32) = G_ANYEXT [[TRUNC1]](s1)
210 ; CHECK-NEXT: [[XOR:%[0-9]+]]:sgpr(s32) = G_XOR [[ANYEXT]], [[ANYEXT1]]
211 ; CHECK-NEXT: [[TRUNC2:%[0-9]+]]:sgpr(s1) = G_TRUNC [[XOR]](s32)
212 ; CHECK-NEXT: S_NOP 0, implicit [[TRUNC2]](s1)
213 %0:_(s32) = COPY $sgpr0
214 %1:_(s32) = COPY $sgpr1
215 %2:_(s1) = G_TRUNC %0
216 %3:_(s1) = G_ICMP intpred(ne), %0, %1
217 %4:_(s1) = G_XOR %2, %3
222 name: xor_i1_s_trunc_vcc
226 liveins: $sgpr0, $vgpr0
227 ; CHECK-LABEL: name: xor_i1_s_trunc_vcc
228 ; CHECK: liveins: $sgpr0, $vgpr0
230 ; CHECK-NEXT: [[COPY:%[0-9]+]]:sgpr(s32) = COPY $sgpr0
231 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:vgpr(s32) = COPY $vgpr0
232 ; CHECK-NEXT: [[TRUNC:%[0-9]+]]:sgpr(s1) = G_TRUNC [[COPY]](s32)
233 ; CHECK-NEXT: [[COPY2:%[0-9]+]]:vgpr(s32) = COPY [[COPY]](s32)
234 ; CHECK-NEXT: [[ICMP:%[0-9]+]]:vcc(s1) = G_ICMP intpred(ne), [[COPY2]](s32), [[COPY1]]
235 ; CHECK-NEXT: [[COPY3:%[0-9]+]]:vcc(s1) = COPY [[TRUNC]](s1)
236 ; CHECK-NEXT: [[XOR:%[0-9]+]]:vcc(s1) = G_XOR [[COPY3]], [[ICMP]]
237 ; CHECK-NEXT: S_NOP 0, implicit [[XOR]](s1)
238 %0:_(s32) = COPY $sgpr0
239 %1:_(s32) = COPY $vgpr0
240 %2:_(s1) = G_TRUNC %0
241 %3:_(s1) = G_ICMP intpred(ne), %0, %1
242 %4:_(s1) = G_XOR %2, %3
252 liveins: $sgpr0_sgpr1, $sgpr2_sgpr3
253 ; CHECK-LABEL: name: xor_s64_ss
254 ; CHECK: liveins: $sgpr0_sgpr1, $sgpr2_sgpr3
256 ; CHECK-NEXT: [[COPY:%[0-9]+]]:sgpr(s64) = COPY $sgpr0_sgpr1
257 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:sgpr(s64) = COPY $sgpr2_sgpr3
258 ; CHECK-NEXT: [[XOR:%[0-9]+]]:sgpr(s64) = G_XOR [[COPY]], [[COPY1]]
259 %0:_(s64) = COPY $sgpr0_sgpr1
260 %1:_(s64) = COPY $sgpr2_sgpr3
261 %2:_(s64) = G_XOR %0, %1
270 liveins: $sgpr0_sgpr1, $vgpr0_vgpr1
271 ; CHECK-LABEL: name: xor_s64_sv
272 ; CHECK: liveins: $sgpr0_sgpr1, $vgpr0_vgpr1
274 ; CHECK-NEXT: [[COPY:%[0-9]+]]:sgpr(s64) = COPY $sgpr0_sgpr1
275 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:vgpr(s64) = COPY $vgpr0_vgpr1
276 ; CHECK-NEXT: [[UV:%[0-9]+]]:sgpr(s32), [[UV1:%[0-9]+]]:sgpr(s32) = G_UNMERGE_VALUES [[COPY]](s64)
277 ; CHECK-NEXT: [[UV2:%[0-9]+]]:vgpr(s32), [[UV3:%[0-9]+]]:vgpr(s32) = G_UNMERGE_VALUES [[COPY1]](s64)
278 ; CHECK-NEXT: [[XOR:%[0-9]+]]:vgpr(s32) = G_XOR [[UV]], [[UV2]]
279 ; CHECK-NEXT: [[XOR1:%[0-9]+]]:vgpr(s32) = G_XOR [[UV1]], [[UV3]]
280 ; CHECK-NEXT: [[MV:%[0-9]+]]:vgpr(s64) = G_MERGE_VALUES [[XOR]](s32), [[XOR1]](s32)
281 %0:_(s64) = COPY $sgpr0_sgpr1
282 %1:_(s64) = COPY $vgpr0_vgpr1
283 %2:_(s64) = G_XOR %0, %1
292 liveins: $sgpr0_sgpr1, $vgpr0_vgpr1
293 ; CHECK-LABEL: name: xor_s64_vs
294 ; CHECK: liveins: $sgpr0_sgpr1, $vgpr0_vgpr1
296 ; CHECK-NEXT: [[COPY:%[0-9]+]]:vgpr(s64) = COPY $vgpr0_vgpr1
297 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:sgpr(s64) = COPY $sgpr0_sgpr1
298 ; CHECK-NEXT: [[UV:%[0-9]+]]:vgpr(s32), [[UV1:%[0-9]+]]:vgpr(s32) = G_UNMERGE_VALUES [[COPY]](s64)
299 ; CHECK-NEXT: [[UV2:%[0-9]+]]:sgpr(s32), [[UV3:%[0-9]+]]:sgpr(s32) = G_UNMERGE_VALUES [[COPY1]](s64)
300 ; CHECK-NEXT: [[XOR:%[0-9]+]]:vgpr(s32) = G_XOR [[UV]], [[UV2]]
301 ; CHECK-NEXT: [[XOR1:%[0-9]+]]:vgpr(s32) = G_XOR [[UV1]], [[UV3]]
302 ; CHECK-NEXT: [[MV:%[0-9]+]]:vgpr(s64) = G_MERGE_VALUES [[XOR]](s32), [[XOR1]](s32)
303 %0:_(s64) = COPY $vgpr0_vgpr1
304 %1:_(s64) = COPY $sgpr0_sgpr1
305 %2:_(s64) = G_XOR %0, %1
314 liveins: $vgpr0_vgpr1, $vgpr2_vgpr3
315 ; CHECK-LABEL: name: xor_s64_vv
316 ; CHECK: liveins: $vgpr0_vgpr1, $vgpr2_vgpr3
318 ; CHECK-NEXT: [[COPY:%[0-9]+]]:vgpr(s64) = COPY $vgpr0_vgpr1
319 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:vgpr(s64) = COPY $vgpr2_vgpr3
320 ; CHECK-NEXT: [[UV:%[0-9]+]]:vgpr(s32), [[UV1:%[0-9]+]]:vgpr(s32) = G_UNMERGE_VALUES [[COPY]](s64)
321 ; CHECK-NEXT: [[UV2:%[0-9]+]]:vgpr(s32), [[UV3:%[0-9]+]]:vgpr(s32) = G_UNMERGE_VALUES [[COPY1]](s64)
322 ; CHECK-NEXT: [[XOR:%[0-9]+]]:vgpr(s32) = G_XOR [[UV]], [[UV2]]
323 ; CHECK-NEXT: [[XOR1:%[0-9]+]]:vgpr(s32) = G_XOR [[UV1]], [[UV3]]
324 ; CHECK-NEXT: [[MV:%[0-9]+]]:vgpr(s64) = G_MERGE_VALUES [[XOR]](s32), [[XOR1]](s32)
325 %0:_(s64) = COPY $vgpr0_vgpr1
326 %1:_(s64) = COPY $vgpr2_vgpr3
327 %2:_(s64) = G_XOR %0, %1
331 name: xor_s64_vv_user
336 liveins: $vgpr0_vgpr1, $vgpr2_vgpr3
337 ; CHECK-LABEL: name: xor_s64_vv_user
338 ; CHECK: liveins: $vgpr0_vgpr1, $vgpr2_vgpr3
340 ; CHECK-NEXT: [[COPY:%[0-9]+]]:vgpr(s64) = COPY $vgpr0_vgpr1
341 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:vgpr(s64) = COPY $vgpr2_vgpr3
342 ; CHECK-NEXT: [[UV:%[0-9]+]]:vgpr(s32), [[UV1:%[0-9]+]]:vgpr(s32) = G_UNMERGE_VALUES [[COPY]](s64)
343 ; CHECK-NEXT: [[UV2:%[0-9]+]]:vgpr(s32), [[UV3:%[0-9]+]]:vgpr(s32) = G_UNMERGE_VALUES [[COPY1]](s64)
344 ; CHECK-NEXT: [[XOR:%[0-9]+]]:vgpr(s32) = G_XOR [[UV]], [[UV2]]
345 ; CHECK-NEXT: [[XOR1:%[0-9]+]]:vgpr(s32) = G_XOR [[UV1]], [[UV3]]
346 ; CHECK-NEXT: [[MV:%[0-9]+]]:vgpr(s64) = G_MERGE_VALUES [[XOR]](s32), [[XOR1]](s32)
347 ; CHECK-NEXT: S_NOP 0, implicit [[MV]](s64)
348 %0:_(s64) = COPY $vgpr0_vgpr1
349 %1:_(s64) = COPY $vgpr2_vgpr3
350 %2:_(s64) = G_XOR %0, %1
354 name: xor_s64_ss_ss_merge
359 liveins: $sgpr0, $sgpr1, $sgpr2, $sgpr3
360 ; CHECK-LABEL: name: xor_s64_ss_ss_merge
361 ; CHECK: liveins: $sgpr0, $sgpr1, $sgpr2, $sgpr3
363 ; CHECK-NEXT: [[COPY:%[0-9]+]]:sgpr(s32) = COPY $sgpr0
364 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:sgpr(s32) = COPY $sgpr1
365 ; CHECK-NEXT: [[COPY2:%[0-9]+]]:sgpr(s32) = COPY $sgpr2
366 ; CHECK-NEXT: [[COPY3:%[0-9]+]]:sgpr(s32) = COPY $sgpr3
367 ; CHECK-NEXT: [[MV:%[0-9]+]]:sgpr(s64) = G_MERGE_VALUES [[COPY]](s32), [[COPY1]](s32)
368 ; CHECK-NEXT: [[MV1:%[0-9]+]]:sgpr(s64) = G_MERGE_VALUES [[COPY2]](s32), [[COPY3]](s32)
369 ; CHECK-NEXT: [[XOR:%[0-9]+]]:sgpr(s64) = G_XOR [[MV]], [[MV1]]
370 ; CHECK-NEXT: S_NOP 0, implicit [[XOR]](s64)
371 %0:_(s32) = COPY $sgpr0
372 %1:_(s32) = COPY $sgpr1
373 %2:_(s32) = COPY $sgpr2
374 %3:_(s32) = COPY $sgpr3
375 %4:_(s64) = G_MERGE_VALUES %0, %1
376 %5:_(s64) = G_MERGE_VALUES %2, %3
377 %6:_(s64) = G_XOR %4, %5
382 name: xor_s64_vv_vv_merge
387 liveins: $vgpr0, $vgpr1, $vgpr2, $vgpr3
388 ; CHECK-LABEL: name: xor_s64_vv_vv_merge
389 ; CHECK: liveins: $vgpr0, $vgpr1, $vgpr2, $vgpr3
391 ; CHECK-NEXT: [[COPY:%[0-9]+]]:vgpr(s32) = COPY $vgpr0
392 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:vgpr(s32) = COPY $vgpr1
393 ; CHECK-NEXT: [[COPY2:%[0-9]+]]:vgpr(s32) = COPY $vgpr2
394 ; CHECK-NEXT: [[COPY3:%[0-9]+]]:vgpr(s32) = COPY $vgpr3
395 ; CHECK-NEXT: [[MV:%[0-9]+]]:vgpr(s64) = G_MERGE_VALUES [[COPY]](s32), [[COPY1]](s32)
396 ; CHECK-NEXT: [[MV1:%[0-9]+]]:vgpr(s64) = G_MERGE_VALUES [[COPY2]](s32), [[COPY3]](s32)
397 ; CHECK-NEXT: [[UV:%[0-9]+]]:vgpr(s32), [[UV1:%[0-9]+]]:vgpr(s32) = G_UNMERGE_VALUES [[MV]](s64)
398 ; CHECK-NEXT: [[UV2:%[0-9]+]]:vgpr(s32), [[UV3:%[0-9]+]]:vgpr(s32) = G_UNMERGE_VALUES [[MV1]](s64)
399 ; CHECK-NEXT: [[XOR:%[0-9]+]]:vgpr(s32) = G_XOR [[UV]], [[UV2]]
400 ; CHECK-NEXT: [[XOR1:%[0-9]+]]:vgpr(s32) = G_XOR [[UV1]], [[UV3]]
401 ; CHECK-NEXT: [[MV2:%[0-9]+]]:vgpr(s64) = G_MERGE_VALUES [[XOR]](s32), [[XOR1]](s32)
402 ; CHECK-NEXT: S_NOP 0, implicit [[MV2]](s64)
403 %0:_(s32) = COPY $vgpr0
404 %1:_(s32) = COPY $vgpr1
405 %2:_(s32) = COPY $vgpr2
406 %3:_(s32) = COPY $vgpr3
407 %4:_(s64) = G_MERGE_VALUES %0, %1
408 %5:_(s64) = G_MERGE_VALUES %2, %3
409 %6:_(s64) = G_XOR %4, %5
414 name: xor_s64_s_sv_merge
419 liveins: $sgpr0_sgpr1, $sgpr2, $vgpr0
420 ; CHECK-LABEL: name: xor_s64_s_sv_merge
421 ; CHECK: liveins: $sgpr0_sgpr1, $sgpr2, $vgpr0
423 ; CHECK-NEXT: [[COPY:%[0-9]+]]:sgpr(s64) = COPY $sgpr0_sgpr1
424 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:sgpr(s32) = COPY $sgpr2
425 ; CHECK-NEXT: [[COPY2:%[0-9]+]]:vgpr(s32) = COPY $vgpr0
426 ; CHECK-NEXT: [[COPY3:%[0-9]+]]:vgpr(s32) = COPY [[COPY1]](s32)
427 ; CHECK-NEXT: [[MV:%[0-9]+]]:vgpr(s64) = G_MERGE_VALUES [[COPY3]](s32), [[COPY2]](s32)
428 ; CHECK-NEXT: [[UV:%[0-9]+]]:sgpr(s32), [[UV1:%[0-9]+]]:sgpr(s32) = G_UNMERGE_VALUES [[COPY]](s64)
429 ; CHECK-NEXT: [[UV2:%[0-9]+]]:vgpr(s32), [[UV3:%[0-9]+]]:vgpr(s32) = G_UNMERGE_VALUES [[MV]](s64)
430 ; CHECK-NEXT: [[XOR:%[0-9]+]]:vgpr(s32) = G_XOR [[UV]], [[UV2]]
431 ; CHECK-NEXT: [[XOR1:%[0-9]+]]:vgpr(s32) = G_XOR [[UV1]], [[UV3]]
432 ; CHECK-NEXT: [[MV1:%[0-9]+]]:vgpr(s64) = G_MERGE_VALUES [[XOR]](s32), [[XOR1]](s32)
433 ; CHECK-NEXT: S_NOP 0, implicit [[MV1]](s64)
434 %0:_(s64) = COPY $sgpr0_sgpr1
435 %1:_(s32) = COPY $sgpr2
436 %2:_(s32) = COPY $vgpr0
437 %3:_(s64) = G_MERGE_VALUES %1, %2
438 %4:_(s64) = G_XOR %0, %3
443 name: xor_s64_s_vs_merge
448 liveins: $sgpr0_sgpr1, $sgpr2, $vgpr0
449 ; CHECK-LABEL: name: xor_s64_s_vs_merge
450 ; CHECK: liveins: $sgpr0_sgpr1, $sgpr2, $vgpr0
452 ; CHECK-NEXT: [[COPY:%[0-9]+]]:sgpr(s64) = COPY $sgpr0_sgpr1
453 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:sgpr(s32) = COPY $sgpr2
454 ; CHECK-NEXT: [[COPY2:%[0-9]+]]:vgpr(s32) = COPY $vgpr0
455 ; CHECK-NEXT: [[COPY3:%[0-9]+]]:vgpr(s32) = COPY [[COPY1]](s32)
456 ; CHECK-NEXT: [[MV:%[0-9]+]]:vgpr(s64) = G_MERGE_VALUES [[COPY2]](s32), [[COPY3]](s32)
457 ; CHECK-NEXT: [[UV:%[0-9]+]]:sgpr(s32), [[UV1:%[0-9]+]]:sgpr(s32) = G_UNMERGE_VALUES [[COPY]](s64)
458 ; CHECK-NEXT: [[UV2:%[0-9]+]]:vgpr(s32), [[UV3:%[0-9]+]]:vgpr(s32) = G_UNMERGE_VALUES [[MV]](s64)
459 ; CHECK-NEXT: [[XOR:%[0-9]+]]:vgpr(s32) = G_XOR [[UV]], [[UV2]]
460 ; CHECK-NEXT: [[XOR1:%[0-9]+]]:vgpr(s32) = G_XOR [[UV1]], [[UV3]]
461 ; CHECK-NEXT: [[MV1:%[0-9]+]]:vgpr(s64) = G_MERGE_VALUES [[XOR]](s32), [[XOR1]](s32)
462 ; CHECK-NEXT: S_NOP 0, implicit [[MV1]](s64)
463 %0:_(s64) = COPY $sgpr0_sgpr1
464 %1:_(s32) = COPY $sgpr2
465 %2:_(s32) = COPY $vgpr0
466 %3:_(s64) = G_MERGE_VALUES %2, %1
467 %4:_(s64) = G_XOR %0, %3
472 name: xor_s64_sv_sv_merge
477 liveins: $sgpr0, $sgpr1, $vgpr0, $vgpr1
478 ; CHECK-LABEL: name: xor_s64_sv_sv_merge
479 ; CHECK: liveins: $sgpr0, $sgpr1, $vgpr0, $vgpr1
481 ; CHECK-NEXT: [[COPY:%[0-9]+]]:sgpr(s32) = COPY $sgpr0
482 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:sgpr(s32) = COPY $sgpr1
483 ; CHECK-NEXT: [[COPY2:%[0-9]+]]:vgpr(s32) = COPY $vgpr0
484 ; CHECK-NEXT: [[COPY3:%[0-9]+]]:vgpr(s32) = COPY $vgpr1
485 ; CHECK-NEXT: [[COPY4:%[0-9]+]]:vgpr(s32) = COPY [[COPY]](s32)
486 ; CHECK-NEXT: [[MV:%[0-9]+]]:vgpr(s64) = G_MERGE_VALUES [[COPY4]](s32), [[COPY2]](s32)
487 ; CHECK-NEXT: [[COPY5:%[0-9]+]]:vgpr(s32) = COPY [[COPY1]](s32)
488 ; CHECK-NEXT: [[MV1:%[0-9]+]]:vgpr(s64) = G_MERGE_VALUES [[COPY5]](s32), [[COPY3]](s32)
489 ; CHECK-NEXT: [[UV:%[0-9]+]]:vgpr(s32), [[UV1:%[0-9]+]]:vgpr(s32) = G_UNMERGE_VALUES [[MV]](s64)
490 ; CHECK-NEXT: [[UV2:%[0-9]+]]:vgpr(s32), [[UV3:%[0-9]+]]:vgpr(s32) = G_UNMERGE_VALUES [[MV1]](s64)
491 ; CHECK-NEXT: [[XOR:%[0-9]+]]:vgpr(s32) = G_XOR [[UV]], [[UV2]]
492 ; CHECK-NEXT: [[XOR1:%[0-9]+]]:vgpr(s32) = G_XOR [[UV1]], [[UV3]]
493 ; CHECK-NEXT: [[MV2:%[0-9]+]]:vgpr(s64) = G_MERGE_VALUES [[XOR]](s32), [[XOR1]](s32)
494 ; CHECK-NEXT: S_NOP 0, implicit [[MV2]](s64)
495 %0:_(s32) = COPY $sgpr0
496 %1:_(s32) = COPY $sgpr1
497 %2:_(s32) = COPY $vgpr0
498 %3:_(s32) = COPY $vgpr1
499 %4:_(s64) = G_MERGE_VALUES %0, %2
500 %5:_(s64) = G_MERGE_VALUES %1, %3
501 %6:_(s64) = G_XOR %4, %5
506 name: xor_s64_sv_vs_merge
511 liveins: $sgpr0, $sgpr1, $vgpr0, $vgpr1
512 ; CHECK-LABEL: name: xor_s64_sv_vs_merge
513 ; CHECK: liveins: $sgpr0, $sgpr1, $vgpr0, $vgpr1
515 ; CHECK-NEXT: [[COPY:%[0-9]+]]:sgpr(s32) = COPY $sgpr0
516 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:sgpr(s32) = COPY $sgpr1
517 ; CHECK-NEXT: [[COPY2:%[0-9]+]]:vgpr(s32) = COPY $vgpr0
518 ; CHECK-NEXT: [[COPY3:%[0-9]+]]:vgpr(s32) = COPY $vgpr1
519 ; CHECK-NEXT: [[COPY4:%[0-9]+]]:vgpr(s32) = COPY [[COPY]](s32)
520 ; CHECK-NEXT: [[MV:%[0-9]+]]:vgpr(s64) = G_MERGE_VALUES [[COPY4]](s32), [[COPY2]](s32)
521 ; CHECK-NEXT: [[COPY5:%[0-9]+]]:vgpr(s32) = COPY [[COPY1]](s32)
522 ; CHECK-NEXT: [[MV1:%[0-9]+]]:vgpr(s64) = G_MERGE_VALUES [[COPY3]](s32), [[COPY5]](s32)
523 ; CHECK-NEXT: [[UV:%[0-9]+]]:vgpr(s32), [[UV1:%[0-9]+]]:vgpr(s32) = G_UNMERGE_VALUES [[MV]](s64)
524 ; CHECK-NEXT: [[UV2:%[0-9]+]]:vgpr(s32), [[UV3:%[0-9]+]]:vgpr(s32) = G_UNMERGE_VALUES [[MV1]](s64)
525 ; CHECK-NEXT: [[XOR:%[0-9]+]]:vgpr(s32) = G_XOR [[UV]], [[UV2]]
526 ; CHECK-NEXT: [[XOR1:%[0-9]+]]:vgpr(s32) = G_XOR [[UV1]], [[UV3]]
527 ; CHECK-NEXT: [[MV2:%[0-9]+]]:vgpr(s64) = G_MERGE_VALUES [[XOR]](s32), [[XOR1]](s32)
528 ; CHECK-NEXT: S_NOP 0, implicit [[MV2]](s64)
529 %0:_(s32) = COPY $sgpr0
530 %1:_(s32) = COPY $sgpr1
531 %2:_(s32) = COPY $vgpr0
532 %3:_(s32) = COPY $vgpr1
533 %4:_(s64) = G_MERGE_VALUES %0, %2
534 %5:_(s64) = G_MERGE_VALUES %3, %1
535 %6:_(s64) = G_XOR %4, %5
540 name: xor_chain_s64_sv
545 liveins: $sgpr0_sgpr1, $sgpr2_sgpr3, $vgpr0_vgpr1
546 ; CHECK-LABEL: name: xor_chain_s64_sv
547 ; CHECK: liveins: $sgpr0_sgpr1, $sgpr2_sgpr3, $vgpr0_vgpr1
549 ; CHECK-NEXT: [[COPY:%[0-9]+]]:sgpr(s64) = COPY $sgpr0_sgpr1
550 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:sgpr(s64) = COPY $sgpr2_sgpr3
551 ; CHECK-NEXT: [[COPY2:%[0-9]+]]:vgpr(s64) = COPY $vgpr0_vgpr1
552 ; CHECK-NEXT: [[UV:%[0-9]+]]:sgpr(s32), [[UV1:%[0-9]+]]:sgpr(s32) = G_UNMERGE_VALUES [[COPY]](s64)
553 ; CHECK-NEXT: [[UV2:%[0-9]+]]:vgpr(s32), [[UV3:%[0-9]+]]:vgpr(s32) = G_UNMERGE_VALUES [[COPY2]](s64)
554 ; CHECK-NEXT: [[XOR:%[0-9]+]]:vgpr(s32) = G_XOR [[UV]], [[UV2]]
555 ; CHECK-NEXT: [[XOR1:%[0-9]+]]:vgpr(s32) = G_XOR [[UV1]], [[UV3]]
556 ; CHECK-NEXT: [[MV:%[0-9]+]]:vgpr(s64) = G_MERGE_VALUES [[XOR]](s32), [[XOR1]](s32)
557 ; CHECK-NEXT: [[UV4:%[0-9]+]]:sgpr(s32), [[UV5:%[0-9]+]]:sgpr(s32) = G_UNMERGE_VALUES [[COPY1]](s64)
558 ; CHECK-NEXT: [[UV6:%[0-9]+]]:vgpr(s32), [[UV7:%[0-9]+]]:vgpr(s32) = G_UNMERGE_VALUES [[MV]](s64)
559 ; CHECK-NEXT: [[XOR2:%[0-9]+]]:vgpr(s32) = G_XOR [[UV4]], [[UV6]]
560 ; CHECK-NEXT: [[XOR3:%[0-9]+]]:vgpr(s32) = G_XOR [[UV5]], [[UV7]]
561 ; CHECK-NEXT: [[MV1:%[0-9]+]]:vgpr(s64) = G_MERGE_VALUES [[XOR2]](s32), [[XOR3]](s32)
562 ; CHECK-NEXT: S_NOP 0, implicit [[MV1]](s64)
563 %0:_(s64) = COPY $sgpr0_sgpr1
564 %1:_(s64) = COPY $sgpr2_sgpr3
565 %2:_(s64) = COPY $vgpr0_vgpr1
566 %3:_(s64) = G_XOR %0, %2
567 %4:_(s64) = G_XOR %1, %3
577 liveins: $sgpr0_sgpr1, $sgpr2_sgpr3
578 ; CHECK-LABEL: name: xor_v2i32_ss
579 ; CHECK: liveins: $sgpr0_sgpr1, $sgpr2_sgpr3
581 ; CHECK-NEXT: [[COPY:%[0-9]+]]:sgpr(<2 x s32>) = COPY $sgpr0_sgpr1
582 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:sgpr(<2 x s32>) = COPY $sgpr2_sgpr3
583 ; CHECK-NEXT: [[XOR:%[0-9]+]]:sgpr(<2 x s32>) = G_XOR [[COPY]], [[COPY1]]
584 ; CHECK-NEXT: S_NOP 0, implicit [[XOR]](<2 x s32>)
585 %0:_(<2 x s32>) = COPY $sgpr0_sgpr1
586 %1:_(<2 x s32>) = COPY $sgpr2_sgpr3
587 %2:_(<2 x s32>) = G_XOR %0, %1
597 liveins: $sgpr0_sgpr1, $vgpr0_vgpr1
598 ; CHECK-LABEL: name: xor_v2i32_sv
599 ; CHECK: liveins: $sgpr0_sgpr1, $vgpr0_vgpr1
601 ; CHECK-NEXT: [[COPY:%[0-9]+]]:sgpr(<2 x s32>) = COPY $sgpr0_sgpr1
602 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:vgpr(<2 x s32>) = COPY $vgpr0_vgpr1
603 ; CHECK-NEXT: [[UV:%[0-9]+]]:sgpr(s32), [[UV1:%[0-9]+]]:sgpr(s32) = G_UNMERGE_VALUES [[COPY]](<2 x s32>)
604 ; CHECK-NEXT: [[UV2:%[0-9]+]]:vgpr(s32), [[UV3:%[0-9]+]]:vgpr(s32) = G_UNMERGE_VALUES [[COPY1]](<2 x s32>)
605 ; CHECK-NEXT: [[XOR:%[0-9]+]]:vgpr(s32) = G_XOR [[UV]], [[UV2]]
606 ; CHECK-NEXT: [[XOR1:%[0-9]+]]:vgpr(s32) = G_XOR [[UV1]], [[UV3]]
607 ; CHECK-NEXT: [[BUILD_VECTOR:%[0-9]+]]:vgpr(<2 x s32>) = G_BUILD_VECTOR [[XOR]](s32), [[XOR1]](s32)
608 ; CHECK-NEXT: S_NOP 0, implicit [[BUILD_VECTOR]](<2 x s32>)
609 %0:_(<2 x s32>) = COPY $sgpr0_sgpr1
610 %1:_(<2 x s32>) = COPY $vgpr0_vgpr1
611 %2:_(<2 x s32>) = G_XOR %0, %1
621 liveins: $sgpr0_sgpr1, $vgpr0_vgpr1
623 ; CHECK-LABEL: name: xor_v2i32_vs
624 ; CHECK: liveins: $sgpr0_sgpr1, $vgpr0_vgpr1
626 ; CHECK-NEXT: [[COPY:%[0-9]+]]:vgpr(<2 x s32>) = COPY $vgpr0_vgpr1
627 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:sgpr(<2 x s32>) = COPY $sgpr0_sgpr1
628 ; CHECK-NEXT: [[UV:%[0-9]+]]:vgpr(s32), [[UV1:%[0-9]+]]:vgpr(s32) = G_UNMERGE_VALUES [[COPY]](<2 x s32>)
629 ; CHECK-NEXT: [[UV2:%[0-9]+]]:sgpr(s32), [[UV3:%[0-9]+]]:sgpr(s32) = G_UNMERGE_VALUES [[COPY1]](<2 x s32>)
630 ; CHECK-NEXT: [[XOR:%[0-9]+]]:vgpr(s32) = G_XOR [[UV]], [[UV2]]
631 ; CHECK-NEXT: [[XOR1:%[0-9]+]]:vgpr(s32) = G_XOR [[UV1]], [[UV3]]
632 ; CHECK-NEXT: [[BUILD_VECTOR:%[0-9]+]]:vgpr(<2 x s32>) = G_BUILD_VECTOR [[XOR]](s32), [[XOR1]](s32)
633 ; CHECK-NEXT: S_NOP 0, implicit [[BUILD_VECTOR]](<2 x s32>)
634 %0:_(<2 x s32>) = COPY $vgpr0_vgpr1
635 %1:_(<2 x s32>) = COPY $sgpr0_sgpr1
636 %2:_(<2 x s32>) = G_XOR %0, %1
646 liveins: $vgpr0_vgpr1, $vgpr2_vgpr3
647 ; CHECK-LABEL: name: xor_v2i32_vv
648 ; CHECK: liveins: $vgpr0_vgpr1, $vgpr2_vgpr3
650 ; CHECK-NEXT: [[COPY:%[0-9]+]]:vgpr(<2 x s32>) = COPY $vgpr0_vgpr1
651 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:vgpr(<2 x s32>) = COPY $vgpr2_vgpr3
652 ; CHECK-NEXT: [[UV:%[0-9]+]]:vgpr(s32), [[UV1:%[0-9]+]]:vgpr(s32) = G_UNMERGE_VALUES [[COPY]](<2 x s32>)
653 ; CHECK-NEXT: [[UV2:%[0-9]+]]:vgpr(s32), [[UV3:%[0-9]+]]:vgpr(s32) = G_UNMERGE_VALUES [[COPY1]](<2 x s32>)
654 ; CHECK-NEXT: [[XOR:%[0-9]+]]:vgpr(s32) = G_XOR [[UV]], [[UV2]]
655 ; CHECK-NEXT: [[XOR1:%[0-9]+]]:vgpr(s32) = G_XOR [[UV1]], [[UV3]]
656 ; CHECK-NEXT: [[BUILD_VECTOR:%[0-9]+]]:vgpr(<2 x s32>) = G_BUILD_VECTOR [[XOR]](s32), [[XOR1]](s32)
657 ; CHECK-NEXT: S_NOP 0, implicit [[BUILD_VECTOR]](<2 x s32>)
658 %0:_(<2 x s32>) = COPY $vgpr0_vgpr1
659 %1:_(<2 x s32>) = COPY $vgpr2_vgpr3
660 %2:_(<2 x s32>) = G_XOR %0, %1
670 liveins: $sgpr0_sgpr1, $sgpr2_sgpr3
671 ; CHECK-LABEL: name: xor_v4s16_ss
672 ; CHECK: liveins: $sgpr0_sgpr1, $sgpr2_sgpr3
674 ; CHECK-NEXT: [[COPY:%[0-9]+]]:sgpr(<4 x s16>) = COPY $sgpr0_sgpr1
675 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:sgpr(<4 x s16>) = COPY $sgpr2_sgpr3
676 ; CHECK-NEXT: [[XOR:%[0-9]+]]:sgpr(<4 x s16>) = G_XOR [[COPY]], [[COPY1]]
677 %0:_(<4 x s16>) = COPY $sgpr0_sgpr1
678 %1:_(<4 x s16>) = COPY $sgpr2_sgpr3
679 %2:_(<4 x s16>) = G_XOR %0, %1
688 liveins: $sgpr0_sgpr1, $vgpr0_vgpr1
689 ; CHECK-LABEL: name: xor_v4s16_sv
690 ; CHECK: liveins: $sgpr0_sgpr1, $vgpr0_vgpr1
692 ; CHECK-NEXT: [[COPY:%[0-9]+]]:sgpr(<4 x s16>) = COPY $sgpr0_sgpr1
693 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:vgpr(<4 x s16>) = COPY $vgpr0_vgpr1
694 ; CHECK-NEXT: [[UV:%[0-9]+]]:sgpr(<2 x s16>), [[UV1:%[0-9]+]]:sgpr(<2 x s16>) = G_UNMERGE_VALUES [[COPY]](<4 x s16>)
695 ; CHECK-NEXT: [[UV2:%[0-9]+]]:vgpr(<2 x s16>), [[UV3:%[0-9]+]]:vgpr(<2 x s16>) = G_UNMERGE_VALUES [[COPY1]](<4 x s16>)
696 ; CHECK-NEXT: [[XOR:%[0-9]+]]:vgpr(<2 x s16>) = G_XOR [[UV]], [[UV2]]
697 ; CHECK-NEXT: [[XOR1:%[0-9]+]]:vgpr(<2 x s16>) = G_XOR [[UV1]], [[UV3]]
698 ; CHECK-NEXT: [[CONCAT_VECTORS:%[0-9]+]]:vgpr(<4 x s16>) = G_CONCAT_VECTORS [[XOR]](<2 x s16>), [[XOR1]](<2 x s16>)
699 %0:_(<4 x s16>) = COPY $sgpr0_sgpr1
700 %1:_(<4 x s16>) = COPY $vgpr0_vgpr1
701 %2:_(<4 x s16>) = G_XOR %0, %1
710 liveins: $sgpr0_sgpr1, $vgpr0_vgpr1
711 ; CHECK-LABEL: name: xor_v4s16_vs
712 ; CHECK: liveins: $sgpr0_sgpr1, $vgpr0_vgpr1
714 ; CHECK-NEXT: [[COPY:%[0-9]+]]:vgpr(<4 x s16>) = COPY $vgpr0_vgpr1
715 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:sgpr(<4 x s16>) = COPY $sgpr0_sgpr1
716 ; CHECK-NEXT: [[UV:%[0-9]+]]:vgpr(<2 x s16>), [[UV1:%[0-9]+]]:vgpr(<2 x s16>) = G_UNMERGE_VALUES [[COPY]](<4 x s16>)
717 ; CHECK-NEXT: [[UV2:%[0-9]+]]:sgpr(<2 x s16>), [[UV3:%[0-9]+]]:sgpr(<2 x s16>) = G_UNMERGE_VALUES [[COPY1]](<4 x s16>)
718 ; CHECK-NEXT: [[XOR:%[0-9]+]]:vgpr(<2 x s16>) = G_XOR [[UV]], [[UV2]]
719 ; CHECK-NEXT: [[XOR1:%[0-9]+]]:vgpr(<2 x s16>) = G_XOR [[UV1]], [[UV3]]
720 ; CHECK-NEXT: [[CONCAT_VECTORS:%[0-9]+]]:vgpr(<4 x s16>) = G_CONCAT_VECTORS [[XOR]](<2 x s16>), [[XOR1]](<2 x s16>)
721 %0:_(<4 x s16>) = COPY $vgpr0_vgpr1
722 %1:_(<4 x s16>) = COPY $sgpr0_sgpr1
723 %2:_(<4 x s16>) = G_XOR %0, %1
732 liveins: $vgpr0_vgpr1, $vgpr2_vgpr3
733 ; CHECK-LABEL: name: xor_v4s16_vv
734 ; CHECK: liveins: $vgpr0_vgpr1, $vgpr2_vgpr3
736 ; CHECK-NEXT: [[COPY:%[0-9]+]]:vgpr(<4 x s16>) = COPY $vgpr0_vgpr1
737 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:vgpr(<4 x s16>) = COPY $vgpr2_vgpr3
738 ; CHECK-NEXT: [[UV:%[0-9]+]]:vgpr(<2 x s16>), [[UV1:%[0-9]+]]:vgpr(<2 x s16>) = G_UNMERGE_VALUES [[COPY]](<4 x s16>)
739 ; CHECK-NEXT: [[UV2:%[0-9]+]]:vgpr(<2 x s16>), [[UV3:%[0-9]+]]:vgpr(<2 x s16>) = G_UNMERGE_VALUES [[COPY1]](<4 x s16>)
740 ; CHECK-NEXT: [[XOR:%[0-9]+]]:vgpr(<2 x s16>) = G_XOR [[UV]], [[UV2]]
741 ; CHECK-NEXT: [[XOR1:%[0-9]+]]:vgpr(<2 x s16>) = G_XOR [[UV1]], [[UV3]]
742 ; CHECK-NEXT: [[CONCAT_VECTORS:%[0-9]+]]:vgpr(<4 x s16>) = G_CONCAT_VECTORS [[XOR]](<2 x s16>), [[XOR1]](<2 x s16>)
743 %0:_(<4 x s16>) = COPY $vgpr0_vgpr1
744 %1:_(<4 x s16>) = COPY $vgpr2_vgpr3
745 %2:_(<4 x s16>) = G_XOR %0, %1
754 liveins: $sgpr0, $sgpr1
755 ; CHECK-LABEL: name: xor_v2s16_ss
756 ; CHECK: liveins: $sgpr0, $sgpr1
758 ; CHECK-NEXT: [[COPY:%[0-9]+]]:sgpr(<2 x s16>) = COPY $sgpr0
759 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:sgpr(<2 x s16>) = COPY $sgpr1
760 ; CHECK-NEXT: [[XOR:%[0-9]+]]:sgpr(<2 x s16>) = G_XOR [[COPY]], [[COPY1]]
761 %0:_(<2 x s16>) = COPY $sgpr0
762 %1:_(<2 x s16>) = COPY $sgpr1
763 %2:_(<2 x s16>) = G_XOR %0, %1
772 liveins: $sgpr0, $vgpr0
773 ; CHECK-LABEL: name: xor_v2s16_sv
774 ; CHECK: liveins: $sgpr0, $vgpr0
776 ; CHECK-NEXT: [[COPY:%[0-9]+]]:sgpr(<2 x s16>) = COPY $sgpr0
777 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:vgpr(<2 x s16>) = COPY $vgpr0
778 ; CHECK-NEXT: [[COPY2:%[0-9]+]]:vgpr(<2 x s16>) = COPY [[COPY]](<2 x s16>)
779 ; CHECK-NEXT: [[XOR:%[0-9]+]]:vgpr(<2 x s16>) = G_XOR [[COPY2]], [[COPY1]]
780 %0:_(<2 x s16>) = COPY $sgpr0
781 %1:_(<2 x s16>) = COPY $vgpr0
782 %2:_(<2 x s16>) = G_XOR %0, %1
791 liveins: $sgpr0, $vgpr0
792 ; CHECK-LABEL: name: xor_v2s16_vs
793 ; CHECK: liveins: $sgpr0, $vgpr0
795 ; CHECK-NEXT: [[COPY:%[0-9]+]]:vgpr(<2 x s16>) = COPY $vgpr0
796 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:sgpr(<2 x s16>) = COPY $sgpr0
797 ; CHECK-NEXT: [[COPY2:%[0-9]+]]:vgpr(<2 x s16>) = COPY [[COPY1]](<2 x s16>)
798 ; CHECK-NEXT: [[XOR:%[0-9]+]]:vgpr(<2 x s16>) = G_XOR [[COPY]], [[COPY2]]
799 %0:_(<2 x s16>) = COPY $vgpr0
800 %1:_(<2 x s16>) = COPY $sgpr0
801 %2:_(<2 x s16>) = G_XOR %0, %1
810 liveins: $vgpr0, $vgpr1
811 ; CHECK-LABEL: name: xor_v2s16_vv
812 ; CHECK: liveins: $vgpr0, $vgpr1
814 ; CHECK-NEXT: [[COPY:%[0-9]+]]:vgpr(<2 x s16>) = COPY $vgpr0
815 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:vgpr(<2 x s16>) = COPY $vgpr1
816 ; CHECK-NEXT: [[XOR:%[0-9]+]]:vgpr(<2 x s16>) = G_XOR [[COPY]], [[COPY1]]
817 %0:_(<2 x s16>) = COPY $vgpr0
818 %1:_(<2 x s16>) = COPY $vgpr1
819 %2:_(<2 x s16>) = G_XOR %0, %1
823 name: xor_i1_vcc_constant
828 liveins: $vgpr0, $vgpr1
829 ; CHECK-LABEL: name: xor_i1_vcc_constant
830 ; CHECK: liveins: $vgpr0, $vgpr1
832 ; CHECK-NEXT: [[COPY:%[0-9]+]]:vgpr(s32) = COPY $vgpr0
833 ; CHECK-NEXT: [[C:%[0-9]+]]:sgpr(s32) = G_CONSTANT i32 0
834 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:vgpr(s32) = COPY [[C]](s32)
835 ; CHECK-NEXT: [[ICMP:%[0-9]+]]:vcc(s1) = G_ICMP intpred(ne), [[COPY]](s32), [[COPY1]]
836 ; CHECK-NEXT: [[C1:%[0-9]+]]:sgpr(s32) = G_CONSTANT i32 1
837 ; CHECK-NEXT: [[TRUNC:%[0-9]+]]:sgpr(s1) = G_TRUNC [[C1]](s32)
838 ; CHECK-NEXT: [[COPY2:%[0-9]+]]:vcc(s1) = COPY [[TRUNC]](s1)
839 ; CHECK-NEXT: [[XOR:%[0-9]+]]:vcc(s1) = G_XOR [[ICMP]], [[COPY2]]
840 ; CHECK-NEXT: S_NOP 0, implicit [[XOR]](s1)
841 %0:_(s32) = COPY $vgpr0
842 %1:_(s32) = G_CONSTANT i32 0
843 %2:_(s1) = G_ICMP intpred(ne), %0, %1
844 %3:_(s1) = G_CONSTANT i1 true
845 %4:_(s1) = G_XOR %2, %3