summaryrefslogtreecommitdiff
path: root/simpleperf
diff options
context:
space:
mode:
authorMark Hansen <markhansen@google.com>2021-09-19 22:52:02 +0000
committerMark Hansen <markhansen@google.com>2021-09-19 22:52:11 +0000
commit26ce2ed10213913fbda29db4a35ee0f7a95d1efa (patch)
tree9a1b9240292aa30340ddb6d4e5cc5e93a2829ed4 /simpleperf
parentc57a063a79ee6279bccbf6889f2d85caa6309cd9 (diff)
downloadextras-26ce2ed10213913fbda29db4a35ee0f7a95d1efa.tar.gz
Add a tab in front of stack samples in report_sample.py
This brings the output closer to the output of linux-perf-tool script. Some tools (e.g. FlameScope) optimise skipping lines starting with tabs, this should help those tools go faster. BUG=200473657 Change-Id: I2144e4dbe83f82d14844082d5dedec14dc7f30fb
Diffstat (limited to 'simpleperf')
-rwxr-xr-xsimpleperf/scripts/report_sample.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/simpleperf/scripts/report_sample.py b/simpleperf/scripts/report_sample.py
index 7af9f2c3..dc178c08 100755
--- a/simpleperf/scripts/report_sample.py
+++ b/simpleperf/scripts/report_sample.py
@@ -67,10 +67,10 @@ def report_sample(
print('%s\t%d/%d [%03d] %d.%06d: %d %s:' % (sample.thread_comm,
sample.pid, sample.tid, sample.cpu, sec,
usec, sample.period, event.name))
- print('%16x %s (%s)' % (sample.ip, symbol.symbol_name, symbol.dso_name))
+ print('\t%16x %s (%s)' % (sample.ip, symbol.symbol_name, symbol.dso_name))
for i in range(callchain.nr):
entry = callchain.entries[i]
- print('%16x %s (%s)' % (entry.ip, entry.symbol.symbol_name, entry.symbol.dso_name))
+ print('\t%16x %s (%s)' % (entry.ip, entry.symbol.symbol_name, entry.symbol.dso_name))
if show_tracing_data:
data = lib.GetTracingDataOfCurrentSample()
if data: