File tree 5 files changed +8
-6
lines changed
5 files changed +8
-6
lines changed Original file line number Diff line number Diff line change @@ -182,6 +182,7 @@ class MSHRInfo(implicit p: Parameters) extends L2Bundle {
182
182
val s_refill = Bool ()
183
183
val param = UInt (3 .W )
184
184
val mergeA = Bool () // whether the mshr already merge an acquire(avoid alias merge)
185
+ val w_releaseack = Bool ()
185
186
}
186
187
187
188
class RespInfoBundle (implicit p : Parameters ) extends L2Bundle {
Original file line number Diff line number Diff line change @@ -125,7 +125,7 @@ class MSHR(implicit p: Parameters) extends L2Module {
125
125
oa.off := req.off
126
126
oa.source := io.id
127
127
oa.opcode := Mux (
128
- req_acquirePerm,
128
+ req_acquirePerm && dirResult.hit ,
129
129
req.opcode,
130
130
// Get or AcquireBlock
131
131
AcquireBlock
@@ -541,6 +541,7 @@ class MSHR(implicit p: Parameters) extends L2Module {
541
541
io.msInfo.bits.s_refill := state.s_refill
542
542
io.msInfo.bits.param := req.param
543
543
io.msInfo.bits.mergeA := mergeA
544
+ io.msInfo.bits.w_releaseack := state.w_releaseack
544
545
545
546
assert(! (c_resp.valid && ! io.status.bits.w_c_resp))
546
547
assert(! (d_resp.valid && ! io.status.bits.w_d_resp))
Original file line number Diff line number Diff line change @@ -178,7 +178,7 @@ class MainPipe(implicit p: Parameters) extends L2Module {
178
178
val need_mshr_s3_a = need_acquire_s3_a || need_probe_s3_a || cache_alias
179
179
// For channel B reqs, alloc mshr when Probe hits in both self and client dir
180
180
val need_mshr_s3_b = dirResult_s3.hit && req_s3.fromB &&
181
- ! (meta_s3.state === BRANCH && req_s3.param === toB) &&
181
+ ! (( meta_s3.state === BRANCH || meta_s3.state === TIP ) && req_s3.param === toB) &&
182
182
meta_has_clients_s3
183
183
184
184
// For channel C reqs, Release will always hit on MainPipe, no need for MSHR
Original file line number Diff line number Diff line change @@ -74,9 +74,9 @@ class SinkB(implicit p: Parameters) extends L2Module {
74
74
s.valid && s.bits.set === task.set && s.bits.reqTag === task.tag && ! s.bits.willFree && ! s.bits.nestB
75
75
)).asUInt.orR
76
76
77
- // unable to accept incoming B req because same-addr as some MSHR replaced block and cannot nest
77
+ // unable to accept incoming B req because same-addr Release to L3 and have not received ReleaseAck, and some MSHR replaced block and cannot nest
78
78
val replaceConflictMask = VecInit (io.msInfo.map(s =>
79
- s.valid && s.bits.set === task.set && s.bits.metaTag === task.tag && s.bits.blockRefill
79
+ s.valid && s.bits.set === task.set && s.bits.metaTag === task.tag && s.bits.blockRefill && ! s.bits.w_releaseack
80
80
)).asUInt
81
81
val replaceConflict = replaceConflictMask.orR
82
82
Original file line number Diff line number Diff line change @@ -50,10 +50,10 @@ class SinkC(implicit p: Parameters) extends L2Module {
50
50
51
51
// dataBuf entry is valid when Release has data
52
52
// taskBuf entry is valid when ReqArb is not ready to receive C tasks
53
- val dataBuf = Reg ( Vec ( bufBlocks, Vec ( beatSize, UInt ((beatBytes * 8 ).W ))))
53
+ val dataBuf = RegInit ( VecInit ( Seq .fill( bufBlocks)( VecInit ( Seq .fill( beatSize)( 0 . U .asTypeOf( UInt ((beatBytes * 8 ).W ))) ))))
54
54
val beatValids = RegInit (VecInit (Seq .fill(bufBlocks)(VecInit (Seq .fill(beatSize)(false .B )))))
55
55
val dataValids = VecInit (beatValids.map(_.asUInt.orR)).asUInt
56
- val taskBuf = Reg ( Vec ( bufBlocks, new TaskBundle ))
56
+ val taskBuf = RegInit ( VecInit ( Seq .fill( bufBlocks)( 0 . U .asTypeOf( new TaskBundle )) ))
57
57
val taskValids = RegInit (VecInit (Seq .fill(bufBlocks)(false .B )))
58
58
val taskArb = Module (new RRArbiter (new TaskBundle , bufBlocks))
59
59
val bufValids = taskValids.asUInt | dataValids
You can’t perform that action at this time.
0 commit comments