That said, I'm still not entirely convinced I like this usage ofEven if you do a placement hook you'll need to address it in the load balancing as well. Consider a single 4 thread SMT core with 4 running tasks. If 2 of them exit the remaining 2 will need to be load balanced within the core in a way that takes into account the dynamic nature of the thread power. This patch does that.
cpupower, its supposed to be a normalization scale for load-balancing,
not a placement hook.
I'd be much happier with a SD_GROUP_ORDER or something like that, thatI don't see this load-balancing patch as mutually exclusive with a patch to fix placement. But even if it is a mutually exclusive solution there is no reason we can't fix things now with this patch and then later take it out when it's fixed another way. This patch series is straightforward, non-intrusive, and without it the scheduler is broken on this processor. --
works together with SD_PREFER_SIBLING to pack active tasks to cpus in
ascending group order.