[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <19f34abd0806111154q77739a2m8dcff24e2f9a3922@mail.gmail.com>
Date: Wed, 11 Jun 2008 20:54:46 +0200
From: "Vegard Nossum" <vegard.nossum@...il.com>
To: "Arjan van de Ven" <arjan@...radead.org>
Cc: "Rusty Russell" <rusty@...tcorp.com.au>, mingo@...e.hu,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH] modules: Take a shortcut for checking if an address is in a module
On 6/11/08, Arjan van de Ven <arjan@...radead.org> wrote:
> On Wed, 11 Jun 2008 21:12:08 +1000
> Rusty Russell <rusty@...tcorp.com.au> wrote:
>
> > On Wednesday 11 June 2008 06:05:19 Arjan van de Ven wrote:
> > > From: Arjan van de Ven <arjan@...ux.intel.com>
> > > Subject: [PATCH] modules: Take a shortcut for checking if an
> > > address is in a module
> > >
> > > Various pieces of the kernel (lockdep, latencytop, etc) tend to
> > > store backtraces, sometimes at a relatively high frequency. In
> > > itself this isn't a big performance deal (after all you're using
> > > diagnostics features), but there have been some complaints from
> > > people who have over 100 modules loaded that this is a tad too slow.
Would it be overkill to simply drop the module addresses in an rbtree
and use that instead of a linear search over all the modules?
It would probably take a fair number of lines in C, and with a little
memory overhead, but the speed-up should be great. Should I give it a
try? (It would be arch-independent too.)
Vegard
--
"The animistic metaphor of the bug that maliciously sneaked in while
the programmer was not looking is intellectually dishonest as it
disguises that the error is the programmer's own creation."
-- E. W. Dijkstra, EWD1036
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists