Merge branch 'main' of https://github.com/hansungk/radiance into main
This commit is contained in:
Submodule src/main/resources/vsrc/vortex updated: 60d4180249...4643edf3e9
@@ -22,56 +22,57 @@ trait CanHaveMemtraceCore { this: BaseSubsystem =>
|
||||
)
|
||||
val numLanes = simtParam.nLanes
|
||||
val filename = param.tracefilename
|
||||
val tracer = LazyModule(
|
||||
new MemTraceDriver(config, filename, param.traceHasSource)(p)
|
||||
)
|
||||
val coreSideLogger = LazyModule(
|
||||
new MemTraceLogger(numLanes, filename, loggerName = "coreside")
|
||||
)
|
||||
val memSideLogger = LazyModule(
|
||||
new MemTraceLogger(numLanes + 1, filename, loggerName = "memside")
|
||||
)
|
||||
// Must use :=* to ensure the N edges from Tracer doesn't get merged into 1
|
||||
// when connecting to SBus
|
||||
println(
|
||||
s"============ MemTraceDriver instantiated [filename=${param.tracefilename}]"
|
||||
)
|
||||
val coalescerNode = p(CoalescerKey) match {
|
||||
case Some(coalParam) => {
|
||||
val coal = LazyModule(new CoalescingUnit(coalParam))
|
||||
coal.cpuNode :=* coreSideLogger.node :=* tracer.node // N lanes
|
||||
memSideLogger.node :=* coal.aggregateNode // N+1 lanes
|
||||
memSideLogger.node
|
||||
}
|
||||
case None => tracer.node
|
||||
}
|
||||
val coalXbar = p(CoalXbarKey) match {
|
||||
case Some(xbarParam) =>{
|
||||
val coXbar = LazyModule(new TLXbar)
|
||||
println(s"============ Using TLXBar for Coalescer Requests ")
|
||||
coXbar.node :=* coalescerNode
|
||||
coXbar.node
|
||||
}
|
||||
case None => coalescerNode
|
||||
}
|
||||
|
||||
|
||||
val vortexBank = coalXbar
|
||||
|
||||
|
||||
|
||||
//If there is only 1 bank, the code below is useless
|
||||
val upstream = p(CoalXbarKey) match {
|
||||
case Some(xbarParam) =>{
|
||||
val tileXbar = LazyModule(new TLXbar)
|
||||
println(s"============ Using TLXBar for L1 Requests ")
|
||||
tileXbar.node :=* vortexBank
|
||||
tileXbar.node
|
||||
// Need to explicitly generate clock domain; see rocket-chip 8881ccd
|
||||
val memtracerDomain = sbus.generateSynchronousDomain
|
||||
memtracerDomain {
|
||||
val tracer = LazyModule(
|
||||
new MemTraceDriver(config, filename, param.traceHasSource)(p)
|
||||
)
|
||||
val coreSideLogger = LazyModule(
|
||||
new MemTraceLogger(numLanes, filename, loggerName = "coreside")
|
||||
)
|
||||
val memSideLogger = LazyModule(
|
||||
new MemTraceLogger(numLanes + 1, filename, loggerName = "memside")
|
||||
)
|
||||
// Must use :=* to ensure the N edges from Tracer doesn't get merged into 1
|
||||
// when connecting to SBus
|
||||
println(
|
||||
s"============ MemTraceDriver instantiated [filename=${param.tracefilename}]"
|
||||
)
|
||||
val coalescerNode = p(CoalescerKey) match {
|
||||
case Some(coalParam) => {
|
||||
val coal = LazyModule(new CoalescingUnit(coalParam))
|
||||
coal.cpuNode :=* coreSideLogger.node :=* tracer.node // N lanes
|
||||
memSideLogger.node :=* coal.aggregateNode // N+1 lanes
|
||||
memSideLogger.node
|
||||
}
|
||||
case None => tracer.node
|
||||
}
|
||||
val coalXbar = p(CoalXbarKey) match {
|
||||
case Some(xbarParam) =>{
|
||||
val coXbar = LazyModule(new TLXbar)
|
||||
println(s"============ Using TLXBar for Coalescer Requests ")
|
||||
coXbar.node :=* coalescerNode
|
||||
coXbar.node
|
||||
}
|
||||
case None => coalescerNode
|
||||
}
|
||||
case None => vortexBank
|
||||
}
|
||||
|
||||
|
||||
sbus.coupleFrom(s"gpu-tracer") { _ :=* upstream }
|
||||
val vortexBank = coalXbar
|
||||
|
||||
//If there is only 1 bank, the code below is useless
|
||||
val upstream = p(CoalXbarKey) match {
|
||||
case Some(xbarParam) =>{
|
||||
val tileXbar = LazyModule(new TLXbar)
|
||||
println(s"============ Using TLXBar for L1 Requests ")
|
||||
tileXbar.node :=* vortexBank
|
||||
tileXbar.node
|
||||
}
|
||||
case None => vortexBank
|
||||
}
|
||||
|
||||
sbus.coupleFrom(s"gpu-tracer") { _ :=* upstream }
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -100,7 +100,7 @@ class VortexBundle(tile: VortexTile)(implicit p: Parameters) extends CoreBundle
|
||||
//val rocc = Flipped(new RoCCCoreIO(nTotalRoCCCSRs))
|
||||
//val trace = Output(new TraceBundle)
|
||||
//val bpwatch = Output(Vec(coreParams.nBreakpoints, new BPWatch(coreParams.retireWidth)))
|
||||
val cease = Output(Bool())
|
||||
val finished = Output(Bool())
|
||||
val wfi = Output(Bool())
|
||||
val traceStall = Input(Bool())
|
||||
}
|
||||
|
||||
@@ -452,11 +452,11 @@ class VortexTileModuleImp(outer: VortexTile) extends BaseTileModuleImp(outer) {
|
||||
core.io.reset_vector := DontCare
|
||||
|
||||
outer.regNode.regmap(
|
||||
0x00 -> Seq(RegField.r(32, core.io.cease))
|
||||
0x00 -> Seq(RegField.r(32, core.io.finished))
|
||||
)
|
||||
|
||||
// Report when the tile has ceased to retire instructions; for now the only cause is clock gating
|
||||
outer.reportCease(outer.vortexParams.core.clockGate.option(core.io.cease))
|
||||
// Report when the tile has ceased to retire instructions
|
||||
outer.reportCease(Some(core.io.finished))
|
||||
|
||||
outer.reportWFI(Some(core.io.wfi))
|
||||
|
||||
|
||||
Reference in New Issue
Block a user