@@ -219,10 +219,6 @@ multiclass Binary_vr_vv<
219
219
defm : Binary_vr<OpNode, ScalarVT, DataVT, MaskVT, OpBaseName>;
220
220
defm : Binary_vv<OpNode, DataVT, MaskVT, OpBaseName>;
221
221
}
222
- multiclass Binary_vr_vv_ShortLong<SDPatternOperator OpNode, ValueType LongScalarVT, ValueType LongDataVT, string LongOpBaseName, ValueType ShortScalarVT, ValueType ShortDataVT, string ShortOpBaseName> {
223
- defm : Binary_vr_vv<OpNode, LongScalarVT, LongDataVT, v256i1, LongOpBaseName>;
224
- defm : Binary_vr_vv<OpNode, ShortScalarVT, ShortDataVT, v256i1, ShortOpBaseName>;
225
- }
226
222
227
223
// Binary operators that support broadcasts only on LHS.
228
224
multiclass Binary_rv_vv<
@@ -233,6 +229,7 @@ multiclass Binary_rv_vv<
233
229
defm : Binary_vv<OpNode, DataVT, MaskVT, OpBaseName>;
234
230
}
235
231
232
+ // Expand both 64bit and 32 bit variant (256 elements)
236
233
multiclass Binary_rv_vv_ShortLong<
237
234
SDPatternOperator OpNode,
238
235
ValueType LongScalarVT, ValueType LongDataVT, string LongOpBaseName,
@@ -245,6 +242,18 @@ multiclass Binary_rv_vv_ShortLong<
245
242
ShortOpBaseName>;
246
243
}
247
244
245
+ multiclass Binary_vr_vv_ShortLong<
246
+ SDPatternOperator OpNode,
247
+ ValueType LongScalarVT, ValueType LongDataVT, string LongOpBaseName,
248
+ ValueType ShortScalarVT, ValueType ShortDataVT, string ShortOpBaseName> {
249
+ defm : Binary_vr_vv<OpNode,
250
+ LongScalarVT, LongDataVT, v256i1,
251
+ LongOpBaseName>;
252
+ defm : Binary_vr_vv<OpNode,
253
+ ShortScalarVT, ShortDataVT, v256i1,
254
+ ShortOpBaseName>;
255
+ }
256
+
248
257
// Binary operators that support broadcasts on LHS and RHS.
249
258
multiclass Binary_all<
250
259
SDPatternOperator OpNode,
@@ -345,9 +354,15 @@ defm : Binary_rv_vv_ShortLong<c_vvp_xor,
345
354
defm : Binary_ShortLong<vvp_sdiv, i64, v256i64, "VDIVSL", i32, v256i32, "VDIVSWSX">;
346
355
defm : Binary_ShortLong<vvp_udiv, i64, v256i64, "VDIVUL", i32, v256i32, "VDIVUW">;
347
356
348
- defm : Binary_vr_vv_ShortLong<vvp_srl, i64, v256i64, "VSRL", i32, v256i32, "PVSRLLO">;
349
- defm : Binary_vr_vv_ShortLong<vvp_sra, i64, v256i64, "VSRAL", i32, v256i32, "PVSRALO">;
350
- defm : Binary_vr_vv_ShortLong<vvp_shl, i64, v256i64, "VSLL", i32, v256i32, "PVSLLLO">;
357
+ defm : Binary_vr_vv_ShortLong<vvp_shl,
358
+ i64, v256i64, "VSLL",
359
+ i32, v256i32, "PVSLLLO">;
360
+ defm : Binary_vr_vv_ShortLong<vvp_sra,
361
+ i64, v256i64, "VSRAL",
362
+ i32, v256i32, "PVSRALO">;
363
+ defm : Binary_vr_vv_ShortLong<vvp_srl,
364
+ i64, v256i64, "VSRL",
365
+ i32, v256i32, "PVSRLLO">;
351
366
352
367
// Floating-point arithmetic (256 elements)
353
368
defm : Unary_ShortLong<vvp_frcp, f64, v256f64, "VRCPD", f32, v256f32, "VRCPS">;
0 commit comments