提交 076dea5f 编写于 作者: J Jenius 提交者: Lingrui98

<bug-fix> IFU: fix f3_lastHalf cancel condition

* Under the circumstance that 2 continuous ftq reqs both have last half
RVI, but the f3_lastHalf.valid cancel condition in wb-stage is set by
!f3_lastHalf.valid, which makes the miss pred f3_lastHalf req has not
been flushed.
上级 32104dbb
......@@ -683,17 +683,15 @@ class NewIFU(implicit p: Parameters) extends XSModule
* we set a flag to notify f3 that the last half flag need not to be set.
*/
//f3_fire is after wb_valid
when(wb_valid && RegNext(f3_hasLastHalf)
&& wb_check_result_stage2.fixedMissPred(PredictWidth - 1)
&& !f3_lastHalf.valid && !f3_fire
when(wb_valid && RegNext(f3_hasLastHalf,init = false.B)
&& wb_check_result_stage2.fixedMissPred(PredictWidth - 1) && !f3_fire && !RegNext(f3_fire,init = false.B)
){
f3_lastHalf_disable := true.B
}
//wb_valid and f3_fire are in same cycle
when(wb_valid && RegNext(f3_hasLastHalf)
&& wb_check_result_stage2.fixedMissPred(PredictWidth - 1)
&& !f3_lastHalf.valid && f3_fire
when(wb_valid && RegNext(f3_hasLastHalf,init = false.B)
&& wb_check_result_stage2.fixedMissPred(PredictWidth - 1) && f3_fire
){
f3_lastHalf.valid := false.B
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册