@@ -25,6 +25,7 @@ def rvv_vnot : PatFrag<(ops node:$in),
2525 (xor node:$in, (riscv_vmset_vl (XLenVT srcvalue)))>;
2626
2727multiclass VPatUSLoadStoreSDNode<ValueType type,
28+ RegisterClass regclass,
2829 int log2sew,
2930 LMULInfo vlmul,
3031 OutPatFrag avl,
@@ -37,7 +38,7 @@ multiclass VPatUSLoadStoreSDNode<ValueType type,
3738 (load_instr (type (IMPLICIT_DEF)), GPR:$rs1, avl,
3839 log2sew, TA_MA)>;
3940 // Store
40- def : Pat<(store type:$rs2, (XLenVT GPR:$rs1)),
41+ def : Pat<(store ( type regclass :$rs2) , (XLenVT GPR:$rs1)),
4142 (store_instr reg_class:$rs2, GPR:$rs1, avl, log2sew)>;
4243}
4344
@@ -49,7 +50,7 @@ multiclass VPatUSLoadStoreMaskSDNode<MTypeInfo m> {
4950 (load_instr (m.Mask (IMPLICIT_DEF)), GPR:$rs1, m.AVL,
5051 m.Log2SEW, TA_MA)>;
5152 // Store
52- def : Pat<(store m.Mask:$rs2, GPR:$rs1),
53+ def : Pat<(store ( m.Mask VR :$rs2) , GPR:$rs1),
5354 (store_instr VR:$rs2, GPR:$rs1, m.AVL, m.Log2SEW)>;
5455}
5556
@@ -884,7 +885,7 @@ multiclass VPatAVGADD_VV_VX_RM<SDNode vop, int vxrm, string suffix = ""> {
884885foreach vti = AllVectors in
885886 let Predicates = !if(!eq(vti.Scalar, f16), [HasVInstructionsF16Minimal],
886887 GetVTypePredicates<vti>.Predicates) in
887- defm : VPatUSLoadStoreSDNode<vti.Vector, vti.Log2SEW, vti.LMul,
888+ defm : VPatUSLoadStoreSDNode<vti.Vector, vti.RegClass, vti. Log2SEW, vti.LMul,
888889 vti.AVL, vti.RegClass>;
889890foreach mti = AllMasks in
890891 let Predicates = [HasVInstructions] in
0 commit comments