@@ -4567,7 +4567,8 @@ multiclass VPatUnaryS_M<string intrinsic_name,
4567
4567
multiclass VPatUnaryV_V_AnyMask<string intrinsic, string instruction,
4568
4568
list<VTypeInfo> vtilist> {
4569
4569
foreach vti = vtilist in {
4570
- let Predicates = GetVTypeMinimalPredicates<vti>.Predicates in
4570
+ defvar ivti = GetIntVTypeInfo<vti>.Vti;
4571
+ let Predicates = GetVTypePredicates<ivti>.Predicates in
4571
4572
def : VPatUnaryAnyMask<intrinsic, instruction, "VM",
4572
4573
vti.Vector, vti.Vector, vti.Mask,
4573
4574
vti.Log2SEW, vti.LMul, vti.RegClass, vti.RegClass>;
@@ -4886,7 +4887,7 @@ multiclass VPatBinaryV_VV_INT<string intrinsic, string instruction,
4886
4887
list<VTypeInfo> vtilist> {
4887
4888
foreach vti = vtilist in {
4888
4889
defvar ivti = GetIntVTypeInfo<vti>.Vti;
4889
- let Predicates = GetVTypeMinimalPredicates<vti >.Predicates in
4890
+ let Predicates = GetVTypePredicates<ivti >.Predicates in
4890
4891
defm : VPatBinary<intrinsic,
4891
4892
instruction # "_VV_" # vti.LMul.MX # "_E" # vti.SEW,
4892
4893
vti.Vector, vti.Vector, ivti.Vector, vti.Mask,
@@ -4903,15 +4904,16 @@ multiclass VPatBinaryV_VV_INT_EEW<string intrinsic, string instruction,
4903
4904
defvar octuple_lmul = vlmul.octuple;
4904
4905
defvar octuple_emul = !srl(!mul(octuple_lmul, eew), vti.Log2SEW);
4905
4906
if !and(!ge(octuple_emul, 1), !le(octuple_emul, 64)) then {
4907
+ defvar ivti = GetIntVTypeInfo<vti>.Vti;
4906
4908
defvar emul_str = octuple_to_str<octuple_emul>.ret;
4907
- defvar ivti = !cast<VTypeInfo>("VI" # eew # emul_str);
4908
4909
defvar inst = instruction # "_VV_" # vti.LMul.MX # "_E" # vti.SEW # "_" # emul_str;
4909
- let Predicates = !listconcat(GetVTypeMinimalPredicates<vti>.Predicates,
4910
- GetVTypeMinimalPredicates<ivti>.Predicates) in
4910
+ defvar eivti = !cast<VTypeInfo>("VI" # eew # emul_str);
4911
+ let Predicates = !listconcat(GetVTypePredicates<ivti>.Predicates,
4912
+ GetVTypePredicates<eivti>.Predicates) in
4911
4913
defm : VPatBinary<intrinsic, inst,
4912
- vti.Vector, vti.Vector, ivti .Vector, vti.Mask,
4914
+ vti.Vector, vti.Vector, eivti .Vector, vti.Mask,
4913
4915
vti.Log2SEW, vti.RegClass,
4914
- vti.RegClass, ivti .RegClass>;
4916
+ vti.RegClass, eivti .RegClass>;
4915
4917
}
4916
4918
}
4917
4919
}
@@ -4948,12 +4950,14 @@ multiclass VPatBinaryV_VX_RM<string intrinsic, string instruction,
4948
4950
4949
4951
multiclass VPatBinaryV_VX_INT<string intrinsic, string instruction,
4950
4952
list<VTypeInfo> vtilist> {
4951
- foreach vti = vtilist in
4952
- let Predicates = GetVTypeMinimalPredicates<vti>.Predicates in
4953
+ foreach vti = vtilist in {
4954
+ defvar ivti = GetIntVTypeInfo<vti>.Vti;
4955
+ let Predicates = GetVTypePredicates<ivti>.Predicates in
4953
4956
defm : VPatBinary<intrinsic, instruction # "_VX_" # vti.LMul.MX,
4954
4957
vti.Vector, vti.Vector, XLenVT, vti.Mask,
4955
4958
vti.Log2SEW, vti.RegClass,
4956
4959
vti.RegClass, GPR>;
4960
+ }
4957
4961
}
4958
4962
4959
4963
multiclass VPatBinaryV_VI<string intrinsic, string instruction,
@@ -4980,12 +4984,14 @@ multiclass VPatBinaryV_VI_RM<string intrinsic, string instruction,
4980
4984
4981
4985
multiclass VPatBinaryV_VI_INT<string intrinsic, string instruction,
4982
4986
list<VTypeInfo> vtilist, Operand imm_type> {
4983
- foreach vti = vtilist in
4984
- let Predicates = GetVTypeMinimalPredicates<vti>.Predicates in
4987
+ foreach vti = vtilist in {
4988
+ defvar ivti = GetIntVTypeInfo<vti>.Vti;
4989
+ let Predicates = GetVTypePredicates<ivti>.Predicates in
4985
4990
defm : VPatBinary<intrinsic, instruction # "_VI_" # vti.LMul.MX,
4986
4991
vti.Vector, vti.Vector, XLenVT, vti.Mask,
4987
4992
vti.Log2SEW, vti.RegClass,
4988
4993
vti.RegClass, imm_type>;
4994
+ }
4989
4995
}
4990
4996
4991
4997
multiclass VPatBinaryM_MM<string intrinsic, string instruction> {
@@ -5573,12 +5579,14 @@ multiclass VPatTernaryV_VV_AAXA_RM<string intrinsic, string instruction,
5573
5579
5574
5580
multiclass VPatTernaryV_VX<string intrinsic, string instruction,
5575
5581
list<VTypeInfo> vtilist> {
5576
- foreach vti = vtilist in
5577
- let Predicates = GetVTypeMinimalPredicates<vti>.Predicates in
5582
+ foreach vti = vtilist in {
5583
+ defvar ivti = GetIntVTypeInfo<vti>.Vti;
5584
+ let Predicates = GetVTypePredicates<ivti>.Predicates in
5578
5585
defm : VPatTernaryWithPolicy<intrinsic, instruction, "VX",
5579
5586
vti.Vector, vti.Vector, XLenVT, vti.Mask,
5580
5587
vti.Log2SEW, vti.LMul, vti.RegClass,
5581
5588
vti.RegClass, GPR>;
5589
+ }
5582
5590
}
5583
5591
5584
5592
multiclass VPatTernaryV_VX_AAXA<string intrinsic, string instruction,
@@ -5605,12 +5613,14 @@ multiclass VPatTernaryV_VX_AAXA_RM<string intrinsic, string instruction,
5605
5613
5606
5614
multiclass VPatTernaryV_VI<string intrinsic, string instruction,
5607
5615
list<VTypeInfo> vtilist, Operand Imm_type> {
5608
- foreach vti = vtilist in
5609
- let Predicates = GetVTypeMinimalPredicates<vti>.Predicates in
5616
+ foreach vti = vtilist in {
5617
+ defvar ivti = GetIntVTypeInfo<vti>.Vti;
5618
+ let Predicates = GetVTypePredicates<ivti>.Predicates in
5610
5619
defm : VPatTernaryWithPolicy<intrinsic, instruction, "VI",
5611
5620
vti.Vector, vti.Vector, XLenVT, vti.Mask,
5612
5621
vti.Log2SEW, vti.LMul, vti.RegClass,
5613
5622
vti.RegClass, Imm_type>;
5623
+ }
5614
5624
}
5615
5625
5616
5626
multiclass VPatTernaryW_VV<string intrinsic, string instruction,
0 commit comments