提交 5b8f22af 编写于 作者: L Lingrui98

ftq: fix a bug modifying target when mispred @ljwljwljwljw

上级 bfe7a5d1
......@@ -122,7 +122,7 @@ class Ftq extends XSModule with HasCircularQueuePtrHelper {
val lastIsMispredict = RegNext(
io.redirect.valid && io.redirect.bits.level === RedirectLevel.flushAfter, init = false.B
)
when(io.frontendRedirect.valid && !lastIsMispredict) {
when(io.frontendRedirect.valid && lastIsMispredict) {
target_vec(io.frontendRedirect.bits.ftqIdx.value) := io.frontendRedirect.bits.cfiUpdate.target
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册