diff options
author | Joseph Schuchart <joseph.schuchart@tu-dresden.de> | 2014-07-10 07:50:51 -0400 |
---|---|---|
committer | Arnaldo Carvalho de Melo <acme@redhat.com> | 2014-07-16 16:57:33 -0400 |
commit | 0f5f5bcd112292f14b75750dde7461463bb1c7bb (patch) | |
tree | bb87bcdd3d703c5f397d46db0c7bd7c14d144e62 /tools/perf/scripts/python/futex-contention.py | |
parent | 05f832e3a267d6e45d092595bdf9339d127ea137 (diff) |
perf script: Add callchain to generic and tracepoint events
This provides valuable information for tracing performance problems.
Since this change alters the interface for the python scripts, also
adjust the script generation and the provided scripts.
Signed-off-by: Joseph Schuchart <joseph.schuchart@tu-dresden.de>
Acked-by: Thomas Ilsche <thomas.ilsche@tu-dresden.de>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Namhyung Kim <namhyung@gmail.com>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Thomas Ilsche <thomas.ilsche@tu-dresden.de>
Link: http://lkml.kernel.org/r/53BE7E1B.10503@tu-dresden.de
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'tools/perf/scripts/python/futex-contention.py')
-rw-r--r-- | tools/perf/scripts/python/futex-contention.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/tools/perf/scripts/python/futex-contention.py b/tools/perf/scripts/python/futex-contention.py index 11e70a388d41..0f5cf437b602 100644 --- a/tools/perf/scripts/python/futex-contention.py +++ b/tools/perf/scripts/python/futex-contention.py | |||
@@ -21,7 +21,7 @@ thread_blocktime = {} | |||
21 | lock_waits = {} # long-lived stats on (tid,lock) blockage elapsed time | 21 | lock_waits = {} # long-lived stats on (tid,lock) blockage elapsed time |
22 | process_names = {} # long-lived pid-to-execname mapping | 22 | process_names = {} # long-lived pid-to-execname mapping |
23 | 23 | ||
24 | def syscalls__sys_enter_futex(event, ctxt, cpu, s, ns, tid, comm, | 24 | def syscalls__sys_enter_futex(event, ctxt, cpu, s, ns, tid, comm, callchain, |
25 | nr, uaddr, op, val, utime, uaddr2, val3): | 25 | nr, uaddr, op, val, utime, uaddr2, val3): |
26 | cmd = op & FUTEX_CMD_MASK | 26 | cmd = op & FUTEX_CMD_MASK |
27 | if cmd != FUTEX_WAIT: | 27 | if cmd != FUTEX_WAIT: |
@@ -31,7 +31,7 @@ def syscalls__sys_enter_futex(event, ctxt, cpu, s, ns, tid, comm, | |||
31 | thread_thislock[tid] = uaddr | 31 | thread_thislock[tid] = uaddr |
32 | thread_blocktime[tid] = nsecs(s, ns) | 32 | thread_blocktime[tid] = nsecs(s, ns) |
33 | 33 | ||
34 | def syscalls__sys_exit_futex(event, ctxt, cpu, s, ns, tid, comm, | 34 | def syscalls__sys_exit_futex(event, ctxt, cpu, s, ns, tid, comm, callchain, |
35 | nr, ret): | 35 | nr, ret): |
36 | if thread_blocktime.has_key(tid): | 36 | if thread_blocktime.has_key(tid): |
37 | elapsed = nsecs(s, ns) - thread_blocktime[tid] | 37 | elapsed = nsecs(s, ns) - thread_blocktime[tid] |