[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <34ec710f-848a-4f8d-9dac-f9419e9b9c07@amd.com>
Date: Thu, 22 Jan 2026 08:26:29 +0530
From: K Prateek Nayak <kprateek.nayak@....com>
To: Peter Zijlstra <peterz@...radead.org>
CC: Ingo Molnar <mingo@...hat.com>, Juri Lelli <juri.lelli@...hat.com>,
Vincent Guittot <vincent.guittot@...aro.org>, <linux-kernel@...r.kernel.org>,
Dietmar Eggemann <dietmar.eggemann@....com>, Steven Rostedt
<rostedt@...dmis.org>, Ben Segall <bsegall@...gle.com>, Mel Gorman
<mgorman@...e.de>, Valentin Schneider <vschneid@...hat.com>, Chen Yu
<yu.c.chen@...el.com>, Shrikanth Hegde <sshegde@...ux.ibm.com>, "Gautham R.
Shenoy" <gautham.shenoy@....com>
Subject: Re: [PATCH v3 0/8] sched/topology: Optimize sd->shared allocation
Hello Peter,
On 1/21/2026 9:46 PM, Peter Zijlstra wrote:
> On Tue, Jan 20, 2026 at 11:32:38AM +0000, K Prateek Nayak wrote:
>
>> "sd->shared" is only allocated for the topmost SD_SHARE_LLC domain and
>> the topology layer uses the sched domain degeneration path to pass the
>> reference to the final "sd_llc" domain.
>
> I'm fairly sure we've had patches that introduced it for other levels at
> various times, but clearly none of those ever made it.
>
> Anyway, a quick peek seems to suggest it is still easy to extend.
>
>
>> include/linux/sched/topology.h | 1 -
>> kernel/sched/fair.c | 62 +++++++-----------
>> kernel/sched/sched.h | 2 +-
>> kernel/sched/topology.c | 111 ++++++++++++++++++++++-----------
>> 4 files changed, 101 insertions(+), 75 deletions(-)
>
> Is this really worth the extra lines though?
The larger plan was to move the "nohz.idle_cpus" tracking into the
sched_domain_shared instance which will bloat these allocations.
Instead of (#CPUs x #topology_levels) surplus, most of which will get
reclaimed at the end anyways, we'll only have #CPUs worth of
allocations now.
--
Thanks and Regards,
Prateek
Powered by blists - more mailing lists