summaryrefslogtreecommitdiff
path: root/objects/BaseCPU.mpy
diff options
context:
space:
mode:
authorNathan Binkert <binkertn@umich.edu>2005-03-09 14:42:30 -0500
committerNathan Binkert <binkertn@umich.edu>2005-03-09 14:42:30 -0500
commit7d91bda6bfba1bd0cf49ff7ff20373b5d44df87a (patch)
treeef8d47d1ac5522b7edf6dd12d623b22001fb6844 /objects/BaseCPU.mpy
parent4a3ad218e1a41a9fa655471b999e2540e4e78448 (diff)
downloadgem5-7d91bda6bfba1bd0cf49ff7ff20373b5d44df87a.tar.xz
Add support for using the variables that m5 was compiled with for
determining which parameters belong to a class. This allows us to remove the disable flag since it is not the correct model for variable checking anyway. objects/BaseCPU.mpy: Use the FULL_SYSTEM environment variable to enable or disable parameters. sim/pyconfig/m5config.py: remove the disable flag since it is not the correct model for variable checking. --HG-- extra : convert_revision : a8ccb78ba16d23006225df282a09187d32557608
Diffstat (limited to 'objects/BaseCPU.mpy')
-rw-r--r--objects/BaseCPU.mpy28
1 files changed, 7 insertions, 21 deletions
diff --git a/objects/BaseCPU.mpy b/objects/BaseCPU.mpy
index f6e6ff96c..484fcccd6 100644
--- a/objects/BaseCPU.mpy
+++ b/objects/BaseCPU.mpy
@@ -4,11 +4,13 @@ simobj BaseCPU(SimObject):
icache = Param.BaseMem(NULL, "L1 instruction cache object")
dcache = Param.BaseMem(NULL, "L1 data cache object")
- dtb = Param.AlphaDTB("Data TLB")
- itb = Param.AlphaITB("Instruction TLB")
- mem = Param.FunctionalMemory("memory")
- system = Param.BaseSystem(Super, "system object")
- workload = VectorParam.Process("processes to run")
+ if Bool._convert(env.get('FULL_SYSTEM', 'False')):
+ dtb = Param.AlphaDTB("Data TLB")
+ itb = Param.AlphaITB("Instruction TLB")
+ mem = Param.FunctionalMemory("memory")
+ system = Param.BaseSystem(Super, "system object")
+ else:
+ workload = VectorParam.Process("processes to run")
max_insts_all_threads = Param.Counter(0,
"terminate when all threads have reached this inst count")
@@ -21,19 +23,3 @@ simobj BaseCPU(SimObject):
defer_registration = Param.Bool(False,
"defer registration with system (for sampling)")
-
- def check(self):
- has_workload = self._hasvalue('workload')
- has_dtb = self._hasvalue('dtb')
- has_itb = self._hasvalue('itb')
- has_mem = self._hasvalue('mem')
- has_system = self._hasvalue('system')
-
- if has_workload:
- self.dtb.disable = True
- self.itb.disable = True
- self.mem.disable = True
- self.system.disable = True
-
- if has_dtb or has_itb or has_mem or has_system:
- self.workload.disable = True