fix firesim test suite generation
This commit is contained in:
@@ -16,10 +16,10 @@ import freechips.rocketchip.config.Parameters
|
||||
import freechips.rocketchip.subsystem.RocketTilesKey
|
||||
import freechips.rocketchip.tile.XLen
|
||||
|
||||
import boom.system.{BoomTilesKey, BoomTestSuites}
|
||||
|
||||
import firesim.util.{GeneratorArgs, HasTargetAgnosticUtilites, HasFireSimGeneratorUtilities}
|
||||
|
||||
import utilities.TestSuiteHelper
|
||||
|
||||
trait HasTestSuites {
|
||||
val rv64RegrTestNames = collection.mutable.LinkedHashSet(
|
||||
"rv64ud-v-fcvt",
|
||||
@@ -58,38 +58,8 @@ trait HasTestSuites {
|
||||
"rv32ui-p-sll")
|
||||
|
||||
def addTestSuites(targetName: String, params: Parameters) {
|
||||
val coreParams =
|
||||
if (params(RocketTilesKey).nonEmpty) {
|
||||
params(RocketTilesKey).head.core
|
||||
} else {
|
||||
params(BoomTilesKey).head.core
|
||||
}
|
||||
val xlen = params(XLen)
|
||||
val vm = coreParams.useVM
|
||||
val env = if (vm) List("p","v") else List("p")
|
||||
coreParams.fpu foreach { case cfg =>
|
||||
if (xlen == 32) {
|
||||
TestGeneration.addSuites(env.map(rv32uf))
|
||||
if (cfg.fLen >= 64)
|
||||
TestGeneration.addSuites(env.map(rv32ud))
|
||||
} else {
|
||||
TestGeneration.addSuite(rv32udBenchmarks)
|
||||
TestGeneration.addSuites(env.map(rv64uf))
|
||||
if (cfg.fLen >= 64)
|
||||
TestGeneration.addSuites(env.map(rv64ud))
|
||||
}
|
||||
}
|
||||
if (coreParams.useAtomics) TestGeneration.addSuites(env.map(if (xlen == 64) rv64ua else rv32ua))
|
||||
if (coreParams.useCompressed) TestGeneration.addSuites(env.map(if (xlen == 64) rv64uc else rv32uc))
|
||||
val (rvi, rvu) =
|
||||
if (params(BoomTilesKey).nonEmpty) ((if (vm) BoomTestSuites.rv64i else BoomTestSuites.rv64pi), rv64u)
|
||||
else if (xlen == 64) ((if (vm) rv64i else rv64pi), rv64u)
|
||||
else ((if (vm) rv32i else rv32pi), rv32u)
|
||||
|
||||
TestGeneration.addSuites(rvi.map(_("p")))
|
||||
TestGeneration.addSuites((if (vm) List("v") else List()).flatMap(env => rvu.map(_(env))))
|
||||
TestGeneration.addSuite(benchmarks)
|
||||
TestGeneration.addSuite(new RegressionTestSuite(if (xlen == 64) rv64RegrTestNames else rv32RegrTestNames))
|
||||
TestSuiteHelper.addRocketTestSuites(params)
|
||||
TestSuiteHelper.addBoomTestSuites(params)
|
||||
TestGeneration.addSuite(FastBlockdevTests)
|
||||
TestGeneration.addSuite(SlowBlockdevTests)
|
||||
if (!targetName.contains("NoNIC"))
|
||||
|
||||
@@ -137,7 +137,7 @@ class FireSimBoomConfig extends Config(
|
||||
new WithBoomL2TLBs(1024) ++
|
||||
new WithoutClockGating ++
|
||||
// Using a small config because it has 64-bit system bus, and compiles quickly
|
||||
new boom.system.SmallBoomConfig)
|
||||
new boom.common.SmallBoomConfig)
|
||||
|
||||
// A safer implementation than the one in BOOM in that it
|
||||
// duplicates whatever BOOMTileKey.head is present N times. This prevents
|
||||
|
||||
Reference in New Issue
Block a user