lkml.org 
[lkml]   [2004]   [Aug]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [patch] Latency Tracer, voluntary-preempt-2.6.8-rc4-O6
Ingo Molnar wrote:
> * Paulo Marques <pmarques@grupopie.com> wrote:
>
>
>>>yeah. Maybe someone will find the time to improve the algorithm. But
>>>it's not a highprio thing.
>>
>>Well, I found some time and decided to give it a go :)
>
>
> great, your patch is looking really good!

Thanks :)

>
>>The original algorithm took, on average, 1340us per lookup on my P4
>>2.8GHz. The compile settings for the test are not the same on the
>>kernel, so this can be only compared against other results from the
>>same setup.
>
>
> ouch. I consider fixing this a quality of implementation issue.
>
>
>>With the attached patch it takes 14us per lookup. This is almost a
>>100x improvement.
>
>
> wow! I have tried your patch and /proc/latency_trace now produces
> instantaneous output.

Good to ear

>...
>
> your patch doesnt add all that much of code. It adds 288 bytes to .text
> and 64 bytes to .data. A typical .config generates 180K of compressed
> kallsyms data (with !KALLSYMS_ALL), so your patch increases the kallsyms
> overhead by a mere 0.2%. So it's really not an issue - especially since
> kallsyms can be disabled in .config.

The 64 bytes of data can be further tuned using the KALLSYMS_STEM_MARKS
define.

Setting it to 16 instead of 8 will speed up the algorithm by _almost_
twice the speed. As the number grows higher, the speed up is less
noticeable.

>...
>
> the standard way is to add the extra initializers. The gcc folks feel
> that those rare cases where gcc gets it wrong justify the benefit of
> catching lots of real bugs. I've added the extra initialization to -O8.

Ok, now that I know how it should be done, next time I'll add them myself :)

--
Paulo Marques - www.grupopie.com
"In a world without walls and fences who needs windows and gates?"
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 14:05    [W:0.137 / U:1.992 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site