summaryrefslogtreecommitdiff
path: root/src/cpu/checker/cpu.hh
diff options
context:
space:
mode:
authorGeoffrey Blake <geoffrey.blake@arm.com>2012-03-09 09:59:27 -0500
committerGeoffrey Blake <geoffrey.blake@arm.com>2012-03-09 09:59:27 -0500
commit043709fdfab3b6c46f6ef95d1f642cd3c06ee20a (patch)
treeef8bab03f4260b67b57b00844d0245ca1e849ea0 /src/cpu/checker/cpu.hh
parentdf05ffab1289b26aab2a0eb71ee55dcb7f42e5e9 (diff)
downloadgem5-043709fdfab3b6c46f6ef95d1f642cd3c06ee20a.tar.xz
CheckerCPU: Make CheckerCPU runtime selectable instead of compile selectable
Enables the CheckerCPU to be selected at runtime with the --checker option from the configs/example/fs.py and configs/example/se.py configuration files. Also merges with the SE/FS changes.
Diffstat (limited to 'src/cpu/checker/cpu.hh')
-rw-r--r--src/cpu/checker/cpu.hh27
1 files changed, 22 insertions, 5 deletions
diff --git a/src/cpu/checker/cpu.hh b/src/cpu/checker/cpu.hh
index 54e446932..c3d3a379e 100644
--- a/src/cpu/checker/cpu.hh
+++ b/src/cpu/checker/cpu.hh
@@ -112,13 +112,25 @@ class CheckerCPU : public BaseCPU
System *systemPtr;
- void setIcachePort(Port *icache_port);
+ void setIcachePort(CpuPort *icache_port);
- Port *icachePort;
+ CpuPort *icachePort;
- void setDcachePort(Port *dcache_port);
+ void setDcachePort(CpuPort *dcache_port);
- Port *dcachePort;
+ CpuPort *dcachePort;
+
+ CpuPort &getDataPort()
+ {
+ panic("Not supported on checker!");
+ return *dcachePort;
+ }
+
+ CpuPort &getInstPort()
+ {
+ panic("Not supported on checker!");
+ return *icachePort;
+ }
virtual Port *getPort(const std::string &name, int idx)
{
@@ -168,7 +180,12 @@ class CheckerCPU : public BaseCPU
TheISA::TLB* getITBPtr() { return itb; }
TheISA::TLB* getDTBPtr() { return dtb; }
- virtual Counter totalInstructions() const
+ virtual Counter totalInsts() const
+ {
+ return 0;
+ }
+
+ virtual Counter totalOps() const
{
return 0;
}