1
0

Merge pull request #791 from freechipsproject/tlb

Fix I$ reset regression
This commit is contained in:
Andrew Waterman 2017-06-09 15:49:25 -07:00 committed by GitHub
commit e69badb205
2 changed files with 3 additions and 3 deletions

@ -1 +1 @@
Subproject commit 21113949ff22bd45c6d5928f7b6214c7e0a88bde
Subproject commit 88dd92a8000aa408c047367e424b8829d0872740

View File

@ -77,7 +77,7 @@ class FrontendModule(outer: Frontend) extends LazyModuleImp(outer)
val s0_valid = io.cpu.req.valid || !fq.io.mask(fq.io.mask.getWidth-2)
val s1_pc = Reg(UInt(width=vaddrBitsExtended))
val s1_speculative = Reg(Bool())
val s2_valid = Reg(init=Bool(true))
val s2_valid = RegInit(false.B)
val s2_pc = Reg(init=io.resetVector)
val s2_btb_resp_valid = Reg(init=Bool(false))
val s2_btb_resp_bits = Reg(new BTBResp)
@ -96,7 +96,7 @@ class FrontendModule(outer: Frontend) extends LazyModuleImp(outer)
val predicted_taken = Wire(init = Bool(false))
val s2_replay = Wire(Bool())
s2_replay := (s2_valid && !fq.io.enq.fire()) || RegNext(s2_replay && !s0_valid)
s2_replay := (s2_valid && !fq.io.enq.fire()) || RegNext(s2_replay && !s0_valid, true.B)
val npc = Mux(s2_replay, s2_pc, predicted_npc)
s1_pc := io.cpu.npc