Re: [RFC PATCH 1/3] Unified trace buffer

From: Linus Torvalds
Date: Thu Sep 25 2008 - 14:16:38 EST




On Thu, 25 Sep 2008, Steven Rostedt wrote:
>
> The one thing that seemed to me most apparent from talking to people
> at LPC, is that they want a simple ring buffer API. If every tracer that
> uses this must come up with its own time keeping management, I don't think
> this will be used at all (except by those that are maintaining tracers
> now).

No, no.

The timestamp code is all in the ring buffer code. That was why I refused
to have the layering without it.

And hell no, nobody should *ever* read the "tsc_delta" fields etc. Those
are entirely internal to the buffering. If any user _ever_ reads or writes
those on its own, it's a bug, plain and simple.

So when you read trace events, you should get the event data and the
timestamp from the trace buffer routines. Nobody should ever even _see_
the internal trace buffer implementation!

Linus
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/