OK. I made a simple boring optimisation to your patch. Shaved almost
a second off system time for kernbench, and seems idiotproof to me,
shouldn't change anything apart from touching fewer runqueues: if
we find a runqueue with nr_running == 0, stop searching ... we ain't
going to find anything better ;-)
Kernbench:
Elapsed User System CPU
2.5.44-mm4 19.676s 192.794s 42.678s 1197.4%
2.5.44-mm4-hbaum-1 19.746s 189.232s 38.354s 1152.2%
2.5.44-mm4-hbaum-12 19.322s 190.176s 40.354s 1192.6%
2.5.44-mm4-hbaum-12-firstzero 19.292s 189.66s 39.428s 1187.4%
Patch is probably space-eaten, so just whack it in by hand.
--- 2.5.44-mm4-hbaum-12/kernel/sched.c 2002-10-27 19:54:25.000000000 -0800
+++ 2.5.44-mm4-hbaum-12-first_low/kernel/sched.c 2002-10-27 16:42:10.000000000 -0800
@@ -2206,6 +2206,8 @@
if (minload > cpu_rq(cur_cpu)->nr_running) {
minload = cpu_rq(cur_cpu)->nr_running;
best_cpu = cur_cpu;
+ if (minload == 0)
+ break;
}
if (++cur_cpu >= NR_CPUS)
cur_cpu = 0;
-
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/