From: Chase Douglas on
On May 19, 2010, at 3:57 PM, Masami Hiramatsu wrote:
> Hi,
>
> Here is a series of patches which improves perf probe to
> add below features. I cleared some coding style issues.
>
> - String support, which enables dynamic events to trace string
> variables instead of its address.
>
> - Fixed-index array entry support, which allows user to trace
> an array entry with digit index, e.g. array[0].
>
> - Global/static variable support, which allows user to trace
> global or static variables, as same as local one.
>
>
> TODOs (possible features):
> - Support dynamic array-indexing (var[var2])
> - Support force type-casting ((type)var)
> - Show what deta-structure member is assigned to each argument.
> - Better support for probes on modules
> - More debugger like enhancements(%next, --disasm, etc.)
>
> Thank you,
>
> ---
>
> Masami Hiramatsu (4):
> perf probe: Support static and global variables
> perf probe: Support tracing an entry of array
> perf probe: Support "string" type
> tracing/kprobes: Support "string" type

What's the status of these patches? They seem very useful to me, but I
don't see them in Arnaldo's tree at git.kernel.org.

Thanks,

-- Chase
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo(a)vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
From: Arnaldo Carvalho de Melo on
Em Mon, Jul 05, 2010 at 10:30:47AM -0400, Chase Douglas escreveu:
> On May 19, 2010, at 3:57 PM, Masami Hiramatsu wrote:
> > Hi,
> >
> > Here is a series of patches which improves perf probe to
> > add below features. I cleared some coding style issues.
> >
> > - String support, which enables dynamic events to trace string
> > variables instead of its address.
> >
> > - Fixed-index array entry support, which allows user to trace
> > an array entry with digit index, e.g. array[0].
> >
> > - Global/static variable support, which allows user to trace
> > global or static variables, as same as local one.
> >
> >
> > TODOs (possible features):
> > - Support dynamic array-indexing (var[var2])
> > - Support force type-casting ((type)var)
> > - Show what deta-structure member is assigned to each argument.
> > - Better support for probes on modules
> > - More debugger like enhancements(%next, --disasm, etc.)
> >
> > Thank you,
> >
> > ---
> >
> > Masami Hiramatsu (4):
> > perf probe: Support static and global variables
> > perf probe: Support tracing an entry of array
> > perf probe: Support "string" type
> > tracing/kprobes: Support "string" type
>
> What's the status of these patches? They seem very useful to me, but I
> don't see them in Arnaldo's tree at git.kernel.org.

Thanks for reminding me about these ones, will look at them to get them
in perf/core.

- Arnaldo
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo(a)vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
From: Masami Hiramatsu on
Arnaldo Carvalho de Melo wrote:
> Em Mon, Jul 05, 2010 at 10:30:47AM -0400, Chase Douglas escreveu:
>> On May 19, 2010, at 3:57 PM, Masami Hiramatsu wrote:
>>> Hi,
>>>
>>> Here is a series of patches which improves perf probe to
>>> add below features. I cleared some coding style issues.
>>>
>>> - String support, which enables dynamic events to trace string
>>> variables instead of its address.
>>>
>>> - Fixed-index array entry support, which allows user to trace
>>> an array entry with digit index, e.g. array[0].
>>>
>>> - Global/static variable support, which allows user to trace
>>> global or static variables, as same as local one.
>>>
>>>
>>> TODOs (possible features):
>>> - Support dynamic array-indexing (var[var2])
>>> - Support force type-casting ((type)var)
>>> - Show what deta-structure member is assigned to each argument.
>>> - Better support for probes on modules
>>> - More debugger like enhancements(%next, --disasm, etc.)
>>>
>>> Thank you,
>>>
>>> ---
>>>
>>> Masami Hiramatsu (4):
>>> perf probe: Support static and global variables
>>> perf probe: Support tracing an entry of array
>>> perf probe: Support "string" type
>>> tracing/kprobes: Support "string" type
>> What's the status of these patches? They seem very useful to me, but I
>> don't see them in Arnaldo's tree at git.kernel.org.
>
> Thanks for reminding me about these ones, will look at them to get them
> in perf/core.

