BC_CTRTEST = 0 # CTR-test mode
# reduce mode
REDUCE = 2 # 0=normal predication 1=reduce mode
- PARALLEL = 3 # 1=parallel reduce, 0=scalar reduce
+ PTREDUCE = 3 # 1=parallel reduce, 0=scalar reduce
SVM = 3 # subvector reduce mode 0=independent 1=horizontal
CRM = 4 # CR mode on reduce (Rc=1) 0=some 1=all
RG = 4 # Reverse-gear on reduce
comb += self.mode.eq(SVP64RMMode.NORMAL)
comb += do_pu.eq(mode[SVP64MODE.LDST_PACK]) # Pack mode
with m.Elif(mode[SVP64MODE.REDUCE]):
- with m.If(mode[SVP64MODE.PARALLEL]):
- comb += self.mode.eq(SVP64RMMode.PARALLEL)
+ with m.If(mode[SVP64MODE.PTREDUCE]):
+ comb += self.mode.eq(SVP64RMMode.PTREDUCE)
with m.Else():
comb += self.mode.eq(SVP64RMMode.MAPREDUCE)
# Pack only active if SVM=1 & SUBVL>1 & Mode[4]=1
with m.If((~is_ldst) & # not for LD/ST
(mode2 == 0) & # first 2 bits == 0
mode[SVP64MODE.REDUCE] & # bit 2 == 1
- (~mode[SVP64MODE.PARALLEL])): # not parallel mapreduce
+ (~mode[SVP64MODE.PTREDUCE])): # not parallel mapreduce
comb += self.reverse_gear.eq(mode[SVP64MODE.RG]) # finally whew
# extract zeroing
# "mapreduce" modes
elif sv_mode == 0b00:
if parallel:
- mode |= (0b1 << SVP64MODE.PARALLEL) # sets parallel reduce
+ mode |= (0b1 << SVP64MODE.PTREDUCE) # sets parallel reduce
assert subvl == 0, "TODO sub-vector parallel reduce"
else:
mode |= (0b1 << SVP64MODE.REDUCE) # sets mapreduce