Add prefetching rocket example config
This commit is contained in:
@@ -153,7 +153,7 @@ lazy val chipyard = (project in file("generators/chipyard"))
|
||||
sha3, // On separate line to allow for cleaner tutorial-setup patches
|
||||
dsptools, `rocket-dsp-utils`,
|
||||
gemmini, icenet, tracegen, cva6, nvdla, sodor, ibex, fft_generator,
|
||||
constellation, mempress)
|
||||
constellation, mempress, barf)
|
||||
.settings(libraryDependencies ++= rocketLibDeps.value)
|
||||
.settings(
|
||||
libraryDependencies ++= Seq(
|
||||
@@ -168,6 +168,11 @@ lazy val mempress = (project in file("generators/mempress"))
|
||||
.settings(chiselTestSettings)
|
||||
.settings(commonSettings)
|
||||
|
||||
lazy val barf = (project in file("generators/bar-fetchers"))
|
||||
.dependsOn(rocketchip)
|
||||
.settings(libraryDependencies ++= rocketLibDeps.value)
|
||||
.settings(commonSettings)
|
||||
|
||||
lazy val constellation = (project in file("generators/constellation"))
|
||||
.dependsOn(rocketchip)
|
||||
.settings(libraryDependencies ++= rocketLibDeps.value)
|
||||
|
||||
@@ -126,3 +126,11 @@ class CustomIOChipTopRocketConfig extends Config(
|
||||
new chipyard.example.WithCustomIOCells ++
|
||||
new freechips.rocketchip.subsystem.WithNBigCores(1) ++ // single rocket-core
|
||||
new chipyard.config.AbstractConfig)
|
||||
|
||||
class PrefetchingRocketConfig extends Config(
|
||||
new barf.WithHellaCachePrefetcher(Seq(0), barf.SingleStridedPrefetcherParams()) ++ // strided prefetcher into L1D$
|
||||
new barf.WithTLICachePrefetcher(barf.MultiNextLinePrefetcherParams()) ++ // next-line prefetcher into L2 for L1I$ accesses
|
||||
new barf.WithTLDCachePrefetcher(barf.SingleAMPMPrefetcherParams()) ++ // AMPM prefetcher into L2 for L1D$ accesses
|
||||
new chipyard.config.WithTilePrefetchers ++ // add TL prefetchers between tiles and the sbus
|
||||
new freechips.rocketchip.subsystem.WithNBigCores(1) ++ // single rocket-core
|
||||
new chipyard.config.AbstractConfig)
|
||||
|
||||
@@ -9,7 +9,10 @@ import freechips.rocketchip.rocket.{RocketCoreParams, MulDivParams, DCacheParams
|
||||
|
||||
import boom.common.{BoomTileAttachParams}
|
||||
import cva6.{CVA6TileAttachParams}
|
||||
import sodor.common.{SodorTileAttachParams}
|
||||
import ibex.{IbexTileAttachParams}
|
||||
import testchipip._
|
||||
import barf.{TilePrefetchingMasterPortParams}
|
||||
|
||||
class WithL2TLBs(entries: Int) extends Config((site, here, up) => {
|
||||
case TilesLocated(InSubsystem) => up(TilesLocated(InSubsystem), site) map {
|
||||
@@ -79,3 +82,17 @@ class WithRocketDCacheScratchpad extends Config((site, here, up) => {
|
||||
}
|
||||
})
|
||||
|
||||
class WithTilePrefetchers extends Config((site, here, up) => {
|
||||
case TilesLocated(InSubsystem) => up(TilesLocated(InSubsystem), site) map {
|
||||
case tp: RocketTileAttachParams => tp.copy(crossingParams = tp.crossingParams.copy(
|
||||
master = TilePrefetchingMasterPortParams(tp.tileParams.hartId, tp.crossingParams.master)))
|
||||
case tp: BoomTileAttachParams => tp.copy(crossingParams = tp.crossingParams.copy(
|
||||
master = TilePrefetchingMasterPortParams(tp.tileParams.hartId, tp.crossingParams.master)))
|
||||
case tp: SodorTileAttachParams => tp.copy(crossingParams = tp.crossingParams.copy(
|
||||
master = TilePrefetchingMasterPortParams(tp.tileParams.hartId, tp.crossingParams.master)))
|
||||
case tp: IbexTileAttachParams => tp.copy(crossingParams = tp.crossingParams.copy(
|
||||
master = TilePrefetchingMasterPortParams(tp.tileParams.hartId, tp.crossingParams.master)))
|
||||
case tp: CVA6TileAttachParams => tp.copy(crossingParams = tp.crossingParams.copy(
|
||||
master = TilePrefetchingMasterPortParams(tp.tileParams.hartId, tp.crossingParams.master)))
|
||||
}
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user