Skip to content

Commit 64aab93

Browse files
dsahernacmel
authored andcommitted
perf script: look up thread using tid instead of pid
This allows the thread name to be dispalyed when dumping events: myapp 25118 [000] 450385.538815: context-switches ... myapp:worker 25119 [000] 450385.538894: context-switches ... Cc: Frederic Weisbecker <fweisbec@gmail.com> Cc: Ingo Molnar <mingo@elte.hu> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/1324578603-12762-4-git-send-email-dsahern@gmail.com Signed-off-by: David Ahern <dsahern@gmail.com> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
1 parent f5faf72 commit 64aab93

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎tools/perf/builtin-script.c‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -443,7 +443,7 @@ static int process_sample_event(struct perf_tool *tool __used,
443443
struct machine *machine)
444444
{
445445
struct addr_location al;
446-
struct thread *thread = machine__findnew_thread(machine, event->ip.pid);
446+
struct thread *thread = machine__findnew_thread(machine, event->ip.tid);
447447

448448
if (thread == NULL) {
449449
pr_debug("problem processing %d event, skipping it.\n",

0 commit comments

Comments
 (0)