Thanks for picking it up. And I need to tell it to Sriker because this
will affect his uprobes patchset (ftrace part).
(Actually, my original plan was to update the patchset onto
his uprobes patchset.)

Sriker, the 1st patch in this series will add many macros/functions
into trace_kprobe.c. This will directly affect your 8th patch of uprobes,
which splits fetch functions out from trace_kprobe.c.
Is that OK for you?

Thank you,

--
Masami HIRAMATSU
2nd Research Dept.
Hitachi, Ltd., Systems Development Laboratory
E-mail: masami.hiramatsu.pt(a)hitachi.com
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo(a)vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
From: Arnaldo Carvalho de Melo on
Em Mon, Jul 05, 2010 at 02:44:50PM -0300, Arnaldo Carvalho de Melo escreveu:
> Em Mon, Jul 05, 2010 at 10:30:47AM -0400, Chase Douglas escreveu:
> > On May 19, 2010, at 3:57 PM, Masami Hiramatsu wrote:
> > > Here is a series of patches which improves perf probe to
> > > add below features. I cleared some coding style issues.

> > > - String support, which enables dynamic events to trace string
> > > variables instead of its address.

> > > - Fixed-index array entry support, which allows user to trace
> > > an array entry with digit index, e.g. array[0].

> > > - Global/static variable support, which allows user to trace
> > > global or static variables, as same as local one.

> > What's the status of these patches? They seem very useful to me, but I
> > don't see them in Arnaldo's tree at git.kernel.org.

> Thanks for reminding me about these ones, will look at them to get them
> in perf/core.

Masami, I fixed up a minor conflict and while trying it this happened:

[root(a)emilia ~]# perf probe -a 'bio_split bi->bi_io_vec[0]'
kprobe_events file does not exist - please rebuild kernel with CONFIG_KPROBE_EVENT.
Error: Failed to add events. (-1)

But on a second try:

[root(a)emilia ~]# l /sys/kernel/debug/tracing/kprobe_events
-rw-r--r-- 1 root root 0 Jul 5 18:37 /sys/kernel/debug/tracing/kprobe_events
[root(a)emilia ~]# cat /sys/kernel/debug/tracing/kprobe_events
[root(a)emilia ~]#
[root(a)emilia ~]# perf probe -a 'bio_split bi->bi_io_vec[0]'
Add new event:
probe:bio_split (on bio_split with bi_io_vec=bi->bi_io_vec[0])

You can now use it on all perf tools, such as:

perf record -e probe:bio_split -aR sleep 1

[root(a)emilia ~]# cat /sys/kernel/debug/tracing/kprobe_events
p:probe/bio_split bio_split bi_io_vec=+0(+72(%di)):u64
[root(a)emilia ~]#

I'll push it as is, posting the pull request with the patches today,
please check if everything is ok and send fixups if needed,

Thanks,

- Arnaldo
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo(a)vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
From: Srikar Dronamraju on
> >>> Masami Hiramatsu (4):
> >>> perf probe: Support static and global variables
> >>> perf probe: Support tracing an entry of array
> >>> perf probe: Support "string" type
> >>> tracing/kprobes: Support "string" type
> >> What's the status of these patches? They seem very useful to me, but I
> >> don't see them in Arnaldo's tree at git.kernel.org.
> >
> > Thanks for reminding me about these ones, will look at them to get them
> > in perf/core.
>
> Thanks for picking it up. And I need to tell it to Sriker because this
> will affect his uprobes patchset (ftrace part).
> (Actually, my original plan was to update the patchset onto
> his uprobes patchset.)
>
> Sriker, the 1st patch in this series will add many macros/functions
> into trace_kprobe.c. This will directly affect your 8th patch of uprobes,
> which splits fetch functions out from trace_kprobe.c.
> Is that OK for you?

Okay, I will keep rebasing to the latest tip/master before sending out
patches for review. So I will continue to do the same when pushing the
v8 patches.

--
Thanks and Regards
Srikar
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo(a)vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/