All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jiri Olsa <jolsa@redhat.com>
To: Namhyung Kim <namhyung@kernel.org>
Cc: Arnaldo Carvalho de Melo <acme@kernel.org>,
	Ingo Molnar <mingo@kernel.org>,
	Peter Zijlstra <a.p.zijlstra@chello.nl>,
	Jiri Olsa <jolsa@kernel.org>, LKML <linux-kernel@vger.kernel.org>,
	kernel-team@lge.com, Jin Yao <yao.jin@linux.intel.com>,
	Milian Wolff <milian.wolff@kdab.com>
Subject: Re: [PATCH 2/2] perf tools: Show correct function name for srcline of callchains
Date: Wed, 1 Nov 2017 13:14:32 +0100	[thread overview]
Message-ID: <20171101121432.GB20353@krava> (raw)
In-Reply-To: <20171031020654.31163-2-namhyung@kernel.org>

On Tue, Oct 31, 2017 at 11:06:54AM +0900, Namhyung Kim wrote:
> When libbfd is not used, it doesn't show proper function name and reuse
> the original symbol of the sample.  That's because it passes the
> original sym to inline_list__append().  As `addr2line -f` returns
> function names as well, use that to create ad inline_sym and pass it to
> inline_list__append().
> 
> For example, following data shows that inlined entries of main have same
> name (main).
> 
> Before:
>   $ perf report -g srcline -q | head
>       45.22%  inlining     libm-2.26.so      [.] __hypot_finite
>               |
>               ---__hypot_finite ??:0
>                  |
>                  |--44.15%--hypot ??:0
>                  |          main complex:589
>                  |          main complex:597
>                  |          main complex:654
>                  |          main complex:664
>                  |          main inlining.cpp:14
> 
> After:
>   $ perf report -g srcline -q | head
>       45.22%  inlining     libm-2.26.so      [.] __hypot_finite
>               |
>               ---__hypot_finite
>                  |
>                  |--44.15%--hypot
>                  |          std::__complex_abs complex:589 (inlined)
>                  |          std::abs<double> complex:597 (inlined)
>                  |          std::_Norm_helper<true>::_S_do_it<double> complex:654 (inlined)
>                  |          std::norm<double> complex:664 (inlined)
>                  |          main inlining.cpp:14
> 
> Cc: Jin Yao <yao.jin@linux.intel.com>
> Cc: Milian Wolff <milian.wolff@kdab.com>
> Signed-off-by: Namhyung Kim <namhyung@kernel.org>

looks ok

Reviewed-by: Jiri Olsa <jolsa@kernel.org>

jirka

  parent reply	other threads:[~2017-11-01 12:14 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-10-31  2:06 [PATCH 1/2] perf tools: Fix memory leak in addr2inlines() Namhyung Kim
2017-10-31  2:06 ` [PATCH 2/2] perf tools: Show correct function name for srcline of callchains Namhyung Kim
     [not found]   ` <2208660.mvSdWdKhUF@milian-kdab2>
2017-11-01 12:05     ` Namhyung Kim
2017-11-01 14:41       ` Arnaldo Carvalho de Melo
2017-11-01 12:14   ` Jiri Olsa [this message]
2017-11-03 14:24   ` [tip:perf/core] perf srcline: " tip-bot for Namhyung Kim
2017-11-01 12:13 ` [PATCH 1/2] perf tools: Fix memory leak in addr2inlines() Jiri Olsa
2017-11-01 14:42   ` Arnaldo Carvalho de Melo
2017-11-03 14:23 ` [tip:perf/core] perf srcline: " tip-bot for Namhyung Kim

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20171101121432.GB20353@krava \
    --to=jolsa@redhat.com \
    --cc=a.p.zijlstra@chello.nl \
    --cc=acme@kernel.org \
    --cc=jolsa@kernel.org \
    --cc=kernel-team@lge.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=milian.wolff@kdab.com \
    --cc=mingo@kernel.org \
    --cc=namhyung@kernel.org \
    --cc=yao.jin@linux.intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.