1 # RUN: llc -mtriple arm-- -run-pass=legalizer %s -o - | FileCheck %s
2 # RUN: llc -mtriple thumb-- -mattr=+v6t2 -run-pass=legalizer %s -o - | FileCheck %s
4 define void @test_add_s8() { ret void }
5 define void @test_add_s16() { ret void }
6 define void @test_add_s32() { ret void }
8 define void @test_sub_s8() { ret void }
9 define void @test_sub_s16() { ret void }
10 define void @test_sub_s32() { ret void }
12 define void @test_mul_s8() { ret void }
13 define void @test_mul_s16() { ret void }
14 define void @test_mul_s32() { ret void }
16 define void @test_and_s8() { ret void }
17 define void @test_and_s16() { ret void }
18 define void @test_and_s32() { ret void }
19 define void @test_and_s64() { ret void }
21 define void @test_or_s8() { ret void }
22 define void @test_or_s16() { ret void }
23 define void @test_or_s32() { ret void }
24 define void @test_or_s64() { ret void }
26 define void @test_xor_s8() { ret void }
27 define void @test_xor_s16() { ret void }
28 define void @test_xor_s32() { ret void }
29 define void @test_xor_s64() { ret void }
31 define void @test_lshr_s32() { ret void }
32 define void @test_ashr_s32() { ret void }
33 define void @test_shl_s32() { ret void }
35 define void @test_shift_s8() { ret void }
36 define void @test_shift_s16() { ret void }
37 define void @test_shift_amount_s8() { ret void }
38 define void @test_shift_amount_s16() { ret void }
42 # CHECK-LABEL: name: test_add_s8
44 # CHECK: legalized: true
45 regBankSelected: false
47 tracksRegLiveness: true
60 %1(s8) = G_LOAD %0 :: (load (s8))
62 %3(s8) = G_LOAD %2 :: (load (s8))
64 ; G_ADD with s8 should widen
65 ; CHECK-NOT: {{%[0-9]+}}:_(s8) = G_ADD {{%[0-9]+, %[0-9]+}}
66 ; CHECK: {{%[0-9]+}}:_(s32) = G_ADD {{%[0-9]+, %[0-9]+}}
67 ; CHECK-NOT: {{%[0-9]+}}:_(s8) = G_ADD {{%[0-9]+, %[0-9]+}}
68 %5(s32) = G_SEXT %4(s8)
70 BX_RET 14, $noreg, implicit $r0
74 # CHECK-LABEL: name: test_add_s16
76 # CHECK: legalized: true
77 regBankSelected: false
79 tracksRegLiveness: true
92 %1(s16) = G_LOAD %0 :: (load (s16))
94 %3(s16) = G_LOAD %2 :: (load (s16))
95 %4(s16) = G_ADD %1, %3
96 ; G_ADD with s16 should widen
97 ; CHECK-NOT: {{%[0-9]+}}:_(s16) = G_ADD {{%[0-9]+, %[0-9]+}}
98 ; CHECK: {{%[0-9]+}}:_(s32) = G_ADD {{%[0-9]+, %[0-9]+}}
99 ; CHECK-NOT: {{%[0-9]+}}:_(s16) = G_ADD {{%[0-9]+, %[0-9]+}}
100 %5(s32) = G_SEXT %4(s16)
102 BX_RET 14, $noreg, implicit $r0
106 # CHECK-LABEL: name: test_add_s32
108 # CHECK: legalized: true
109 regBankSelected: false
111 tracksRegLiveness: true
113 - { id: 0, class: _ }
114 - { id: 1, class: _ }
115 - { id: 2, class: _ }
122 %2(s32) = G_ADD %0, %1
123 ; G_ADD with s32 is legal, so we should find it unchanged in the output
124 ; CHECK: {{%[0-9]+}}:_(s32) = G_ADD {{%[0-9]+, %[0-9]+}}
126 BX_RET 14, $noreg, implicit $r0
131 # CHECK-LABEL: name: test_sub_s8
133 # CHECK: legalized: true
134 regBankSelected: false
136 tracksRegLiveness: true
138 - { id: 0, class: _ }
139 - { id: 1, class: _ }
140 - { id: 2, class: _ }
141 - { id: 3, class: _ }
142 - { id: 4, class: _ }
143 - { id: 5, class: _ }
149 %1(s8) = G_LOAD %0 :: (load (s8))
151 %3(s8) = G_LOAD %2 :: (load (s8))
152 %4(s8) = G_SUB %1, %3
153 ; G_SUB with s8 should widen
154 ; CHECK-NOT: {{%[0-9]+}}:_(s8) = G_SUB {{%[0-9]+, %[0-9]+}}
155 ; CHECK: {{%[0-9]+}}:_(s32) = G_SUB {{%[0-9]+, %[0-9]+}}
156 ; CHECK-NOT: {{%[0-9]+}}:_(s8) = G_SUB {{%[0-9]+, %[0-9]+}}
157 %5(s32) = G_SEXT %4(s8)
159 BX_RET 14, $noreg, implicit $r0
163 # CHECK-LABEL: name: test_sub_s16
165 # CHECK: legalized: true
166 regBankSelected: false
168 tracksRegLiveness: true
170 - { id: 0, class: _ }
171 - { id: 1, class: _ }
172 - { id: 2, class: _ }
173 - { id: 3, class: _ }
174 - { id: 4, class: _ }
175 - { id: 5, class: _ }
181 %1(s16) = G_LOAD %0 :: (load (s16))
183 %3(s16) = G_LOAD %2 :: (load (s16))
184 %4(s16) = G_SUB %1, %3
185 ; G_SUB with s16 should widen
186 ; CHECK-NOT: {{%[0-9]+}}:_(s16) = G_SUB {{%[0-9]+, %[0-9]+}}
187 ; CHECK: {{%[0-9]+}}:_(s32) = G_SUB {{%[0-9]+, %[0-9]+}}
188 ; CHECK-NOT: {{%[0-9]+}}:_(s16) = G_SUB {{%[0-9]+, %[0-9]+}}
189 %5(s32) = G_SEXT %4(s16)
191 BX_RET 14, $noreg, implicit $r0
195 # CHECK-LABEL: name: test_sub_s32
197 # CHECK: legalized: true
198 regBankSelected: false
200 tracksRegLiveness: true
202 - { id: 0, class: _ }
203 - { id: 1, class: _ }
204 - { id: 2, class: _ }
211 %2(s32) = G_SUB %0, %1
212 ; G_SUB with s32 is legal, so we should find it unchanged in the output
213 ; CHECK: {{%[0-9]+}}:_(s32) = G_SUB {{%[0-9]+, %[0-9]+}}
215 BX_RET 14, $noreg, implicit $r0
220 # CHECK-LABEL: name: test_mul_s8
222 # CHECK: legalized: true
223 regBankSelected: false
225 tracksRegLiveness: true
227 - { id: 0, class: _ }
228 - { id: 1, class: _ }
229 - { id: 2, class: _ }
230 - { id: 3, class: _ }
231 - { id: 4, class: _ }
232 - { id: 5, class: _ }
238 %1(s8) = G_LOAD %0 :: (load (s8))
240 %3(s8) = G_LOAD %2 :: (load (s8))
241 %4(s8) = G_MUL %1, %3
242 ; G_MUL with s8 should widen
243 ; CHECK-NOT: {{%[0-9]+}}:_(s8) = G_MUL {{%[0-9]+, %[0-9]+}}
244 ; CHECK: {{%[0-9]+}}:_(s32) = G_MUL {{%[0-9]+, %[0-9]+}}
245 ; CHECK-NOT: {{%[0-9]+}}:_(s8) = G_MUL {{%[0-9]+, %[0-9]+}}
246 %5(s32) = G_SEXT %4(s8)
248 BX_RET 14, $noreg, implicit $r0
252 # CHECK-LABEL: name: test_mul_s16
254 # CHECK: legalized: true
255 regBankSelected: false
257 tracksRegLiveness: true
259 - { id: 0, class: _ }
260 - { id: 1, class: _ }
261 - { id: 2, class: _ }
262 - { id: 3, class: _ }
263 - { id: 4, class: _ }
264 - { id: 5, class: _ }
270 %1(s16) = G_LOAD %0 :: (load (s16))
272 %3(s16) = G_LOAD %2 :: (load (s16))
273 %4(s16) = G_MUL %1, %3
274 ; G_MUL with s16 should widen
275 ; CHECK-NOT: {{%[0-9]+}}:_(s16) = G_MUL {{%[0-9]+, %[0-9]+}}
276 ; CHECK: {{%[0-9]+}}:_(s32) = G_MUL {{%[0-9]+, %[0-9]+}}
277 ; CHECK-NOT: {{%[0-9]+}}:_(s16) = G_MUL {{%[0-9]+, %[0-9]+}}
278 %5(s32) = G_SEXT %4(s16)
280 BX_RET 14, $noreg, implicit $r0
284 # CHECK-LABEL: name: test_mul_s32
286 # CHECK: legalized: true
287 regBankSelected: false
289 tracksRegLiveness: true
291 - { id: 0, class: _ }
292 - { id: 1, class: _ }
293 - { id: 2, class: _ }
300 %2(s32) = G_MUL %0, %1
301 ; G_MUL with s32 is legal, so we should find it unchanged in the output
302 ; CHECK: {{%[0-9]+}}:_(s32) = G_MUL {{%[0-9]+, %[0-9]+}}
304 BX_RET 14, $noreg, implicit $r0
309 # CHECK-LABEL: name: test_and_s8
311 # CHECK: legalized: true
312 regBankSelected: false
314 tracksRegLiveness: true
316 - { id: 0, class: _ }
317 - { id: 1, class: _ }
318 - { id: 2, class: _ }
319 - { id: 3, class: _ }
320 - { id: 4, class: _ }
321 - { id: 5, class: _ }
327 %1(s8) = G_LOAD %0 :: (load (s8))
329 %3(s8) = G_LOAD %2 :: (load (s8))
330 %4(s8) = G_AND %1, %3
331 ; G_AND with s8 should widen
332 ; CHECK-NOT: {{%[0-9]+}}:_(s8) = G_AND {{%[0-9]+, %[0-9]+}}
333 ; CHECK: {{%[0-9]+}}:_(s32) = G_AND {{%[0-9]+, %[0-9]+}}
334 ; CHECK-NOT: {{%[0-9]+}}:_(s8) = G_AND {{%[0-9]+, %[0-9]+}}
335 %5(s32) = G_SEXT %4(s8)
337 BX_RET 14, $noreg, implicit $r0
341 # CHECK-LABEL: name: test_and_s16
343 # CHECK: legalized: true
344 regBankSelected: false
346 tracksRegLiveness: true
348 - { id: 0, class: _ }
349 - { id: 1, class: _ }
350 - { id: 2, class: _ }
351 - { id: 3, class: _ }
352 - { id: 4, class: _ }
353 - { id: 5, class: _ }
359 %1(s16) = G_LOAD %0 :: (load (s16))
361 %3(s16) = G_LOAD %2 :: (load (s16))
362 %4(s16) = G_AND %1, %3
363 ; G_AND with s16 should widen
364 ; CHECK-NOT: {{%[0-9]+}}:_(s16) = G_AND {{%[0-9]+, %[0-9]+}}
365 ; CHECK: {{%[0-9]+}}:_(s32) = G_AND {{%[0-9]+, %[0-9]+}}
366 ; CHECK-NOT: {{%[0-9]+}}:_(s16) = G_AND {{%[0-9]+, %[0-9]+}}
367 %5(s32) = G_SEXT %4(s16)
369 BX_RET 14, $noreg, implicit $r0
373 # CHECK-LABEL: name: test_and_s32
375 # CHECK: legalized: true
376 regBankSelected: false
378 tracksRegLiveness: true
380 - { id: 0, class: _ }
381 - { id: 1, class: _ }
382 - { id: 2, class: _ }
389 %2(s32) = G_AND %0, %1
390 ; G_AND with s32 is legal, so we should find it unchanged in the output
391 ; CHECK: {{%[0-9]+}}:_(s32) = G_AND {{%[0-9]+, %[0-9]+}}
393 BX_RET 14, $noreg, implicit $r0
398 # CHECK-LABEL: name: test_and_s64
400 # CHECK: legalized: true
401 regBankSelected: false
403 tracksRegLiveness: true
405 - { id: 0, class: _ }
406 - { id: 1, class: _ }
407 - { id: 2, class: _ }
408 - { id: 3, class: _ }
409 - { id: 4, class: _ }
410 - { id: 5, class: _ }
411 - { id: 6, class: _ }
412 - { id: 7, class: _ }
413 - { id: 8, class: _ }
416 liveins: $r0, $r1, $r2, $r3
422 %4(s64) = G_MERGE_VALUES %0(s32), %1(s32)
423 %5(s64) = G_MERGE_VALUES %2(s32), %3(s32)
424 %6(s64) = G_AND %4, %5
425 %7(s32), %8(s32) = G_UNMERGE_VALUES %6(s64)
428 BX_RET 14, $noreg, implicit $r0, implicit $r1
433 # CHECK-LABEL: name: test_or_s8
435 # CHECK: legalized: true
436 regBankSelected: false
438 tracksRegLiveness: true
440 - { id: 0, class: _ }
441 - { id: 1, class: _ }
442 - { id: 2, class: _ }
443 - { id: 3, class: _ }
444 - { id: 4, class: _ }
445 - { id: 5, class: _ }
451 %1(s8) = G_LOAD %0 :: (load (s8))
453 %3(s8) = G_LOAD %2 :: (load (s8))
455 ; G_OR with s8 should widen
456 ; CHECK-NOT: {{%[0-9]+}}:_(s8) = G_OR {{%[0-9]+, %[0-9]+}}
457 ; CHECK: {{%[0-9]+}}:_(s32) = G_OR {{%[0-9]+, %[0-9]+}}
458 ; CHECK-NOT: {{%[0-9]+}}:_(s8) = G_OR {{%[0-9]+, %[0-9]+}}
459 %5(s32) = G_SEXT %4(s8)
461 BX_RET 14, $noreg, implicit $r0
465 # CHECK-LABEL: name: test_or_s16
467 # CHECK: legalized: true
468 regBankSelected: false
470 tracksRegLiveness: true
472 - { id: 0, class: _ }
473 - { id: 1, class: _ }
474 - { id: 2, class: _ }
475 - { id: 3, class: _ }
476 - { id: 4, class: _ }
477 - { id: 5, class: _ }
483 %1(s16) = G_LOAD %0 :: (load (s16))
485 %3(s16) = G_LOAD %2 :: (load (s16))
486 %4(s16) = G_OR %1, %3
487 ; G_OR with s16 should widen
488 ; CHECK-NOT: {{%[0-9]+}}:_(s16) = G_OR {{%[0-9]+, %[0-9]+}}
489 ; CHECK: {{%[0-9]+}}:_(s32) = G_OR {{%[0-9]+, %[0-9]+}}
490 ; CHECK-NOT: {{%[0-9]+}}:_(s16) = G_OR {{%[0-9]+, %[0-9]+}}
491 %5(s32) = G_SEXT %4(s16)
493 BX_RET 14, $noreg, implicit $r0
497 # CHECK-LABEL: name: test_or_s32
499 # CHECK: legalized: true
500 regBankSelected: false
502 tracksRegLiveness: true
504 - { id: 0, class: _ }
505 - { id: 1, class: _ }
506 - { id: 2, class: _ }
513 %2(s32) = G_OR %0, %1
514 ; G_OR with s32 is legal, so we should find it unchanged in the output
515 ; CHECK: {{%[0-9]+}}:_(s32) = G_OR {{%[0-9]+, %[0-9]+}}
517 BX_RET 14, $noreg, implicit $r0
522 # CHECK-LABEL: name: test_or_s64
524 # CHECK: legalized: true
525 regBankSelected: false
527 tracksRegLiveness: true
529 - { id: 0, class: _ }
530 - { id: 1, class: _ }
531 - { id: 2, class: _ }
532 - { id: 3, class: _ }
533 - { id: 4, class: _ }
534 - { id: 5, class: _ }
535 - { id: 6, class: _ }
536 - { id: 7, class: _ }
537 - { id: 8, class: _ }
540 liveins: $r0, $r1, $r2, $r3
546 %4(s64) = G_MERGE_VALUES %0(s32), %1(s32)
547 %5(s64) = G_MERGE_VALUES %2(s32), %3(s32)
548 %6(s64) = G_OR %4, %5
549 %7(s32), %8(s32) = G_UNMERGE_VALUES %6(s64)
552 BX_RET 14, $noreg, implicit $r0, implicit $r1
557 # CHECK-LABEL: name: test_xor_s8
559 # CHECK: legalized: true
560 regBankSelected: false
562 tracksRegLiveness: true
564 - { id: 0, class: _ }
565 - { id: 1, class: _ }
566 - { id: 2, class: _ }
567 - { id: 3, class: _ }
568 - { id: 4, class: _ }
569 - { id: 5, class: _ }
575 %1(s8) = G_LOAD %0 :: (load (s8))
577 %3(s8) = G_LOAD %2 :: (load (s8))
578 %4(s8) = G_XOR %1, %3
579 ; G_XOR with s8 should widen
580 ; CHECK-NOT: {{%[0-9]+}}:_(s8) = G_XOR {{%[0-9]+, %[0-9]+}}
581 ; CHECK: {{%[0-9]+}}:_(s32) = G_XOR {{%[0-9]+, %[0-9]+}}
582 ; CHECK-NOT: {{%[0-9]+}}:_(s8) = G_XOR {{%[0-9]+, %[0-9]+}}
583 %5(s32) = G_SEXT %4(s8)
585 BX_RET 14, $noreg, implicit $r0
589 # CHECK-LABEL: name: test_xor_s16
591 # CHECK: legalized: true
592 regBankSelected: false
594 tracksRegLiveness: true
596 - { id: 0, class: _ }
597 - { id: 1, class: _ }
598 - { id: 2, class: _ }
599 - { id: 3, class: _ }
600 - { id: 4, class: _ }
601 - { id: 5, class: _ }
607 %1(s16) = G_LOAD %0 :: (load (s16))
609 %3(s16) = G_LOAD %2 :: (load (s16))
610 %4(s16) = G_XOR %1, %3
611 ; G_XOR with s16 should widen
612 ; CHECK-NOT: {{%[0-9]+}}:_(s16) = G_XOR {{%[0-9]+, %[0-9]+}}
613 ; CHECK: {{%[0-9]+}}:_(s32) = G_XOR {{%[0-9]+, %[0-9]+}}
614 ; CHECK-NOT: {{%[0-9]+}}:_(s16) = G_XOR {{%[0-9]+, %[0-9]+}}
615 %5(s32) = G_SEXT %4(s16)
617 BX_RET 14, $noreg, implicit $r0
621 # CHECK-LABEL: name: test_xor_s32
623 # CHECK: legalized: true
624 regBankSelected: false
626 tracksRegLiveness: true
628 - { id: 0, class: _ }
629 - { id: 1, class: _ }
630 - { id: 2, class: _ }
637 %2(s32) = G_XOR %0, %1
638 ; G_XOR with s32 is legal, so we should find it unchanged in the output
639 ; CHECK: {{%[0-9]+}}:_(s32) = G_XOR {{%[0-9]+, %[0-9]+}}
641 BX_RET 14, $noreg, implicit $r0
646 # CHECK-LABEL: name: test_xor_s64
648 # CHECK: legalized: true
649 regBankSelected: false
651 tracksRegLiveness: true
653 - { id: 0, class: _ }
654 - { id: 1, class: _ }
655 - { id: 2, class: _ }
656 - { id: 3, class: _ }
657 - { id: 4, class: _ }
658 - { id: 5, class: _ }
659 - { id: 6, class: _ }
660 - { id: 7, class: _ }
661 - { id: 8, class: _ }
664 liveins: $r0, $r1, $r2, $r3
670 %4(s64) = G_MERGE_VALUES %0(s32), %1(s32)
671 %5(s64) = G_MERGE_VALUES %2(s32), %3(s32)
672 %6(s64) = G_XOR %4, %5
673 %7(s32), %8(s32) = G_UNMERGE_VALUES %6(s64)
676 BX_RET 14, $noreg, implicit $r0, implicit $r1
681 # CHECK-LABEL: name: test_lshr_s32
683 # CHECK: legalized: true
684 regBankSelected: false
686 tracksRegLiveness: true
688 - { id: 0, class: _ }
689 - { id: 1, class: _ }
690 - { id: 2, class: _ }
697 %2(s32) = G_LSHR %0, %1
698 ; G_LSHR with s32 is legal, so we should find it unchanged in the output
699 ; CHECK: {{%[0-9]+}}:_(s32) = G_LSHR {{%[0-9]+, %[0-9]+}}
701 BX_RET 14, $noreg, implicit $r0
706 # CHECK-LABEL: name: test_ashr_s32
708 # CHECK: legalized: true
709 regBankSelected: false
711 tracksRegLiveness: true
713 - { id: 0, class: _ }
714 - { id: 1, class: _ }
715 - { id: 2, class: _ }
722 %2(s32) = G_ASHR %0, %1
723 ; G_ASHR with s32 is legal, so we should find it unchanged in the output
724 ; CHECK: {{%[0-9]+}}:_(s32) = G_ASHR {{%[0-9]+, %[0-9]+}}
726 BX_RET 14, $noreg, implicit $r0
731 # CHECK-LABEL: name: test_shl_s32
733 # CHECK: legalized: true
734 regBankSelected: false
736 tracksRegLiveness: true
738 - { id: 0, class: _ }
739 - { id: 1, class: _ }
740 - { id: 2, class: _ }
747 %2(s32) = G_SHL %0, %1
748 ; G_SHL with s32 is legal, so we should find it unchanged in the output
749 ; CHECK: {{%[0-9]+}}:_(s32) = G_SHL {{%[0-9]+, %[0-9]+}}
751 BX_RET 14, $noreg, implicit $r0
756 # CHECK-LABEL: name: test_shift_s8
758 # CHECK: legalized: true
759 regBankSelected: false
761 tracksRegLiveness: true
763 - { id: 0, class: _ }
764 - { id: 1, class: _ }
765 - { id: 2, class: _ }
766 - { id: 3, class: _ }
767 - { id: 4, class: _ }
774 %2(s8) = G_TRUNC %0(s32)
775 %3(s8) = G_SHL %2, %1(s32)
776 ; G_SHL with s8 should widen
777 ; CHECK-NOT: {{%[0-9]+}}:_(s8) = G_SHL {{%[0-9]+, %[0-9]+}}
778 ; CHECK: {{%[0-9]+}}:_(s32) = G_SHL {{%[0-9]+, %[0-9]+}}
779 ; CHECK-NOT: {{%[0-9]+}}:_(s8) = G_SHL {{%[0-9]+, %[0-9]+}}
780 %4(s32) = G_SEXT %3(s8)
782 BX_RET 14, $noreg, implicit $r0
786 # CHECK-LABEL: name: test_shift_s16
788 # CHECK: legalized: true
789 regBankSelected: false
791 tracksRegLiveness: true
793 - { id: 0, class: _ }
794 - { id: 1, class: _ }
795 - { id: 2, class: _ }
796 - { id: 3, class: _ }
797 - { id: 4, class: _ }
804 %2(s16) = G_TRUNC %0(s32)
805 %3(s16) = G_SHL %2, %1(s32)
806 ; G_SHL with s16 should widen
807 ; CHECK-NOT: {{%[0-9]+}}:_(s16) = G_SHL {{%[0-9]+, %[0-9]+}}
808 ; CHECK: {{%[0-9]+}}:_(s32) = G_SHL {{%[0-9]+, %[0-9]+}}
809 ; CHECK-NOT: {{%[0-9]+}}:_(s16) = G_SHL {{%[0-9]+, %[0-9]+}}
810 %4(s32) = G_SEXT %3(s16)
812 BX_RET 14, $noreg, implicit $r0
815 name: test_shift_amount_s8
816 # CHECK-LABEL: name: test_shift_amount_s8
818 # CHECK: legalized: true
819 regBankSelected: false
821 tracksRegLiveness: true
823 - { id: 0, class: _ }
824 - { id: 1, class: _ }
825 - { id: 2, class: _ }
826 - { id: 3, class: _ }
833 %2(s8) = G_TRUNC %0(s32)
834 %3(s32) = G_SHL %1, %2(s8)
835 ; G_SHL with s8 amount should widen
836 ; CHECK-NOT: {{%[0-9]+}}:_(s32) = G_SHL {{%[0-9]+, %[0-9]+}}(s8)
837 ; CHECK: {{%[0-9]+}}:_(s32) = G_SHL {{%[0-9]+, %[0-9]+}}(s32)
838 ; CHECK-NOT: {{%[0-9]+}}:_(s32) = G_SHL {{%[0-9]+, %[0-9]+}}(s8)
840 BX_RET 14, $noreg, implicit $r0
843 name: test_shift_amount_s16
844 # CHECK-LABEL: name: test_shift_amount_s16
846 # CHECK: legalized: true
847 regBankSelected: false
849 tracksRegLiveness: true
851 - { id: 0, class: _ }
852 - { id: 1, class: _ }
853 - { id: 2, class: _ }
854 - { id: 3, class: _ }
861 %2(s16) = G_TRUNC %0(s32)
862 %3(s32) = G_SHL %1, %2(s16)
863 ; G_SHL with s16 amount should widen
864 ; CHECK-NOT: {{%[0-9]+}}:_(s32) = G_SHL {{%[0-9]+, %[0-9]+}}(s16)
865 ; CHECK: {{%[0-9]+}}:_(s32) = G_SHL {{%[0-9]+, %[0-9]+}}(s32)
866 ; CHECK-NOT: {{%[0-9]+}}:_(s32) = G_SHL {{%[0-9]+, %[0-9]+}}(s16)
868 BX_RET 14, $noreg, implicit $r0