1
0

Revert "include the unmatched field in CDEMatchError"

This reverts commit ff2937a788.
This commit is contained in:
Howard Mao 2016-06-07 16:13:01 -07:00
parent 8db27a36c4
commit 2cd897e240
3 changed files with 44 additions and 44 deletions

@ -1 +1 @@
Subproject commit 6ce66711e7d9b65c49806734fa4028ed1305cf21 Subproject commit 846f00987cc95aa6b9b806d3c8c690c6e011b89d

View File

@ -305,7 +305,7 @@ class BaseConfig extends Config (
case UseHtifClockDiv => true case UseHtifClockDiv => true
case ConfigString => makeConfigString() case ConfigString => makeConfigString()
case GlobalAddrMap => globalAddrMap case GlobalAddrMap => globalAddrMap
case field => throw new CDEMatchError(field) case _ => throw new CDEMatchError
}}, }},
knobValues = { knobValues = {
case "NTILES" => 1 case "NTILES" => 1
@ -316,35 +316,35 @@ class BaseConfig extends Config (
case "L1I_SETS" => 64 case "L1I_SETS" => 64
case "L1I_WAYS" => 4 case "L1I_WAYS" => 4
case "L1I_BUFFER_WAYS" => false case "L1I_BUFFER_WAYS" => false
case field => throw new CDEMatchError(field) case _ => throw new CDEMatchError
} }
) )
class DefaultConfig extends Config(new WithBlockingL1 ++ new BaseConfig) class DefaultConfig extends Config(new WithBlockingL1 ++ new BaseConfig)
class With2Cores extends Config(knobValues = { case "NTILES" => 2; case field => throw new CDEMatchError(field) }) class With2Cores extends Config(knobValues = { case "NTILES" => 2; case _ => throw new CDEMatchError })
class With4Cores extends Config(knobValues = { case "NTILES" => 4; case field => throw new CDEMatchError(field) }) class With4Cores extends Config(knobValues = { case "NTILES" => 4; case _ => throw new CDEMatchError })
class With8Cores extends Config(knobValues = { case "NTILES" => 8; case field => throw new CDEMatchError(field) }) class With8Cores extends Config(knobValues = { case "NTILES" => 8; case _ => throw new CDEMatchError })
class With2BanksPerMemChannel extends Config(knobValues = { case "NBANKS_PER_MEM_CHANNEL" => 2; case field => throw new CDEMatchError(field) }) class With2BanksPerMemChannel extends Config(knobValues = { case "NBANKS_PER_MEM_CHANNEL" => 2; case _ => throw new CDEMatchError })
class With4BanksPerMemChannel extends Config(knobValues = { case "NBANKS_PER_MEM_CHANNEL" => 4; case field => throw new CDEMatchError(field) }) class With4BanksPerMemChannel extends Config(knobValues = { case "NBANKS_PER_MEM_CHANNEL" => 4; case _ => throw new CDEMatchError })
class With8BanksPerMemChannel extends Config(knobValues = { case "NBANKS_PER_MEM_CHANNEL" => 8; case field => throw new CDEMatchError(field) }) class With8BanksPerMemChannel extends Config(knobValues = { case "NBANKS_PER_MEM_CHANNEL" => 8; case _ => throw new CDEMatchError })
class With2MemoryChannels extends Config( class With2MemoryChannels extends Config(
(pname,site,here) => pname match { (pname,site,here) => pname match {
case NMemoryChannels => Dump("N_MEM_CHANNELS", 2) case NMemoryChannels => Dump("N_MEM_CHANNELS", 2)
case field => throw new CDEMatchError(field) case _ => throw new CDEMatchError
} }
) )
class With4MemoryChannels extends Config( class With4MemoryChannels extends Config(
(pname,site,here) => pname match { (pname,site,here) => pname match {
case NMemoryChannels => Dump("N_MEM_CHANNELS", 4) case NMemoryChannels => Dump("N_MEM_CHANNELS", 4)
case field => throw new CDEMatchError(field) case _ => throw new CDEMatchError
} }
) )
class With8MemoryChannels extends Config( class With8MemoryChannels extends Config(
(pname,site,here) => pname match { (pname,site,here) => pname match {
case NMemoryChannels => Dump("N_MEM_CHANNELS", 8) case NMemoryChannels => Dump("N_MEM_CHANNELS", 8)
case field => throw new CDEMatchError(field) case _ => throw new CDEMatchError
} }
) )
@ -371,27 +371,27 @@ class WithL2Cache extends Config(
case InnerTLId => "L1toL2" case InnerTLId => "L1toL2"
case OuterTLId => "L2toMC"}))) case OuterTLId => "L2toMC"})))
case L2Replacer => () => new SeqRandom(site(NWays)) case L2Replacer => () => new SeqRandom(site(NWays))
case field => throw new CDEMatchError(field) case _ => throw new CDEMatchError
}, },
knobValues = { case "L2_WAYS" => 8; case "L2_CAPACITY_IN_KB" => 2048; case "L2_SPLIT_METADATA" => false; case field => throw new CDEMatchError(field) } knobValues = { case "L2_WAYS" => 8; case "L2_CAPACITY_IN_KB" => 2048; case "L2_SPLIT_METADATA" => false; case _ => throw new CDEMatchError }
) )
class WithPLRU extends Config( class WithPLRU extends Config(
(pname, site, here) => pname match { (pname, site, here) => pname match {
case L2Replacer => () => new SeqPLRU(site(NSets), site(NWays)) case L2Replacer => () => new SeqPLRU(site(NSets), site(NWays))
case field => throw new CDEMatchError(field) case _ => throw new CDEMatchError
}) })
class WithL2Capacity2048 extends Config(knobValues = { case "L2_CAPACITY_IN_KB" => 2048; case field => throw new CDEMatchError(field) }) class WithL2Capacity2048 extends Config(knobValues = { case "L2_CAPACITY_IN_KB" => 2048; case _ => throw new CDEMatchError })
class WithL2Capacity1024 extends Config(knobValues = { case "L2_CAPACITY_IN_KB" => 1024; case field => throw new CDEMatchError(field) }) class WithL2Capacity1024 extends Config(knobValues = { case "L2_CAPACITY_IN_KB" => 1024; case _ => throw new CDEMatchError })
class WithL2Capacity512 extends Config(knobValues = { case "L2_CAPACITY_IN_KB" => 512; case field => throw new CDEMatchError(field) }) class WithL2Capacity512 extends Config(knobValues = { case "L2_CAPACITY_IN_KB" => 512; case _ => throw new CDEMatchError })
class WithL2Capacity256 extends Config(knobValues = { case "L2_CAPACITY_IN_KB" => 256; case field => throw new CDEMatchError(field) }) class WithL2Capacity256 extends Config(knobValues = { case "L2_CAPACITY_IN_KB" => 256; case _ => throw new CDEMatchError })
class WithL2Capacity128 extends Config(knobValues = { case "L2_CAPACITY_IN_KB" => 128; case field => throw new CDEMatchError(field) }) class WithL2Capacity128 extends Config(knobValues = { case "L2_CAPACITY_IN_KB" => 128; case _ => throw new CDEMatchError })
class WithL2Capacity64 extends Config(knobValues = { case "L2_CAPACITY_IN_KB" => 64; case field => throw new CDEMatchError(field) }) class WithL2Capacity64 extends Config(knobValues = { case "L2_CAPACITY_IN_KB" => 64; case _ => throw new CDEMatchError })
class With1L2Ways extends Config(knobValues = { case "L2_WAYS" => 1; case field => throw new CDEMatchError(field) }) class With1L2Ways extends Config(knobValues = { case "L2_WAYS" => 1; case _ => throw new CDEMatchError })
class With2L2Ways extends Config(knobValues = { case "L2_WAYS" => 2; case field => throw new CDEMatchError(field) }) class With2L2Ways extends Config(knobValues = { case "L2_WAYS" => 2; case _ => throw new CDEMatchError })
class With4L2Ways extends Config(knobValues = { case "L2_WAYS" => 4; case field => throw new CDEMatchError(field) }) class With4L2Ways extends Config(knobValues = { case "L2_WAYS" => 4; case _ => throw new CDEMatchError })
class DefaultL2Config extends Config(new WithL2Cache ++ new BaseConfig) class DefaultL2Config extends Config(new WithL2Cache ++ new BaseConfig)
class DefaultL2FPGAConfig extends Config(new WithL2Capacity64 ++ new WithL2Cache ++ new DefaultFPGAConfig) class DefaultL2FPGAConfig extends Config(new WithL2Capacity64 ++ new WithL2Cache ++ new DefaultFPGAConfig)
@ -405,7 +405,7 @@ class WithRV32 extends Config(
case UseUser => false case UseUser => false
case UseAtomics => false case UseAtomics => false
case UseFPU => false case UseFPU => false
case field => throw new CDEMatchError(field) case _ => throw new CDEMatchError
} }
) )
@ -413,14 +413,14 @@ class FPGAConfig extends Config (
(pname,site,here) => pname match { (pname,site,here) => pname match {
case NAcquireTransactors => 4 case NAcquireTransactors => 4
case UseHtifClockDiv => false case UseHtifClockDiv => false
case field => throw new CDEMatchError(field) case _ => throw new CDEMatchError
} }
) )
class WithBlockingL1 extends Config ( class WithBlockingL1 extends Config (
knobValues = { knobValues = {
case "L1D_MSHRS" => 0 case "L1D_MSHRS" => 0
case field => throw new CDEMatchError(field) case _ => throw new CDEMatchError
} }
) )
@ -441,7 +441,7 @@ class SmallConfig extends Config (
case StoreDataQueueDepth => 2 case StoreDataQueueDepth => 2
case ReplayQueueDepth => 2 case ReplayQueueDepth => 2
case NAcquireTransactors => 2 case NAcquireTransactors => 2
case field => throw new CDEMatchError(field) case _ => throw new CDEMatchError
}}, }},
knobValues = { knobValues = {
case "L1D_SETS" => 64 case "L1D_SETS" => 64
@ -449,7 +449,7 @@ class SmallConfig extends Config (
case "L1I_SETS" => 64 case "L1I_SETS" => 64
case "L1I_WAYS" => 1 case "L1I_WAYS" => 1
case "L1D_MSHRS" => 0 case "L1D_MSHRS" => 0
case field => throw new CDEMatchError(field) case _ => throw new CDEMatchError
} }
) )
@ -488,7 +488,7 @@ class WithRoccExample extends Config(
generator = (p: Parameters) => Module(new CharacterCountExample()(p)))) generator = (p: Parameters) => Module(new CharacterCountExample()(p))))
case RoccMaxTaggedMemXacts => 1 case RoccMaxTaggedMemXacts => 1
case field => throw new CDEMatchError(field) case _ => throw new CDEMatchError
}) })
class RoccExampleConfig extends Config(new WithRoccExample ++ new BaseConfig) class RoccExampleConfig extends Config(new WithRoccExample ++ new BaseConfig)
@ -504,7 +504,7 @@ class WithDmaController extends Config(
DmaCtrlRegNumbers.CSR_BASE, DmaCtrlRegNumbers.CSR_BASE,
DmaCtrlRegNumbers.CSR_END))) DmaCtrlRegNumbers.CSR_END)))
case RoccMaxTaggedMemXacts => 1 case RoccMaxTaggedMemXacts => 1
case field => throw new CDEMatchError(field) case _ => throw new CDEMatchError
}) })
class WithStreamLoopback extends Config( class WithStreamLoopback extends Config(
@ -512,7 +512,7 @@ class WithStreamLoopback extends Config(
case UseStreamLoopback => true case UseStreamLoopback => true
case StreamLoopbackSize => 128 case StreamLoopbackSize => 128
case StreamLoopbackWidth => 64 case StreamLoopbackWidth => 64
case field => throw new CDEMatchError(field) case _ => throw new CDEMatchError
}) })
class DmaControllerConfig extends Config(new WithDmaController ++ new WithStreamLoopback ++ new DefaultL2Config) class DmaControllerConfig extends Config(new WithDmaController ++ new WithStreamLoopback ++ new DefaultL2Config)
@ -529,7 +529,7 @@ class OctoChannelBenchmarkConfig extends Config(new With8MemoryChannels ++ new S
class EightChannelConfig extends Config(new With8MemoryChannels ++ new BaseConfig) class EightChannelConfig extends Config(new With8MemoryChannels ++ new BaseConfig)
class WithSplitL2Metadata extends Config(knobValues = { case "L2_SPLIT_METADATA" => true; case field => throw new CDEMatchError(field) }) class WithSplitL2Metadata extends Config(knobValues = { case "L2_SPLIT_METADATA" => true; case _ => throw new CDEMatchError })
class SplitL2MetadataTestConfig extends Config(new WithSplitL2Metadata ++ new DefaultL2Config) class SplitL2MetadataTestConfig extends Config(new WithSplitL2Metadata ++ new DefaultL2Config)
class DualCoreConfig extends Config(new With2Cores ++ new BaseConfig) class DualCoreConfig extends Config(new With2Cores ++ new BaseConfig)

View File

@ -44,7 +44,7 @@ class WithGroundTest extends Config(
case RoccNCSRs => site(GroundTestCSRs).size case RoccNCSRs => site(GroundTestCSRs).size
case UseFPU => false case UseFPU => false
case UseAtomics => true case UseAtomics => true
case field => throw new CDEMatchError(field) case _ => throw new CDEMatchError
}) })
class WithMemtest extends Config( class WithMemtest extends Config(
@ -56,19 +56,19 @@ class WithMemtest extends Config(
case GeneratorStartAddress => site(GlobalAddrMap)("mem").start case GeneratorStartAddress => site(GlobalAddrMap)("mem").start
case BuildGroundTest => case BuildGroundTest =>
(id: Int, p: Parameters) => Module(new GeneratorTest(id)(p)) (id: Int, p: Parameters) => Module(new GeneratorTest(id)(p))
case field => throw new CDEMatchError(field) case _ => throw new CDEMatchError
}) })
class WithCacheFillTest extends Config( class WithCacheFillTest extends Config(
(pname, site, here) => pname match { (pname, site, here) => pname match {
case BuildGroundTest => case BuildGroundTest =>
(id: Int, p: Parameters) => Module(new CacheFillTest()(p)) (id: Int, p: Parameters) => Module(new CacheFillTest()(p))
case field => throw new CDEMatchError(field) case _ => throw new CDEMatchError
}, },
knobValues = { knobValues = {
case "L2_WAYS" => 4 case "L2_WAYS" => 4
case "L2_CAPACITY_IN_KB" => 4 case "L2_CAPACITY_IN_KB" => 4
case field => throw new CDEMatchError(field) case _ => throw new CDEMatchError
}) })
class WithBroadcastRegressionTest extends Config( class WithBroadcastRegressionTest extends Config(
@ -78,7 +78,7 @@ class WithBroadcastRegressionTest extends Config(
case GroundTestRegressions => case GroundTestRegressions =>
(p: Parameters) => RegressionTests.broadcastRegressions(p) (p: Parameters) => RegressionTests.broadcastRegressions(p)
case GroundTestMaxXacts => 3 case GroundTestMaxXacts => 3
case field => throw new CDEMatchError(field) case _ => throw new CDEMatchError
}) })
class WithCacheRegressionTest extends Config( class WithCacheRegressionTest extends Config(
@ -88,7 +88,7 @@ class WithCacheRegressionTest extends Config(
case GroundTestRegressions => case GroundTestRegressions =>
(p: Parameters) => RegressionTests.cacheRegressions(p) (p: Parameters) => RegressionTests.cacheRegressions(p)
case GroundTestMaxXacts => 3 case GroundTestMaxXacts => 3
case field => throw new CDEMatchError(field) case _ => throw new CDEMatchError
}) })
class WithDmaTest extends Config( class WithDmaTest extends Config(
@ -104,7 +104,7 @@ class WithDmaTest extends Config(
(0x00800008, 0x00800008, 64)) (0x00800008, 0x00800008, 64))
case DmaTestDataStart => 0x3012CC00 case DmaTestDataStart => 0x3012CC00
case DmaTestDataStride => 8 case DmaTestDataStride => 8
case field => throw new CDEMatchError(field) case _ => throw new CDEMatchError
}) })
class WithDmaStreamTest extends Config( class WithDmaStreamTest extends Config(
@ -116,21 +116,21 @@ class WithDmaStreamTest extends Config(
size = site(StreamLoopbackWidth) / 8) size = site(StreamLoopbackWidth) / 8)
case GroundTestCSRs => case GroundTestCSRs =>
Seq(DmaCtrlRegNumbers.CSR_BASE + DmaCtrlRegNumbers.OUTSTANDING) Seq(DmaCtrlRegNumbers.CSR_BASE + DmaCtrlRegNumbers.OUTSTANDING)
case field => throw new CDEMatchError(field) case _ => throw new CDEMatchError
}) })
class WithNastiConverterTest extends Config( class WithNastiConverterTest extends Config(
(pname, site, here) => pname match { (pname, site, here) => pname match {
case BuildGroundTest => case BuildGroundTest =>
(id: Int, p: Parameters) => Module(new NastiConverterTest()(p)) (id: Int, p: Parameters) => Module(new NastiConverterTest()(p))
case field => throw new CDEMatchError(field) case _ => throw new CDEMatchError
}) })
class WithUnitTest extends Config( class WithUnitTest extends Config(
(pname, site, here) => pname match { (pname, site, here) => pname match {
case BuildGroundTest => case BuildGroundTest =>
(id: Int, p: Parameters) => Module(new UnitTestSuite()(p)) (id: Int, p: Parameters) => Module(new UnitTestSuite()(p))
case field => throw new CDEMatchError(field) case _ => throw new CDEMatchError
}) })
class WithTraceGen extends Config( class WithTraceGen extends Config(
@ -140,7 +140,7 @@ class WithTraceGen extends Config(
case NGenerators => site(NTiles) case NGenerators => site(NTiles)
case MaxGenerateRequests => 128 case MaxGenerateRequests => 128
case AddressBag => List(0x8, 0x10, 0x108, 0x100008) case AddressBag => List(0x8, 0x10, 0x108, 0x100008)
case field => throw new CDEMatchError(field) case _ => throw new CDEMatchError
}) })
class GroundTestConfig extends Config(new WithGroundTest ++ new BaseConfig) class GroundTestConfig extends Config(new WithGroundTest ++ new BaseConfig)