public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [Patch]fixed: perf cannot show existing process callgraph symbol
@ 2010-02-05 17:02 austin_zhang
  2010-02-08 15:57 ` [tip:perf/core] perf record: Fix " tip-bot for austin_zhang@linux.intel.com
  0 siblings, 1 reply; 2+ messages in thread
From: austin_zhang @ 2010-02-05 17:02 UTC (permalink / raw)
  To: a.p.zijlstra, paulus, mingo, acme; +Cc: linux-kernel, austin.zhang

When 'perf record -g' a existing process, even with debuginfo
packages, still cannnot get symbol from 'perf report'.

try:
perf record -g -p `pidof xxx` -f
perf report

    68.26%    :1181           b74870f2  [.] 0x000000b74870f2
              |
              |--32.09%-- 0xb73b5b44
              |          0xb7487102
              |          0xb748a4e2
              |          0xb748633d
              |          0xb73b41cd
              |          0xb73b4467
              |          0xb747d531

The reason is: for existing process, in __cmd_record(),
the pid is 0 rather than the existing process id.

Signed-off-by: Austin Zhang <austin_zhang@linux.intel.com>
---
 tools/perf/builtin-record.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/tools/perf/builtin-record.c b/tools/perf/builtin-record.c
index 2654253..1d62d2a 100644
--- a/tools/perf/builtin-record.c
+++ b/tools/perf/builtin-record.c
@@ -552,7 +552,7 @@ static int __cmd_record(int argc, const char **argv)
 	}

 	if (!system_wide && profile_cpu == -1)
-		event__synthesize_thread(pid, process_synthesized_event,
+		event__synthesize_thread(target_pid, process_synthesized_event,
 					 session);
 	else
 		event__synthesize_threads(process_synthesized_event, session);
-- 
1.6.1.3


^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2010-02-08 15:58 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-02-05 17:02 [Patch]fixed: perf cannot show existing process callgraph symbol austin_zhang
2010-02-08 15:57 ` [tip:perf/core] perf record: Fix " tip-bot for austin_zhang@linux.intel.com

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox