Re: top hogs CPU in 2.6: kallsyms_lookup is very slow

From: William Lee Irwin III
Date: Thu Sep 16 2004 - 06:55:56 EST


On Thu, Sep 16, 2004 at 02:28:26PM +0300, Denis Vlasenko wrote:
> I see 2.6.9-rc2 being slower than 2.4.27-rc3
> on a Pentium 66, 80 MB RAM.
> Specifically:
> top on idle machine sucks ~40% CPU while in 2.4
> it takes only ~6%
> I recompiled 2.6 with HZ=100 and with slab debugging
> off. This helped a bit (wget was slow too),
> but top still hogs CPU.
> I did 'strace -T -tt top b n 1' under both kernels,
> postprocessed it a bit:

The following patches in -mm are likely to help top(1).

kallsyms-data-size-reduction--lookup-speedup.patch
kallsyms data size reduction / lookup speedup

inconsistent-kallsyms-fix.patch
Inconsistent kallsyms fix

kallsyms-correct-type-char-in-proc-kallsyms.patch
kallsyms: correct type char in /proc/kallsyms

kallsyms-fix-sparc-gibberish.patch
kallsyms: fix sparc gibberish

As for all syscalls/etc. being slower by 50%-100%, I suggest toning
down HZ (we desperately need to go tickless) and seeing if it persists.
Also please check that time isn't twice as fast as it should be in 2.6.


-- wli
-
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/