Skip to content

Commit d06df5f

Browse files
committed
Revert "fix: fix channel_C assert bug"
This reverts commit a2f630b.
1 parent 488d092 commit d06df5f

1 file changed

Lines changed: 3 additions & 28 deletions

File tree

src/main/scala/coupledL2/debug/Monitor.scala

Lines changed: 3 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -66,34 +66,9 @@ class Monitor(implicit p: Parameters) extends L2Module {
6666
meta_s3.state === TRUNK && !meta_s3.clients.orR)),
6767
"Trunk should have some client hit")
6868

69-
val rel_hit_no_client_s3 = s3_valid && !mshr_req_s3 && req_s3.fromC && dirResult_s3.hit && !meta_s3.clients.orR
70-
val rel_hit_no_client_s4 = RegNext(rel_hit_no_client_s3, false.B)
71-
val req_s3_r = RegEnable(req_s3, 0.U.asTypeOf(req_s3), s3_valid)
72-
val meta_s3_r = RegEnable(meta_s3, 0.U.asTypeOf(meta_s3), s3_valid)
73-
val hit_s3_r = RegEnable(dirResult_s3.hit, false.B, s3_valid)
74-
75-
val metaW_same_set_s3 = mp.metaW_s3.valid && mp.metaW_s3.bits.set === req_s3.set
76-
val metaW_same_way_s3 = metaW_same_set_s3 && mp.metaW_s3.bits.wayOH(dirResult_s3.way)
77-
val metaW_same_line_s4 = RegNext(metaW_same_way_s3, false.B)
78-
val metaW_clients_s4 = RegEnable(mp.metaW_s3.bits.wmeta.clients, 0.U(clientBits.W), mp.metaW_s3.valid)
79-
val metaW_state_s4 = RegEnable(mp.metaW_s3.bits.wmeta.state, 0.U(2.W), mp.metaW_s3.valid)
80-
val rel_hit_no_client_hard_s4 = rel_hit_no_client_s4 && !metaW_same_line_s4
81-
val rel_hit_no_client_transient_s4 = rel_hit_no_client_s4 && metaW_same_line_s4
82-
83-
assert(!rel_hit_no_client_hard_s4,
84-
"Invalid Client should not send Release (hard): tag=%x set=%x op=%x param=%x hit=%d state=%d clients=%x metaW_same_line=%d metaW_state=%d metaW_clients=%x",
85-
req_s3_r.tag, req_s3_r.set, req_s3_r.opcode, req_s3_r.param,
86-
hit_s3_r, meta_s3_r.state, meta_s3_r.clients,
87-
metaW_same_line_s4, metaW_state_s4, metaW_clients_s4)
88-
89-
XSPerfAccumulate("release_hit_no_client_hard", rel_hit_no_client_hard_s4)
90-
XSPerfAccumulate("release_hit_no_client_transient", rel_hit_no_client_transient_s4)
91-
when (rel_hit_no_client_transient_s4) {
92-
printf("[L2 Monitor transient] Release hit with no client: tag=%x set=%x op=%x param=%x hit=%d state=%d clients=%x metaW_state=%d metaW_clients=%x\n",
93-
req_s3_r.tag, req_s3_r.set, req_s3_r.opcode, req_s3_r.param,
94-
hit_s3_r, meta_s3_r.state, meta_s3_r.clients,
95-
metaW_state_s4, metaW_clients_s4)
96-
}
69+
assert(RegNext(!(s3_valid && req_s3.fromC && dirResult_s3.hit &&
70+
!meta_s3.clients.orR)),
71+
"Invalid Client should not send Release")
9772

9873
// assertion for set blocking
9974
// A channel task @s1 never have same-set task @s2/s3

0 commit comments

Comments
 (0)