@@ -270,8 +270,6 @@ def SDT_RISCVSETCCOP_VL : SDTypeProfile<1, 6, [
270
270
SDTCisSameAs<0, 5>, SDTCisVT<6, XLenVT>]>;
271
271
272
272
// Float -> Int
273
- def riscv_vfcvt_xu_f_vl : SDNode<"RISCVISD::VFCVT_XU_F_VL", SDT_RISCVFP2IOp_VL>;
274
- def riscv_vfcvt_x_f_vl : SDNode<"RISCVISD::VFCVT_X_F_VL", SDT_RISCVFP2IOp_VL>;
275
273
def riscv_vfcvt_rm_xu_f_vl : SDNode<"RISCVISD::VFCVT_RM_XU_F_VL", SDT_RISCVFP2IOp_RM_VL>;
276
274
def riscv_vfcvt_rm_x_f_vl : SDNode<"RISCVISD::VFCVT_RM_X_F_VL", SDT_RISCVFP2IOp_RM_VL>;
277
275
@@ -1206,24 +1204,6 @@ multiclass VPatConvertFP2IVL_V<SDPatternOperator vop, string instruction_name> {
1206
1204
}
1207
1205
}
1208
1206
1209
- multiclass VPatConvertFP2IVL_V_RM<SDPatternOperator vop, string instruction_name> {
1210
- foreach fvti = AllFloatVectors in {
1211
- defvar ivti = GetIntVTypeInfo<fvti>.Vti;
1212
- let Predicates = !listconcat(GetVTypePredicates<fvti>.Predicates,
1213
- GetVTypePredicates<ivti>.Predicates) in
1214
- def : Pat<(ivti.Vector (vop (fvti.Vector fvti.RegClass:$rs1),
1215
- (fvti.Mask V0),
1216
- VLOpFrag)),
1217
- (!cast<Instruction>(instruction_name#"_"#ivti.LMul.MX#"_MASK")
1218
- (ivti.Vector (IMPLICIT_DEF)), fvti.RegClass:$rs1,
1219
- (fvti.Mask V0),
1220
- // Value to indicate no rounding mode change in
1221
- // RISCVInsertReadWriteCSR
1222
- FRM_DYN,
1223
- GPR:$vl, ivti.Log2SEW, TA_MA)>;
1224
- }
1225
- }
1226
-
1227
1207
1228
1208
multiclass VPatConvertFP2I_RM_VL_V<SDPatternOperator vop, string instruction_name> {
1229
1209
foreach fvti = AllFloatVectors in {
@@ -1289,25 +1269,6 @@ multiclass VPatWConvertFP2IVL_V<SDPatternOperator vop, string instruction_name>
1289
1269
}
1290
1270
}
1291
1271
1292
- multiclass VPatWConvertFP2IVL_V_RM<SDPatternOperator vop, string instruction_name> {
1293
- foreach fvtiToFWti = AllWidenableFloatVectors in {
1294
- defvar fvti = fvtiToFWti.Vti;
1295
- defvar iwti = GetIntVTypeInfo<fvtiToFWti.Wti>.Vti;
1296
- let Predicates = !listconcat(GetVTypePredicates<fvti>.Predicates,
1297
- GetVTypePredicates<iwti>.Predicates) in
1298
- def : Pat<(iwti.Vector (vop (fvti.Vector fvti.RegClass:$rs1),
1299
- (fvti.Mask V0),
1300
- VLOpFrag)),
1301
- (!cast<Instruction>(instruction_name#"_"#fvti.LMul.MX#"_MASK")
1302
- (iwti.Vector (IMPLICIT_DEF)), fvti.RegClass:$rs1,
1303
- (fvti.Mask V0),
1304
- // Value to indicate no rounding mode change in
1305
- // RISCVInsertReadWriteCSR
1306
- FRM_DYN,
1307
- GPR:$vl, fvti.Log2SEW, TA_MA)>;
1308
- }
1309
- }
1310
-
1311
1272
1312
1273
multiclass VPatWConvertFP2I_RM_VL_V<SDNode vop, string instruction_name> {
1313
1274
foreach fvtiToFWti = AllWidenableFloatVectors in {
@@ -1361,28 +1322,6 @@ multiclass VPatNConvertFP2IVL_W<SDPatternOperator vop,
1361
1322
}
1362
1323
}
1363
1324
1364
- multiclass VPatNConvertFP2IVL_W_RM<SDPatternOperator vop,
1365
- string instruction_name> {
1366
- // Reuse the same list of types used in the widening nodes, but just swap the
1367
- // direction of types around so we're converting from Wti -> Vti
1368
- foreach vtiToWti = AllWidenableIntToFloatVectors in {
1369
- defvar vti = vtiToWti.Vti;
1370
- defvar fwti = vtiToWti.Wti;
1371
- let Predicates = !listconcat(GetVTypePredicates<vti>.Predicates,
1372
- GetVTypePredicates<fwti>.Predicates) in
1373
- def : Pat<(vti.Vector (vop (fwti.Vector fwti.RegClass:$rs1),
1374
- (fwti.Mask V0),
1375
- VLOpFrag)),
1376
- (!cast<Instruction>(instruction_name#"_"#vti.LMul.MX#"_MASK")
1377
- (vti.Vector (IMPLICIT_DEF)), fwti.RegClass:$rs1,
1378
- (fwti.Mask V0),
1379
- // Value to indicate no rounding mode change in
1380
- // RISCVInsertReadWriteCSR
1381
- FRM_DYN,
1382
- GPR:$vl, vti.Log2SEW, TA_MA)>;
1383
- }
1384
- }
1385
-
1386
1325
multiclass VPatNConvertFP2I_RM_VL_W<SDNode vop, string instruction_name> {
1387
1326
foreach vtiToWti = AllWidenableIntToFloatVectors in {
1388
1327
defvar vti = vtiToWti.Vti;
@@ -2637,8 +2576,6 @@ foreach fvti = AllFloatVectors in {
2637
2576
}
2638
2577
2639
2578
// 13.17. Vector Single-Width Floating-Point/Integer Type-Convert Instructions
2640
- defm : VPatConvertFP2IVL_V_RM<riscv_vfcvt_xu_f_vl, "PseudoVFCVT_XU_F_V">;
2641
- defm : VPatConvertFP2IVL_V_RM<riscv_vfcvt_x_f_vl, "PseudoVFCVT_X_F_V">;
2642
2579
defm : VPatConvertFP2I_RM_VL_V<riscv_vfcvt_rm_xu_f_vl, "PseudoVFCVT_XU_F_V">;
2643
2580
defm : VPatConvertFP2I_RM_VL_V<any_riscv_vfcvt_rm_x_f_vl, "PseudoVFCVT_X_F_V">;
2644
2581
@@ -2652,8 +2589,6 @@ defm : VPatConvertI2FP_RM_VL_V<riscv_vfcvt_rm_f_xu_vl, "PseudoVFCVT_F_XU_V">;
2652
2589
defm : VPatConvertI2FP_RM_VL_V<riscv_vfcvt_rm_f_x_vl, "PseudoVFCVT_F_X_V">;
2653
2590
2654
2591
// 13.18. Widening Floating-Point/Integer Type-Convert Instructions
2655
- defm : VPatWConvertFP2IVL_V_RM<riscv_vfcvt_xu_f_vl, "PseudoVFWCVT_XU_F_V">;
2656
- defm : VPatWConvertFP2IVL_V_RM<riscv_vfcvt_x_f_vl, "PseudoVFWCVT_X_F_V">;
2657
2592
defm : VPatWConvertFP2I_RM_VL_V<riscv_vfcvt_rm_xu_f_vl, "PseudoVFWCVT_XU_F_V">;
2658
2593
defm : VPatWConvertFP2I_RM_VL_V<riscv_vfcvt_rm_x_f_vl, "PseudoVFWCVT_X_F_V">;
2659
2594
@@ -2694,8 +2629,6 @@ foreach fvtiToFWti = AllWidenableBFloatToFloatVectors in {
2694
2629
}
2695
2630
2696
2631
// 13.19 Narrowing Floating-Point/Integer Type-Convert Instructions
2697
- defm : VPatNConvertFP2IVL_W_RM<riscv_vfcvt_xu_f_vl, "PseudoVFNCVT_XU_F_W">;
2698
- defm : VPatNConvertFP2IVL_W_RM<riscv_vfcvt_x_f_vl, "PseudoVFNCVT_X_F_W">;
2699
2632
defm : VPatNConvertFP2I_RM_VL_W<riscv_vfcvt_rm_xu_f_vl, "PseudoVFNCVT_XU_F_W">;
2700
2633
defm : VPatNConvertFP2I_RM_VL_W<riscv_vfcvt_rm_x_f_vl, "PseudoVFNCVT_X_F_W">;
2701
2634
0 commit comments