just commit what i need for dumping traces compatible with intel's casper
--HG-- extra : convert_revision : a0c4a68a576fa771fd553eaedd6a07255a04dca2
This commit is contained in:
parent
6e192b5704
commit
3532a661c5
|
@ -52,14 +52,17 @@ void
|
||||||
Trace::InstRecord::dump(ostream &outs)
|
Trace::InstRecord::dump(ostream &outs)
|
||||||
{
|
{
|
||||||
if (flags[INTEL_FORMAT]) {
|
if (flags[INTEL_FORMAT]) {
|
||||||
ccprintf(outs, "%7d ) ", cycle);
|
if (cpu->system->name() == trace_system) {
|
||||||
outs << "0x" << hex << PC << ":\t";
|
ccprintf(outs, "%7d ) ", cycle);
|
||||||
if (staticInst->isLoad()) {
|
outs << "0x" << hex << PC << ":\t";
|
||||||
outs << "<RD 0x" << hex << addr;
|
if (staticInst->isLoad()) {
|
||||||
outs << ">";
|
outs << "<RD 0x" << hex << addr;
|
||||||
} else if (staticInst->isStore()) {
|
outs << ">";
|
||||||
outs << "<WR 0x" << hex << addr;
|
} else if (staticInst->isStore()) {
|
||||||
outs << ">";
|
outs << "<WR 0x" << hex << addr;
|
||||||
|
outs << ">";
|
||||||
|
}
|
||||||
|
outs << endl;
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
if (flags[PRINT_CYCLE])
|
if (flags[PRINT_CYCLE])
|
||||||
|
@ -135,15 +138,17 @@ Trace::InstRecord::dump(ostream &outs)
|
||||||
|
|
||||||
if (flags[PRINT_CP_SEQ] && cp_seq_valid)
|
if (flags[PRINT_CP_SEQ] && cp_seq_valid)
|
||||||
outs << " CPSeq=" << dec << cp_seq;
|
outs << " CPSeq=" << dec << cp_seq;
|
||||||
|
|
||||||
|
//
|
||||||
|
// End of line...
|
||||||
|
//
|
||||||
|
outs << endl;
|
||||||
}
|
}
|
||||||
//
|
|
||||||
// End of line...
|
|
||||||
//
|
|
||||||
outs << endl;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
vector<bool> Trace::InstRecord::flags(NUM_BITS);
|
vector<bool> Trace::InstRecord::flags(NUM_BITS);
|
||||||
|
string Trace::InstRecord::trace_system;
|
||||||
|
|
||||||
////////////////////////////////////////////////////////////////////////
|
////////////////////////////////////////////////////////////////////////
|
||||||
//
|
//
|
||||||
|
@ -184,6 +189,9 @@ Param<bool> exe_trace_print_cp_seq(&exeTraceParams, "print_cpseq",
|
||||||
"print correct-path sequence number", false);
|
"print correct-path sequence number", false);
|
||||||
Param<bool> exe_trace_intel_format(&exeTraceParams, "intel_format",
|
Param<bool> exe_trace_intel_format(&exeTraceParams, "intel_format",
|
||||||
"print trace in intel compatible format", false);
|
"print trace in intel compatible format", false);
|
||||||
|
Param<string> exe_trace_system(&exeTraceParams, "trace_system",
|
||||||
|
"print trace of which system (client or server)",
|
||||||
|
"client");
|
||||||
|
|
||||||
|
|
||||||
//
|
//
|
||||||
|
@ -204,6 +212,7 @@ Trace::InstRecord::setParams()
|
||||||
flags[PRINT_FETCH_SEQ] = exe_trace_print_fetchseq;
|
flags[PRINT_FETCH_SEQ] = exe_trace_print_fetchseq;
|
||||||
flags[PRINT_CP_SEQ] = exe_trace_print_cp_seq;
|
flags[PRINT_CP_SEQ] = exe_trace_print_cp_seq;
|
||||||
flags[INTEL_FORMAT] = exe_trace_intel_format;
|
flags[INTEL_FORMAT] = exe_trace_intel_format;
|
||||||
|
trace_system = exe_trace_system;
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
|
|
@ -148,6 +148,7 @@ class InstRecord : public Record
|
||||||
};
|
};
|
||||||
|
|
||||||
static std::vector<bool> flags;
|
static std::vector<bool> flags;
|
||||||
|
static std::string trace_system;
|
||||||
|
|
||||||
static void setParams();
|
static void setParams();
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue