yield from super().specifiers(record=record)
+class ZZCombinedBaseRM(BaseRM):
+ def specifiers(self, record):
+ if self.sz and self.dz:
+ yield "zz"
+ elif self.sz:
+ yield "sz"
+ elif self.dz:
+ yield "dz"
+
+ yield from super().specifiers(record=record)
+
+
class DZBaseRM(BaseRM):
def specifiers(self, record):
if self.dz:
pass
-class NormalSimpleRM(DZBaseRM, SZBaseRM, NormalBaseRM):
+class NormalSimpleRM(ZZCombinedBaseRM, NormalBaseRM):
"""normal: simple mode"""
dz: BaseRM.mode[3]
sz: BaseRM.mode[4]
yield from super().specifiers(record=record, mode="ff")
-class NormalSatRM(SatBaseRM, DZBaseRM, SZBaseRM, NormalBaseRM):
+class NormalSatRM(SatBaseRM, ZZCombinedBaseRM, NormalBaseRM):
"""normal: sat mode: N=0/1 u/s, SUBVL=1"""
N: BaseRM.mode[2]
dz: BaseRM.mode[3]
pass
-class LDSTIdxSimpleRM(SEABaseRM, DZBaseRM, SZBaseRM, LDSTIdxBaseRM):
+class LDSTIdxSimpleRM(SEABaseRM, ZZCombinedBaseRM, LDSTIdxBaseRM):
"""ld/st index: simple mode"""
SEA: BaseRM.mode[2]
dz: BaseRM.mode[3]
sz: BaseRM.mode[4]
-class LDSTIdxStrideRM(SEABaseRM, DZBaseRM, SZBaseRM, LDSTIdxBaseRM):
+class LDSTIdxStrideRM(SEABaseRM, ZZCombinedBaseRM, LDSTIdxBaseRM):
"""ld/st index: strided (scalar only source)"""
SEA: BaseRM.mode[2]
dz: BaseRM.mode[3]
yield from super().specifiers(record=record)
-class LDSTIdxSatRM(SatBaseRM, DZBaseRM, SZBaseRM, LDSTIdxBaseRM):
+class LDSTIdxSatRM(SatBaseRM, ZZCombinedBaseRM, LDSTIdxBaseRM):
"""ld/st index: sat mode: N=0/1 u/s"""
N: BaseRM.mode[2]
dz: BaseRM.mode[3]
SNZ: BaseRM[7]
-class CROpSimpleRM(PredicateBaseRM, DZBaseRM, SZBaseRM, CROpBaseRM):
+class CROpSimpleRM(PredicateBaseRM, ZZCombinedBaseRM, CROpBaseRM):
"""cr_op: simple mode"""
RG: BaseRM[20]
dz: BaseRM[22]
yield from super().specifiers(record=record)
-class CROpMRRM(MRBaseRM, DZBaseRM, SZBaseRM, CROpBaseRM):
+class CROpMRRM(MRBaseRM, ZZCombinedBaseRM, CROpBaseRM):
"""cr_op: scalar reduce mode (mapreduce), SUBVL=1"""
RG: BaseRM[20]
dz: BaseRM[22]
class CROpFF5RM(FFPRRc0BaseRM, PredicateBaseRM,
- VLiBaseRM, DZBaseRM, SZBaseRM, CROpBaseRM):
+ VLiBaseRM, ZZCombinedBaseRM, CROpBaseRM):
"""cr_op: ffirst 5-bit mode"""
VLi: BaseRM[20]
inv: BaseRM[21]