@@ -1466,7 +1466,6 @@ define i1 @icmp_shl_nuw_1(i64 %a) {
1466
1466
%shl = shl nuw i64 1 , %a
1467
1467
%cmp = icmp ne i64 %shl , 0
1468
1468
ret i1 %cmp
1469
-
1470
1469
}
1471
1470
1472
1471
define i1 @icmp_shl_1_V_ugt_2147483648 (i32 %V ) {
@@ -1476,7 +1475,39 @@ define i1 @icmp_shl_1_V_ugt_2147483648(i32 %V) {
1476
1475
%shl = shl i32 1 , %V
1477
1476
%cmp = icmp ugt i32 %shl , 2147483648
1478
1477
ret i1 %cmp
1478
+ }
1479
+
1480
+ define <2 x i1 > @icmp_shl_1_ugt_signmask (<2 x i8 > %V ) {
1481
+ ; CHECK-LABEL: @icmp_shl_1_ugt_signmask(
1482
+ ; CHECK-NEXT: [[SHL:%.*]] = shl <2 x i8> <i8 1, i8 1>, [[V:%.*]]
1483
+ ; CHECK-NEXT: [[CMP:%.*]] = icmp ugt <2 x i8> [[SHL]], <i8 -128, i8 -128>
1484
+ ; CHECK-NEXT: ret <2 x i1> [[CMP]]
1485
+ ;
1486
+ %shl = shl <2 x i8 > <i8 1 , i8 1 >, %V
1487
+ %cmp = icmp ugt <2 x i8 > %shl , <i8 128 , i8 128 >
1488
+ ret <2 x i1 > %cmp
1489
+ }
1490
+
1491
+ define <2 x i1 > @icmp_shl_1_ugt_signmask_undef (<2 x i8 > %V ) {
1492
+ ; CHECK-LABEL: @icmp_shl_1_ugt_signmask_undef(
1493
+ ; CHECK-NEXT: [[SHL:%.*]] = shl <2 x i8> <i8 1, i8 1>, [[V:%.*]]
1494
+ ; CHECK-NEXT: [[CMP:%.*]] = icmp ugt <2 x i8> [[SHL]], <i8 -128, i8 undef>
1495
+ ; CHECK-NEXT: ret <2 x i1> [[CMP]]
1496
+ ;
1497
+ %shl = shl <2 x i8 > <i8 1 , i8 1 >, %V
1498
+ %cmp = icmp ugt <2 x i8 > %shl , <i8 128 , i8 undef >
1499
+ ret <2 x i1 > %cmp
1500
+ }
1479
1501
1502
+ define <2 x i1 > @icmp_shl_1_ugt_signmask_undef2 (<2 x i8 > %V ) {
1503
+ ; CHECK-LABEL: @icmp_shl_1_ugt_signmask_undef2(
1504
+ ; CHECK-NEXT: [[SHL:%.*]] = shl <2 x i8> <i8 1, i8 undef>, [[V:%.*]]
1505
+ ; CHECK-NEXT: [[CMP:%.*]] = icmp ugt <2 x i8> [[SHL]], <i8 undef, i8 -128>
1506
+ ; CHECK-NEXT: ret <2 x i1> [[CMP]]
1507
+ ;
1508
+ %shl = shl <2 x i8 > <i8 1 , i8 undef >, %V
1509
+ %cmp = icmp ugt <2 x i8 > %shl , <i8 undef , i8 128 >
1510
+ ret <2 x i1 > %cmp
1480
1511
}
1481
1512
1482
1513
define i1 @icmp_shl_1_V_ule_2147483648 (i32 %V ) {
@@ -1486,7 +1517,39 @@ define i1 @icmp_shl_1_V_ule_2147483648(i32 %V) {
1486
1517
%shl = shl i32 1 , %V
1487
1518
%cmp = icmp ule i32 %shl , 2147483648
1488
1519
ret i1 %cmp
1520
+ }
1489
1521
1522
+ define <2 x i1 > @icmp_shl_1_ule_signmask (<2 x i8 > %V ) {
1523
+ ; CHECK-LABEL: @icmp_shl_1_ule_signmask(
1524
+ ; CHECK-NEXT: [[SHL:%.*]] = shl <2 x i8> <i8 1, i8 1>, [[V:%.*]]
1525
+ ; CHECK-NEXT: [[CMP:%.*]] = icmp ule <2 x i8> [[SHL]], <i8 -128, i8 -128>
1526
+ ; CHECK-NEXT: ret <2 x i1> [[CMP]]
1527
+ ;
1528
+ %shl = shl <2 x i8 > <i8 1 , i8 1 >, %V
1529
+ %cmp = icmp ule <2 x i8 > %shl , <i8 128 , i8 128 >
1530
+ ret <2 x i1 > %cmp
1531
+ }
1532
+
1533
+ define <2 x i1 > @icmp_shl_1_ule_signmask_undef (<2 x i8 > %V ) {
1534
+ ; CHECK-LABEL: @icmp_shl_1_ule_signmask_undef(
1535
+ ; CHECK-NEXT: [[SHL:%.*]] = shl <2 x i8> <i8 1, i8 1>, [[V:%.*]]
1536
+ ; CHECK-NEXT: [[CMP:%.*]] = icmp ule <2 x i8> [[SHL]], <i8 -128, i8 undef>
1537
+ ; CHECK-NEXT: ret <2 x i1> [[CMP]]
1538
+ ;
1539
+ %shl = shl <2 x i8 > <i8 1 , i8 1 >, %V
1540
+ %cmp = icmp ule <2 x i8 > %shl , <i8 128 , i8 undef >
1541
+ ret <2 x i1 > %cmp
1542
+ }
1543
+
1544
+ define <2 x i1 > @icmp_shl_1_ule_signmask_undef2 (<2 x i8 > %V ) {
1545
+ ; CHECK-LABEL: @icmp_shl_1_ule_signmask_undef2(
1546
+ ; CHECK-NEXT: [[SHL:%.*]] = shl <2 x i8> <i8 1, i8 undef>, [[V:%.*]]
1547
+ ; CHECK-NEXT: [[CMP:%.*]] = icmp ule <2 x i8> [[SHL]], <i8 undef, i8 -128>
1548
+ ; CHECK-NEXT: ret <2 x i1> [[CMP]]
1549
+ ;
1550
+ %shl = shl <2 x i8 > <i8 1 , i8 undef >, %V
1551
+ %cmp = icmp ule <2 x i8 > %shl , <i8 undef , i8 128 >
1552
+ ret <2 x i1 > %cmp
1490
1553
}
1491
1554
1492
1555
define i1 @icmp_shl_1_V_eq_31 (i32 %V ) {
@@ -1496,7 +1559,6 @@ define i1 @icmp_shl_1_V_eq_31(i32 %V) {
1496
1559
%shl = shl i32 1 , %V
1497
1560
%cmp = icmp eq i32 %shl , 31
1498
1561
ret i1 %cmp
1499
-
1500
1562
}
1501
1563
1502
1564
define i1 @icmp_shl_1_V_ne_31 (i32 %V ) {
@@ -1506,7 +1568,6 @@ define i1 @icmp_shl_1_V_ne_31(i32 %V) {
1506
1568
%shl = shl i32 1 , %V
1507
1569
%cmp = icmp ne i32 %shl , 31
1508
1570
ret i1 %cmp
1509
-
1510
1571
}
1511
1572
1512
1573
define i1 @tautological1 (i32 %A , i32 %B ) {
0 commit comments