BaseCPU.py revision 1310
1simobj BaseCPU(SimObject): 2 abstract = True 3 icache = Param.BaseMem(NULL, "L1 instruction cache object") 4 dcache = Param.BaseMem(NULL, "L1 data cache object") 5 6 dtb = Param.AlphaDTB("Data TLB") 7 itb = Param.AlphaITB("Instruction TLB") 8 mem = Param.FunctionalMemory("memory") 9 system = Param.BaseSystem(Super, "system object") 10 workload = VectorParam.Process("processes to run") 11 12 max_insts_all_threads = Param.Counter(0, 13 "terminate when all threads have reached this inst count") 14 max_insts_any_thread = Param.Counter(0, 15 "terminate when any thread reaches this inst count") 16 max_loads_all_threads = Param.Counter(0, 17 "terminate when all threads have reached this load count") 18 max_loads_any_thread = Param.Counter(0, 19 "terminate when any thread reaches this load count") 20 21 defer_registration = Param.Bool(false, 22 "defer registration with system (for sampling)") 23 24 def check(self): 25 has_workload = self._hasvalue('workload') 26 has_dtb = self._hasvalue('dtb') 27 has_itb = self._hasvalue('itb') 28 has_mem = self._hasvalue('mem') 29 has_system = self._hasvalue('system') 30 31 if has_workload: 32 self.dtb.disable = True 33 self.itb.disable = True 34 self.mem.disable = True 35 self.system.disable = True 36 37 if has_dtb or has_itb or has_mem or has_system: 38 self.workload.disable = True 39