From 9f0d8f252c2de0b9ac5654b2c35e913831eba756 Mon Sep 17 00:00:00 2001 From: Korey Sewell Date: Wed, 23 Jun 2010 18:18:20 -0400 Subject: inorder-stats: add instruction type stats also, remove inst-req stats as default.good for debugging but in terms of pure processor stats they aren't useful --- src/cpu/inorder/resources/execution_unit.cc | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) (limited to 'src/cpu/inorder/resources/execution_unit.cc') diff --git a/src/cpu/inorder/resources/execution_unit.cc b/src/cpu/inorder/resources/execution_unit.cc index 429291231..868ebe098 100644 --- a/src/cpu/inorder/resources/execution_unit.cc +++ b/src/cpu/inorder/resources/execution_unit.cc @@ -56,14 +56,9 @@ ExecutionUnit::regStats() lastExecuteCycle = curTick; - cyclesExecuted - .name(name() + ".cyclesExecuted") - .desc("Number of Cycles Execution Unit was used."); - - utilization - .name(name() + ".utilization") - .desc("Utilization of Execution Unit (cycles / totalCycles)."); - utilization = cyclesExecuted / cpu->numCycles; + executions + .name(name() + ".executions") + .desc("Number of Instructions Executed."); Resource::regStats(); } @@ -88,7 +83,6 @@ ExecutionUnit::execute(int slot_num) { if (curTick != lastExecuteCycle) { lastExecuteCycle = curTick; - cyclesExecuted++; } @@ -97,6 +91,7 @@ ExecutionUnit::execute(int slot_num) } else if (inst->isControl()) { // Evaluate Branch fault = inst->execute(); + executions++; inst->setExecuted(); @@ -190,6 +185,7 @@ ExecutionUnit::execute(int slot_num) } else { // Regular ALU instruction fault = inst->execute(); + executions++; if (fault == NoFault) { inst->setExecuted(); -- cgit v1.2.3