Merge pull request #1603 from ucb-bar/jerryz123-patch-3

Add NarrowRocketCache config fragment
This commit is contained in:
Jerry Zhao
2023-10-31 14:48:48 -07:00
committed by GitHub

View File

@@ -66,6 +66,15 @@ class WithNPMPs(n: Int = 8) extends Config((site, here, up) => {
}
})
class WithRocketCacheRowBits(rowBits: Int = 64) extends Config((site, here, up) => {
case TilesLocated(InSubsystem) => up(TilesLocated(InSubsystem)) map {
case tp: RocketTileAttachParams => tp.copy(tileParams = tp.tileParams.copy(
dcache = tp.tileParams.dcache.map(_.copy(rowBits = rowBits)),
icache = tp.tileParams.icache.map(_.copy(rowBits = rowBits))
))
}
})
class WithRocketICacheScratchpad extends Config((site, here, up) => {
case TilesLocated(InSubsystem) => up(TilesLocated(InSubsystem), site) map {
case tp: RocketTileAttachParams => tp.copy(tileParams = tp.tileParams.copy(