@@ -143,22 +143,24 @@ class PseudoToVInst<string PseudoInst> {
143143
144144// This class describes information associated to the LMUL.
145145class LMULInfo<int lmul, int oct, VReg regclass, VReg wregclass,
146- VReg f2regclass, VReg f4regclass, VReg f8regclass, string mx> {
146+ VReg f2regclass, VReg f4regclass, VReg f8regclass, string mx,
147+ VReg moutregclass = VMM1> {
147148 bits<3> value = lmul; // This is encoded as the vlmul field of vtype.
148149 VReg vrclass = regclass;
149150 VReg wvrclass = wregclass;
150151 VReg f8vrclass = f8regclass;
151152 VReg f4vrclass = f4regclass;
152153 VReg f2vrclass = f2regclass;
154+ VReg moutclass = moutregclass;
153155 string MX = mx;
154156 int octuple = oct;
155157}
156158
157159// Associate LMUL with tablegen records of register classes.
158160def V_M1 : LMULInfo<0b000, 8, VR, VRM2, VR, VR, VR, "M1">;
159- def V_M2 : LMULInfo<0b001, 16, VRM2, VRM4, VR, VR, VR, "M2">;
160- def V_M4 : LMULInfo<0b010, 32, VRM4, VRM8, VRM2, VR, VR, "M4">;
161- def V_M8 : LMULInfo<0b011, 64, VRM8,/*NoVReg*/VR, VRM4, VRM2, VR, "M8">;
161+ def V_M2 : LMULInfo<0b001, 16, VRM2, VRM4, VR, VR, VR, "M2", VMM2 >;
162+ def V_M4 : LMULInfo<0b010, 32, VRM4, VRM8, VRM2, VR, VR, "M4", VMM4 >;
163+ def V_M8 : LMULInfo<0b011, 64, VRM8,/*NoVReg*/VR, VRM4, VRM2, VR, "M8", VMM8 >;
162164
163165def V_MF8 : LMULInfo<0b101, 1, VR, VR,/*NoVReg*/VR,/*NoVReg*/VR,/*NoVReg*/VR, "MF8">;
164166def V_MF4 : LMULInfo<0b110, 2, VR, VR, VR,/*NoVReg*/VR,/*NoVReg*/VR, "MF4">;
@@ -2668,25 +2670,21 @@ multiclass PseudoVEXT_VF8 {
26682670// With LMUL<=1 the source and dest occupy a single register so any overlap
26692671// is in the lowest-numbered part.
26702672multiclass VPseudoBinaryM_VV<LMULInfo m, int TargetConstraintType = 1> {
2671- defm _VV : VPseudoBinaryM<VR, m.vrclass, m.vrclass, m,
2672- !if(!ge(m.octuple, 16), "@earlyclobber $rd", ""), TargetConstraintType>;
2673+ defm _VV : VPseudoBinaryM<m.moutclass, m.vrclass, m.vrclass, m, "", TargetConstraintType>;
26732674}
26742675
26752676multiclass VPseudoBinaryM_VX<LMULInfo m, int TargetConstraintType = 1> {
26762677 defm "_VX" :
2677- VPseudoBinaryM<VR, m.vrclass, GPR, m,
2678- !if(!ge(m.octuple, 16), "@earlyclobber $rd", ""), TargetConstraintType>;
2678+ VPseudoBinaryM<m.moutclass, m.vrclass, GPR, m, "", TargetConstraintType>;
26792679}
26802680
26812681multiclass VPseudoBinaryM_VF<LMULInfo m, FPR_Info f, int TargetConstraintType = 1> {
26822682 defm "_V" # f.FX :
2683- VPseudoBinaryM<VR, m.vrclass, f.fprclass, m,
2684- !if(!ge(m.octuple, 16), "@earlyclobber $rd", ""), TargetConstraintType>;
2683+ VPseudoBinaryM<m.moutclass, m.vrclass, f.fprclass, m, "", TargetConstraintType>;
26852684}
26862685
26872686multiclass VPseudoBinaryM_VI<LMULInfo m, int TargetConstraintType = 1> {
2688- defm _VI : VPseudoBinaryM<VR, m.vrclass, simm5, m,
2689- !if(!ge(m.octuple, 16), "@earlyclobber $rd", ""), TargetConstraintType>;
2687+ defm _VI : VPseudoBinaryM<m.moutclass, m.vrclass, simm5, m, "", TargetConstraintType>;
26902688}
26912689
26922690multiclass VPseudoVGTR_VV_VX_VI<Operand ImmType = simm5, string Constraint = ""> {
0 commit comments