@@ -602,7 +602,11 @@ def MOVI32ri : MxPseudoMove_DI<MxType32r>;
602
602
/// what registers are allocated for the operands and if they overlap we just
603
603
/// extend the value if the registers are completely different we need to move
604
604
/// first.
605
- foreach EXT = ["S", "Z"] in {
605
+ /// The "" group (MOVXd16d8, etc.) is similar to the others but does NOT do any
606
+ /// value extension, they just load a smaller register into the lower part of
607
+ /// another register if operands' real registers are different or does nothing
608
+ /// if they are the same.
609
+ foreach EXT = ["S", "Z", ""] in {
606
610
let hasSideEffects = 0 in {
607
611
608
612
def MOV#EXT#Xd16d8 : MxPseudoMove_RR<MxType16d, MxType8d>;
@@ -631,14 +635,6 @@ foreach EXT = ["S", "Z"] in {
631
635
}
632
636
}
633
637
634
- /// This group of instructions is similar to the group above but DOES NOT do
635
- /// any value extension, they just load a smaller register into the lower part
636
- /// of another register if operands' real registers are different or does
637
- /// nothing if they are the same.
638
- def MOVXd16d8 : MxPseudoMove_RR<MxType16d, MxType8d>;
639
- def MOVXd32d8 : MxPseudoMove_RR<MxType32d, MxType8d>;
640
- def MOVXd32d16 : MxPseudoMove_RR<MxType32r, MxType16r>;
641
-
642
638
//===----------------------------------------------------------------------===//
643
639
// Extend/Truncate Patterns
644
640
//===----------------------------------------------------------------------===//
@@ -686,22 +682,22 @@ def: Pat<(MxZExtLoadi32i16 MxCP_ARII:$src), (MOVZXd32f16 MxARII16:$src)>;
686
682
def: Pat<(MxZExtLoadi32i16 MxCP_PCD :$src), (MOVZXd32q16 MxPCD16 :$src)>;
687
683
688
684
// i16 <- anyext i8
689
- def: Pat<(i16 (anyext i8:$src)), (MOVZXd16d8 MxDRD8:$src)>;
690
- def: Pat<(MxExtLoadi16i8 MxCP_ARI:$src), (MOVZXd16j8 MxARI8:$src)>;
691
- def: Pat<(MxExtLoadi16i8 MxCP_ARID:$src), (MOVZXd16p8 MxARID8:$src)>;
692
- def: Pat<(MxExtLoadi16i8 MxCP_ARII:$src), (MOVZXd16f8 MxARII8:$src)>;
685
+ def: Pat<(i16 (anyext i8:$src)), (MOVXd16d8 MxDRD8:$src)>;
686
+ def: Pat<(MxExtLoadi16i8 MxCP_ARI:$src), (MOVXd16j8 MxARI8:$src)>;
687
+ def: Pat<(MxExtLoadi16i8 MxCP_ARID:$src), (MOVXd16p8 MxARID8:$src)>;
688
+ def: Pat<(MxExtLoadi16i8 MxCP_ARII:$src), (MOVXd16f8 MxARII8:$src)>;
693
689
694
690
// i32 <- anyext i8
695
- def: Pat<(i32 (anyext i8:$src)), (MOVZXd32d8 MxDRD8:$src)>;
696
- def: Pat<(MxExtLoadi32i8 MxCP_ARI :$src), (MOVZXd32j8 MxARI8 :$src)>;
697
- def: Pat<(MxExtLoadi32i8 MxCP_ARID:$src), (MOVZXd32p8 MxARID8:$src)>;
698
- def: Pat<(MxExtLoadi32i8 MxCP_ARII:$src), (MOVZXd32f8 MxARII8:$src)>;
691
+ def: Pat<(i32 (anyext i8:$src)), (MOVXd32d8 MxDRD8:$src)>;
692
+ def: Pat<(MxExtLoadi32i8 MxCP_ARI :$src), (MOVXd32j8 MxARI8 :$src)>;
693
+ def: Pat<(MxExtLoadi32i8 MxCP_ARID:$src), (MOVXd32p8 MxARID8:$src)>;
694
+ def: Pat<(MxExtLoadi32i8 MxCP_ARII:$src), (MOVXd32f8 MxARII8:$src)>;
699
695
700
696
// i32 <- anyext i16
701
- def: Pat<(i32 (anyext i16:$src)), (MOVZXd32d16 MxDRD16:$src)>;
702
- def: Pat<(MxExtLoadi32i16 MxCP_ARI :$src), (MOVZXd32j16 MxARI16 :$src)>;
703
- def: Pat<(MxExtLoadi32i16 MxCP_ARID:$src), (MOVZXd32p16 MxARID16:$src)>;
704
- def: Pat<(MxExtLoadi32i16 MxCP_ARII:$src), (MOVZXd32f16 MxARII16:$src)>;
697
+ def: Pat<(i32 (anyext i16:$src)), (MOVXd32d16 MxDRD16:$src)>;
698
+ def: Pat<(MxExtLoadi32i16 MxCP_ARI :$src), (MOVXd32j16 MxARI16 :$src)>;
699
+ def: Pat<(MxExtLoadi32i16 MxCP_ARID:$src), (MOVXd32p16 MxARID16:$src)>;
700
+ def: Pat<(MxExtLoadi32i16 MxCP_ARII:$src), (MOVXd32f16 MxARII16:$src)>;
705
701
706
702
// trunc patterns
707
703
def : Pat<(i16 (trunc i32:$src)),
0 commit comments