All of lore.kernel.org
 help / color / mirror / Atom feed
From: Franck Bui-Huu <vagabon.xyz@gmail.com>
To: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com>
Cc: Arnaldo Carvalho de Melo <acme@ghostprotocols.net>,
	lkml <linux-kernel@vger.kernel.org>,
	2nddept-manager@sdl.hitachi.co.jp
Subject: Re: [PATCH] perf-probe: make "perf-probe -L <function>" display the absolute path and absolute line number
Date: Thu, 13 Jan 2011 20:42:26 +0100	[thread overview]
Message-ID: <m34o9c8ual.fsf@gmail.com> (raw)
In-Reply-To: <4D2EDBE4.3060608@hitachi.com> (Masami Hiramatsu's message of "Thu, 13 Jan 2011 20:03:00 +0900")

Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> writes:

> (2011/01/13 19:20), Franck Bui-Huu wrote:
>> From: Franck Bui-Huu <fbuihuu@gmail.com>
>> 
>> It should be more usefull to get the full location of the function
>
>> (absolute line number + full path) instead of repeating the name of
>> the function and the start line number given by the command line.
>> 
>> So we had before:
>> 
>>    $ perf probe -L schedule | head -n3
>>    <schedule:0>
>>          0  asmlinkage void __sched schedule(void)
>>          1  {
>> 
>> and now we get:
>> 
>>    $ perf probe -L schedule | head -n3
>>    </usr/src/debug/kernel-2.6.35.fc14/linux-2.6.35.x86_64/kernel/sched.c:3813>
>>          0  asmlinkage void __sched schedule(void)
>>          1  {
>
> Indeed, it could be useful for users to see where the function is...
>
> However, I think that should be optional, because the output lines
> have the relative line numbers from the function, and those numbers
> are important for users who want to probe a specific line by using
> function relative line numbers. e.g. "schedule:10"
>
> And with that option, I'd suggest to show absolute line numbers on each line.
>
>   $ perf probe -L schedule:0-1 --by-source
>   </usr/src/debug/kernel-2.6.35.fc14/linux-2.6.35.x86_64/kernel/sched.c:3813>
>      3813  asmlinkage void __sched schedule(void)
>      3814  {
>
> Or, just show source file as an additional information.
>
>   $ perf probe -L schedule:0-1
>   <schedule@/usr/src/debug/kernel-2.6.35.fc14/linux-2.6.35.x86_64/kernel/sched.c:0>
>         0  asmlinkage void __sched schedule(void)
>         1  {
>
> I just would like to keep the consistency of the output/input format.

Well, for consistency, I thought that the additional information (given
inside angle brackets) should always be the same: a full path and an
absolute line number which clearly identify which source file perf-probe
is listing.

-- 
		Franck

  reply	other threads:[~2011-01-13 20:09 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-01-13 10:20 [PATCH] perf-probe: make "perf-probe -L <function>" display the absolute path and absolute line number Franck Bui-Huu
2011-01-13 11:03 ` Masami Hiramatsu
2011-01-13 19:42   ` Franck Bui-Huu [this message]
2011-01-14  3:22     ` Masami Hiramatsu
2011-01-14  9:03       ` Franck Bui-Huu
2011-01-14 10:08         ` Masami Hiramatsu
2011-01-14 10:33         ` Masami Hiramatsu
2011-01-14 19:53           ` Franck Bui-Huu

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=m34o9c8ual.fsf@gmail.com \
    --to=vagabon.xyz@gmail.com \
    --cc=2nddept-manager@sdl.hitachi.co.jp \
    --cc=acme@ghostprotocols.net \
    --cc=linux-kernel@vger.kernel.org \
    --cc=masami.hiramatsu.pt@hitachi.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.