Re: [RFC] scheduler: improve SMP fairness in CFS

From: Li, Tong N
Date: Tue Jul 24 2007 - 16:58:42 EST


On Tue, 2007-07-24 at 16:39 -0400, Chris Snook wrote:

> Divining the intentions of the administrator is an AI-complete problem and we're
> not going to try to solve that in the kernel. An intelligent administrator
> could also allocate 50% of each CPU to a resource group containing all the
> *other* processes. Then, when the other processes are scheduled out, your
> single task will run on whichever CPU is idle. This will very quickly
> equilibrate to the scheduling ping-pong you seem to want. The scheduler
> deliberately avoids this kind of migration by default because it hurts cache and
> TLB performance, so if you want to override this very sane default behavior,
> you're going to have to explicitly configure it yourself.
>

Well, the admin wouldn't specifically ask for 50% of each CPU. He would
just allocate 50% of total CPU time---it's up to the scheduler to
fulfill that. If a task is entitled to one CPU, then it'll stay there
and have no migration. Migration occurs only if there's overload, in
which case I think you agree in your last email that the cache and TLB
impact is not an issue (at least in SMP).

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