Re: [PATCHSET] percpu: generalize first chunk allocators and improve lpage NUMA support

From: Andi Kleen
Date: Wed Jul 01 2009 - 09:12:00 EST


On Wed, Jul 01, 2009 at 09:53:06PM +0900, Tejun Heo wrote:
> It would be nice to have something to test cpu on/offlining
> automatically. Something which keeps bringing cpus up and down as the
> system goes through stress testing.

That's an trivial shell script using echo into sysfs files. It doesn't
seem to be widely done (the last time I tried it I promptly ran
into some RCU bug). You need a large enough machine for it.

But most stress testing does not actually have good code coverage
in my experience. It just runs the same small set of core code all over
(you can check now, kernel gcov is finally in)

The tricky part is to actually test the code you want to test.

> > ending up with lots of badly tested code is to:
>
> But I don't think it would be that drastic. Most users are quite
> simple.

But how do you test them properly? And educate
the driver writers? Also it would likely increase code sizes drastically.

Philosophically I think code like that should be a simple
operation and turning all the per cpu init code into
callbacks is not simple. That makes everything more error prone.

And it's imho unclear if that is all worth it just to avoid
wasting some memory in the "256 possible CPUs" case (which
I doubt is particularly realistic anyways, at least I don't
know of any Hypervisor today that scales to 256 CPUs)

-Andi

--
ak@xxxxxxxxxxxxxxx -- Speaking for myself only.
--
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/