You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
valisHit= checkIfHit(validAndDirtyBits2._1, validAndDirtyBits2._3, tagReg) // Long combinational path // TODO: Move one pipeline register back instead
157
-
158
-
updateStageIndex := indexReg
159
-
updateStageTag := tagReg
160
-
updateStageValid := reqValidReg
161
-
updateStageIsHit := isHit._1
167
+
valisHalfMissInUpdateStage= isHalfMissReg &&!(!halfMissInCritReg && io.repPol.updateCoreReachedLimit) // If the core has reached limit and there is already a request in the non-critical q then we turn it into a full new request
io.missFifoPush.updateByteEn := (isHalfMissReg&& reqValidReg &&!isHit._1 && reqRwReg &&!io.stall) // Update a byte mask if it is a write request and a half miss
212
+
io.missFifoPush.updateByteEn := (isHalfMissInUpdateStage&& reqValidReg &&!isHit._1 && reqRwReg &&!io.stall) // Update a byte mask if it is a write request and a half miss
207
213
io.missFifoPush.updateByteEnVal := byteEnReg
208
214
io.missFifoPush.updateByteEnCol := blockOffsetReg
209
215
io.missFifoPush.updateByteEnRow := halfMissIdxReg
@@ -233,7 +239,7 @@ class Rep(nCores: Int, nSets: Int, nWays: Int, nMshrs: Int, reqIdWidth: Int, tag
io.read.repWay :=Mux(isHalfMissReg, Mux(halfMissInCritReg, io.missCritInfo.replacementWays(halfMissIdxReg), io.missNonCritInfo.replacementWays(halfMissIdxReg)), repWay) // If it is a half miss we give the replacement way of the full miss for a write request
242
+
io.read.repWay :=Mux(isHalfMissInUpdateStage, Mux(halfMissInCritReg, io.missCritInfo.replacementWays(halfMissIdxReg), io.missNonCritInfo.replacementWays(halfMissIdxReg)), repWay) // If it is a half miss we give the replacement way of the full miss for a write request
237
243
io.read.isHit := isHit._1
238
244
io.read.hitWay := isHit._2
239
245
io.read.isRepDirty := isRepDirty
@@ -251,15 +257,22 @@ class Rep(nCores: Int, nSets: Int, nWays: Int, nMshrs: Int, reqIdWidth: Int, tag
Copy file name to clipboardExpand all lines: src/test/scala/caches/hardware/pipelined/cache/SharedPipelinedCacheTest.scala
+7-2Lines changed: 7 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -26,6 +26,8 @@ case class CacheRequest(
26
26
expectedData: Option[String] =None
27
27
) extendsTestAction
28
28
29
+
// TODO: Should add an optional parameter that says that a response for a request should be received after a response to some other request has been received
CacheRequest(coreId =3, reqId =13, tag =39, index =74, blockOffset =3, rw =false, expectedData =Some("b638aaa4ef343eee6a4757cb65a2f78c")), // MISS, way: 3, contention event, critical wb, reach contention limit for core 1
380
382
CacheRequest(coreId =1, reqId =14, tag =57, index =74, blockOffset =2, rw =false, expectedData =Some("26f4756810b9c7b7fc87a234ac62fee6")), // MISS, way: 2,
381
383
CacheRequest(coreId =2, reqId =15, tag =41, index =74, blockOffset =1, rw =false, expectedData =Some("8f2a3009871c1b8fb22ed80f63229d0f")), // MISS, way: 3,
382
-
CacheRequest(coreId =0, reqId =16, tag =8, index =74, blockOffset =0, rw =false, expectedData =Some("e83fb23952953ff164bdb8d5685d2bd3"), rejected =true), // MISS, way: rejected
384
+
CacheRequest(coreId =0, reqId =16, tag =41, index =72, blockOffset =1, rw =false, expectedData =Some("abbd90af6dbb29366ec5bd141df45023")), // MISS, way: 0,
385
+
CacheRequest(coreId =1, reqId =17, tag =41, index =72, blockOffset =0, rw =false, expectedData =Some("a64a45812e63b4001eafac68edee5dd6")), // MISS, way: 1, not a half-miss since the core reached contention limit
386
+
CacheRequest(coreId =2, reqId =18, tag =41, index =72, blockOffset =2, rw =false, expectedData =Some("b1a10cf29e0b684ae2dd8277b34d19f1")), // MISS, way: 2, not a half-miss since the core reached contention limit
387
+
CacheRequest(coreId =0, reqId =19, tag =8, index =74, blockOffset =0, rw =false, expectedData =Some("e83fb23952953ff164bdb8d5685d2bd3"), rejected =true), // MISS, way: rejected
0 commit comments