summaryrefslogtreecommitdiff
path: root/configs/example/se.py
diff options
context:
space:
mode:
authorAndreas Hansson <andreas.hansson@arm.com>2013-04-22 13:20:33 -0400
committerAndreas Hansson <andreas.hansson@arm.com>2013-04-22 13:20:33 -0400
commit3477d60d5c2f20644e301378ca2923766d765f8e (patch)
tree3ebea4940bab8c9c347bf56f1cef9db8b170ab0d /configs/example/se.py
parenta35d3ff167a50bcbaeffbefc46bde5f640a475f5 (diff)
downloadgem5-3477d60d5c2f20644e301378ca2923766d765f8e.tar.xz
config: Add a mem-type config option to se/fs scripts
This patch enables selection of the memory controller class through a mem-type command-line option. Behind the scenes, this option is treated much like the cpu-type, and a similar framework is used to resolve the valid options, and translate the short-hand description to a valid class. The regression scripts are updated with a hardcoded memory class for the moment. The best solution going forward is probably to get the memory out of the makeSystem functions, but Ruby complicates things as it does not connect the memory controller to the membus. --HG-- rename : configs/common/CpuConfig.py => configs/common/MemConfig.py
Diffstat (limited to 'configs/example/se.py')
-rw-r--r--configs/example/se.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/configs/example/se.py b/configs/example/se.py
index a5f0204fd..6878742c8 100644
--- a/configs/example/se.py
+++ b/configs/example/se.py
@@ -150,13 +150,15 @@ else:
CPUClass.clock = options.clock
CPUClass.numThreads = numThreads
+MemClass = Simulation.setMemClass(options)
+
# Check -- do not allow SMT with multiple CPUs
if options.smt and options.num_cpus > 1:
fatal("You cannot use SMT with multiple CPUs!")
np = options.num_cpus
system = System(cpu = [CPUClass(cpu_id=i) for i in xrange(np)],
- physmem = SimpleMemory(range=AddrRange("512MB")),
+ physmem = MemClass(range=AddrRange("512MB")),
membus = CoherentBus(), mem_mode = test_mem_mode)
# Sanity check