Nick Piggin wrote: > All that aside, I think we can probably do without cpus_exclusive > entirely (for sched-domains), and automatically detect a correct > set of partitions. I remember leaving that as an exercise for the > reader ;) but I think I've got some renewed energy, so I might > try tackling it. OK, something like this patch should automatically carve up the sched-domains into an optimal set of partitions based solely on the state of tasks in the system. The downsides are that it is going to a very expensive operation, and also that it would need to be called at task exit time in order to never lose updates. However, the same algorithm can be implemented using the cpusets topology instead of cpus_allowed, and it will be much cheaper (and cpusets already has a task exit hook). Hmm, there will be still some problems with kernel thread like pdflush in the root cpuset, preventing the partitioning to be actually activated... -- SUSE Labs, Novell Inc.