forked from OSchip/llvm-project
[trace][intelpt] Instruction count in trace info
Added a line to `thread trace dump info` results which shows total number of instructions executed until now. Differential Revision: https://reviews.llvm.org/D122076
This commit is contained in:
parent
ae0ae91903
commit
8271220a99
|
@ -110,7 +110,10 @@ void TraceIntelPT::DumpTraceInfo(Thread &thread, Stream &s, bool verbose) {
|
|||
s.Printf(", not traced\n");
|
||||
return;
|
||||
}
|
||||
s.Printf("\n Raw trace size: %zu bytes\n", *raw_size);
|
||||
s.Printf("\n");
|
||||
s.Printf(" Raw trace size: %zu bytes\n", *raw_size);
|
||||
s.Printf(" Total number of instructions: %zu\n",
|
||||
Decode(thread)->GetInstructions().size());
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
|
@ -38,4 +38,5 @@ class TestTraceDumpInfo(TraceIntelPTTestCaseBase):
|
|||
substrs=['''Trace technology: intel-pt
|
||||
|
||||
thread #1: tid = 3842849
|
||||
Raw trace size: 4096 bytes'''])
|
||||
Raw trace size: 4096 bytes
|
||||
Total number of instructions: 21'''])
|
||||
|
|
Loading…
Reference in New Issue