提交 71e28975 编写于 作者: Z zoujr

BPU: add false_hit and new_br_insert_pos in bpu update interface

上级 4ed595da
......@@ -89,7 +89,8 @@ class BIM(implicit p: Parameters) extends BasePredictor with BimParams with BPUU
satUpdate(oldCtrs(i), 2, newTakens(i))
))
val need_to_update = VecInit((0 until numBr).map(i => u_valid && update.preds.is_br(i)))
val update_mask = LowerMask(PriorityEncoderOH(update.preds.taken_mask.asUInt))
val need_to_update = VecInit((0 until numBr).map(i => u_valid && update.preds.is_br(i) && update_mask(i)))
when (reset.asBool) { wrbypass_ctr_valids.foreach(_ := VecInit(Seq.fill(numBr)(false.B)))}
......
......@@ -163,7 +163,7 @@ class FTB(implicit p: Parameters) extends BasePredictor with FTBParams {
}
val s1_latch_is_br = ftb_entry.brValids
val s1_latch_is_jal = ftb_entry.jmpValid && !(ftb_entry.isJalr || ftb_entry.isCall ||ftb_entry.isRet)
val s1_latch_is_jal = ftb_entry.jmpValid && !ftb_entry.isJalr
val s1_latch_is_jalr = ftb_entry.isJalr
val s1_latch_is_call = ftb_entry.isCall
val s1_latch_is_ret = ftb_entry.isRet
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册