From: Andreas Sandberg Date: Fri, 15 Feb 2013 22:40:08 +0000 (-0500) Subject: cpu: Make checker CPUs inherit from CheckerCPU in the Python hierarchy X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=7f1263f1446b789e9f88685ae763ba575e81e454;p=gem5.git cpu: Make checker CPUs inherit from CheckerCPU in the Python hierarchy Checker CPUs currently don't inherit from the CheckerCPU in the Python object hierarchy. This has two consequences: * It makes CPU model discovery from the Python world somewhat complicated as there is no way of testing if a CPU is a checker. * Parameters are duplicated in the checker configuration specification. This changeset makes all checker CPUs inherit from the base checker CPU class. --- diff --git a/src/cpu/DummyChecker.py b/src/cpu/DummyChecker.py index e75f7057e..3bf021a14 100644 --- a/src/cpu/DummyChecker.py +++ b/src/cpu/DummyChecker.py @@ -36,8 +36,8 @@ # Authors: Geoffrey Blake from m5.params import * -from BaseCPU import BaseCPU +from CheckerCPU import CheckerCPU -class DummyChecker(BaseCPU): +class DummyChecker(CheckerCPU): type = 'DummyChecker' cxx_header = 'cpu/dummy_checker.hh' diff --git a/src/cpu/o3/O3Checker.py b/src/cpu/o3/O3Checker.py index d2dc8e95b..f21a038c4 100644 --- a/src/cpu/o3/O3Checker.py +++ b/src/cpu/o3/O3Checker.py @@ -27,14 +27,8 @@ # Authors: Nathan Binkert from m5.params import * -from BaseCPU import BaseCPU +from CheckerCPU import CheckerCPU -class O3Checker(BaseCPU): +class O3Checker(CheckerCPU): type = 'O3Checker' cxx_header = 'cpu/o3/checker.hh' - - exitOnError = Param.Bool(False, "Exit on an error") - updateOnError = Param.Bool(False, - "Update the checker with the main CPU's state on an error") - warnOnlyOnLoadError = Param.Bool(True, - "If a load result is incorrect, only print a warning and do not exit")