[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <c62985530811260332m20a3388dy7bdc1fc15811898d@mail.gmail.com>
Date: Wed, 26 Nov 2008 12:32:41 +0100
From: "Frédéric Weisbecker" <fweisbec@...il.com>
To: "Steven Rostedt" <rostedt@...dmis.org>
Cc: "Ingo Molnar" <mingo@...e.hu>,
"Linux Kernel" <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] tracing/function-return-tracer: set a more human readable output
2008/11/26 Steven Rostedt <rostedt@...dmis.org>:
>
> On Wed, 26 Nov 2008, Ingo Molnar wrote:
>>
>> The changes would be:
>>
>> 1) Compression of non-nested calls into a single line.
>>
>> Implementing this probably necessiates some trickery with the
>> ring-buffer: we'd have to look at the next entry as well and see
>> whether it closes the function call.
>
> The latency_trace file does this already:
>
> You can look into the trace buffer without moving it with:
>
> entry = ring_buffer_iter_peek(iter->buffer_iter[iter->cpu], &ts);
>
> where, ts will give you the time stamp, it can be NULL if you do not care.
>
> When your print function is called, the item in the ring buffer has
> already been consumed. So the peek will give you the next item in the ring
> buffer.
>>
>> 2) Adding a closing ';' semicolon to single-line calls. It's the C
>> syntax and i'm missing it :-)
>>
>> 3) The first column: single-character visual shortcuts for "overhead".
>> This is a concept we used in the -rt tracer and it still lives in
>> the latency tracer bits of ftrace and is quite useful:
>>
>> '+' means "overhead spike": overhead is above 10 usecs.
>> '!' means "large overhead": overhead is above 100 usecs.
>>
>> These give at-a-glance hotspot analysis - hotspots are easier to
>> miss as pure numbers.
>
> The latency_trace file has this too. And it uses the above peek to figure
> it out ;-)
That's right, the latency_trace does it. But it is based on a
ring-buffer entry timestamp.
I wanted to use ring-buffer entry timestamp, but it would be hard to
calculate the duration
since the return trace of a function doesn't often follow immediately
its entry trace.
And I can't reuse lat_print_timestamp() because I need the nsec
remaining part....
This is too specific to reuse latency_trace...
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists