This revision was automatically updated to reflect the committed changes. Closed by commit rG8271220a9981: [trace][intelpt] Instruction count in trace info (authored by zrthxn).
Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D122076/new/ https://reviews.llvm.org/D122076 Files: lldb/source/Plugins/Trace/intel-pt/TraceIntelPT.cpp lldb/test/API/commands/trace/TestTraceDumpInfo.py Index: lldb/test/API/commands/trace/TestTraceDumpInfo.py =================================================================== --- lldb/test/API/commands/trace/TestTraceDumpInfo.py +++ lldb/test/API/commands/trace/TestTraceDumpInfo.py @@ -38,4 +38,5 @@ substrs=['''Trace technology: intel-pt thread #1: tid = 3842849 - Raw trace size: 4096 bytes''']) + Raw trace size: 4096 bytes + Total number of instructions: 21''']) Index: lldb/source/Plugins/Trace/intel-pt/TraceIntelPT.cpp =================================================================== --- lldb/source/Plugins/Trace/intel-pt/TraceIntelPT.cpp +++ lldb/source/Plugins/Trace/intel-pt/TraceIntelPT.cpp @@ -110,7 +110,10 @@ 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; }
Index: lldb/test/API/commands/trace/TestTraceDumpInfo.py =================================================================== --- lldb/test/API/commands/trace/TestTraceDumpInfo.py +++ lldb/test/API/commands/trace/TestTraceDumpInfo.py @@ -38,4 +38,5 @@ substrs=['''Trace technology: intel-pt thread #1: tid = 3842849 - Raw trace size: 4096 bytes''']) + Raw trace size: 4096 bytes + Total number of instructions: 21''']) Index: lldb/source/Plugins/Trace/intel-pt/TraceIntelPT.cpp =================================================================== --- lldb/source/Plugins/Trace/intel-pt/TraceIntelPT.cpp +++ lldb/source/Plugins/Trace/intel-pt/TraceIntelPT.cpp @@ -110,7 +110,10 @@ 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; }
_______________________________________________ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits