Re: [Patch v4 01/22] sched/cache: Introduce infrastructure for cache-aware load balancing

Peter Zijlstra
2026-04-09T23:00:36Z

On Thu, Apr 09, 2026 at 12:21:58PM -0700, Tim Chen wrote:

> > > + get_nr_threads(p) <= 1) {
> >
> > And this, I just noticed this, why are we excluding tasks with one
> > thread? The comment just states we are (doh), but utterly fails to
> > explain why.
>
> The thought was that for a single thread, we will tend to place it
> in same LLC as it was previously running with cache hot. Incurring
> the added cost of tracking its residency in LLC is uneeded.

Not sure -- the moment it gets migrated away, it will stay away. There
is no force to pull it back, while with cache aware it will try and come
back for a short while -- until it's build an occupancy on the new llc.

Anyway, if you want to do this, it needs to be a separate patch.