lkml.org 
[lkml]   [2009]   [Apr]   [16]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 2/8] tracing: create automated trace defines
Mathieu Desnoyers wrote:
>> Are they? They're generally considered to be "free", because the call
>> and return are predicted 100% accurately.
>>
>>
>
> Adding a simple function call within the tracer fast path, in LTTng, has
> a very measurable performance impact on the tbench workload. This is why
> I don't use any function call-based trace clocks in LTTng, but rather my
> own inline trace clock.

I'm a bit concerned about all the code that tracing puts inline though.
It seems it would put quite a lot of icache overhead on the codepath
when the tracepoint is disabled, not least because its duplicated in
every instance of the tracepoint. And if the compiler decides to put
the unlikely() branch code out of line, then that's the same as making
it a function call (except that if it is a function call, all the
tracepoints will share the same code, and get a higher likelihood of
getting icache hits).


J


\
 
 \ /
  Last update: 2009-04-17 02:21    [from the cache]
©2003-2011 Jasper Spaans