Re: [PATCH 0/2 v2] Syscalls tracing

Ingo Molnar
2009-03-13T16:18:30Z

* Ingo Molnar <mingo@elte.hu> wrote:

>
> * Frederic Weisbecker <fweisbec@gmail.com> wrote:
>
> > On Fri, Mar 13, 2009 at 03:42:10PM +0100, Frederic Weisbecker wrote:
> > > tracing/syscalls: core infrastructure to trace syscalls
> > >
> > > This new iteration addresses a good part of the previous reviews.
> >
> >
> > Ah I just discovered that you applied the previous version
> > today. But the v2 is not a delta :-s
> >
> > I can rebase them but not until Sunday.
>
> No problem, i'll deltify them and will have a look.

Ok, i did the deltas, tidied them up and put them into
tip:tracing/syscalls.

Nice stuff! Here's some sample output:

aldebaran:/debug/tracing> head trace
# tracer: syscall
#
# TASK-PID CPU# TIMESTAMP FUNCTION
# | | | | |
<...>-4405 [003] 188.452934: sys_dup2(oldfd: a, newfd: 1)
<...>-4405 [003] 188.452939: sys_dup2 -> 0x1
<...>-4405 [003] 188.452940: sys_fcntl(fd: a, cmd: 1, arg: 0)
<...>-4405 [003] 188.452941: sys_fcntl -> 0x1
<...>-4405 [003] 188.452942: sys_close(fd: a)
<...>-4405 [003] 188.452943: sys_close -> 0x0

A suggestion:

- Would be nice for all the registered syscalls to show up
under /debug/events/syscalls/, one directory per syscall,
with an 'enable' and a 'format' file as well.

And a bugreport:

- when using function_graph (after having used the syscall
tracer) i dont see graph traces anymore - only the syscall
trace entries:

# tracer: function_graph
#
# CPU DURATION FUNCTION CALLS
# | | | | | | |
##### CPU 9 buffer started ####
at-spi-registry-3063 [009] 322.915058: sys_read -> 0x5a8
at-spi-registry-3063 [009] 322.915059: sys_write(fd: 6, buf: 632840, count: 5a8)
at-spi-registry-3063 [009] 322.915062: sys_write -> 0x5a8
at-spi-registry-3063 [009] 322.915062: sys_read(fd: 4, buf: 632840, count: 40000)

That's not intended, right?

Ingo