summaryrefslogtreecommitdiff
path: root/cpu/base.cc
diff options
context:
space:
mode:
Diffstat (limited to 'cpu/base.cc')
-rw-r--r--cpu/base.cc8
1 files changed, 6 insertions, 2 deletions
diff --git a/cpu/base.cc b/cpu/base.cc
index 044fafca9..d4ba8c812 100644
--- a/cpu/base.cc
+++ b/cpu/base.cc
@@ -60,15 +60,19 @@ int maxThreadsPerCPU = 1;
void
CPUProgressEvent::process()
{
-#ifndef NDEBUG
Counter temp = cpu->totalInstructions();
+#ifndef NDEBUG
double ipc = double(temp - lastNumInst) / (interval / cpu->cycles(1));
+
DPRINTFN("%s progress event, instructions committed: %lli, IPC: %0.8d\n",
cpu->name(), temp - lastNumInst, ipc);
ipc = 0.0;
+#else
+ cprintf("%lli: %s progress event, instructions committed: %lli\n",
+ curTick, cpu->name(), temp - lastNumInst);
+#endif
lastNumInst = temp;
schedule(curTick + interval);
-#endif
}
const char *