63,80c63,65
< static uint64_t regs[32] = {
< 0, 0, 0, 0, 0, 0, 0, 0,
< 0, 0, 0, 0, 0, 0, 0, 0,
< 0, 0, 0, 0, 0, 0, 0, 0,
< 0, 0, 0, 0, 0, 0, 0, 0};
< static uint64_t ccr = 0;
< static uint64_t y = 0;
< static uint64_t floats[32];
< uint64_t newVal;
< static const char * prefixes[4] = {"G", "O", "L", "I"};
<
< char buf[256];
< sprintf(buf, "PC = 0x%016llx", thread->readNextPC());
< outs << buf;
< sprintf(buf, " NPC = 0x%016llx", thread->readNextNPC());
< outs << buf;
< newVal = thread->readMiscReg(SparcISA::MISCREG_CCR);
< if(newVal != ccr)
---
> //Don't print what happens for each micro-op, just print out
> //once at the last op, and for regular instructions.
> if(!staticInst->isMicroOp() || staticInst->isLastMicroOp())
82c67,79
< sprintf(buf, " CCR = 0x%016llx", newVal);
---
> static uint64_t regs[32] = {
> 0, 0, 0, 0, 0, 0, 0, 0,
> 0, 0, 0, 0, 0, 0, 0, 0,
> 0, 0, 0, 0, 0, 0, 0, 0,
> 0, 0, 0, 0, 0, 0, 0, 0};
> static uint64_t ccr = 0;
> static uint64_t y = 0;
> static uint64_t floats[32];
> uint64_t newVal;
> static const char * prefixes[4] = {"G", "O", "L", "I"};
>
> char buf[256];
> sprintf(buf, "PC = 0x%016llx", thread->readNextPC());
84,89c81
< ccr = newVal;
< }
< newVal = thread->readMiscReg(SparcISA::MISCREG_Y);
< if(newVal != y)
< {
< sprintf(buf, " Y = 0x%016llx", newVal);
---
> sprintf(buf, " NPC = 0x%016llx", thread->readNextNPC());
91,95c83,84
< y = newVal;
< }
< for(int y = 0; y < 4; y++)
< {
< for(int x = 0; x < 8; x++)
---
> newVal = thread->readMiscReg(SparcISA::MISCREG_CCR);
> if(newVal != ccr)
97,99c86,99
< int index = x + 8 * y;
< newVal = thread->readIntReg(index);
< if(regs[index] != newVal)
---
> sprintf(buf, " CCR = 0x%016llx", newVal);
> outs << buf;
> ccr = newVal;
> }
> newVal = thread->readMiscReg(SparcISA::MISCREG_Y);
> if(newVal != y)
> {
> sprintf(buf, " Y = 0x%016llx", newVal);
> outs << buf;
> y = newVal;
> }
> for(int y = 0; y < 4; y++)
> {
> for(int x = 0; x < 8; x++)
101,103c101,108
< sprintf(buf, " %s%d = 0x%016llx", prefixes[y], x, newVal);
< outs << buf;
< regs[index] = newVal;
---
> int index = x + 8 * y;
> newVal = thread->readIntReg(index);
> if(regs[index] != newVal)
> {
> sprintf(buf, " %s%d = 0x%016llx", prefixes[y], x, newVal);
> outs << buf;
> regs[index] = newVal;
> }
106,110c111
< }
< for(int y = 0; y < 32; y++)
< {
< newVal = thread->readFloatRegBits(2 * y, 64);
< if(floats[y] != newVal)
---
> for(int y = 0; y < 32; y++)
112,114c113,119
< sprintf(buf, " F%d = 0x%016llx", y, newVal);
< outs << buf;
< floats[y] = newVal;
---
> newVal = thread->readFloatRegBits(2 * y, 64);
> if(floats[y] != newVal)
> {
> sprintf(buf, " F%d = 0x%016llx", 2 * y, newVal);
> outs << buf;
> floats[y] = newVal;
> }
115a121
> outs << endl;
117d122
< outs << endl;