Con Kolivas <kernel@xxxxxxxxxxx> wrote:
Because of the recent discussion about latency in the kernel I asked William Lee Irwin III to help create some instrumentation to determine where in the kernel there were still sustained periods of non-preemptible code. He hacked together this simple patch which times periods according to the preempt count.
Looks sane.
The patch appears to require CONFIG_PREEMPT enabled on uniprocessor and is i386 only at the moment.
Not sure what you mean by "on uniprocessor"? AFAICT the patch will work
as-is on uniprocessor and on SMP. Looks like it'll work with
CONFIG_PREEMPT=n, too, although that would be a slightly bizarre thing to
do.
+ print_symbol("%s\n",
+ __get_cpu_var(preempt_exit));
I'll change this to
print_symbol("%s",
__get_cpu_var(preempt_exit));
printk("\n");
so it doesn't make a mess with CONFIG_KALLSYMS=n.