summaryrefslogtreecommitdiff
path: root/src/cpu/simple
diff options
context:
space:
mode:
authorGabe Black <gblack@eecs.umich.edu>2012-04-15 12:35:49 -0700
committerGabe Black <gblack@eecs.umich.edu>2012-04-15 12:35:49 -0700
commita5187f9d966d967254c71e1fb3545a4745aadc75 (patch)
tree8aeeb6902aa998cc3c522f835369a3eb6e0a5544 /src/cpu/simple
parent8fe112d61b08b83b6b7f27daa9daaa521e67deaf (diff)
downloadgem5-a5187f9d966d967254c71e1fb3545a4745aadc75.tar.xz
CPU: Tidy up some formatting and a DPRINTF in the simple CPU base class.
Put the { on the same line as the if and put a space between the if and the open paren. Also, use the # format modifier which puts a 0x in front of hex values automatically. If the ExtMachInst type isn't integral and actually prints something more complicated, the # falls away harmlessly and we aren't left with a phantom 0x followed by a bunch of unrelated text.
Diffstat (limited to 'src/cpu/simple')
-rw-r--r--src/cpu/simple/base.cc5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/cpu/simple/base.cc b/src/cpu/simple/base.cc
index a5951035e..ca4090870 100644
--- a/src/cpu/simple/base.cc
+++ b/src/cpu/simple/base.cc
@@ -414,13 +414,12 @@ BaseSimpleCPU::preExecute()
}
//If we decoded an instruction this "tick", record information about it.
- if(curStaticInst)
- {
+ if (curStaticInst) {
#if TRACING_ON
traceData = tracer->getInstRecord(curTick(), tc,
curStaticInst, thread->pcState(), curMacroStaticInst);
- DPRINTF(Decode,"Decode: Decoded %s instruction: 0x%x\n",
+ DPRINTF(Decode,"Decode: Decoded %s instruction: %#x\n",
curStaticInst->getName(), curStaticInst->machInst);
#endif // TRACING_ON
}