mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH v2 0/3] sched/fair: improve nohz fields for large systems
@ 2026-01-02 12:47 Shrikanth Hegde
  2026-01-02 12:47 ` [PATCH v2 1/3] sched/fair: Move checking for nohz cpus after time check Shrikanth Hegde
                   ` (2 more replies)
  0 siblings, 3 replies; 14+ messages in thread
From: Shrikanth Hegde @ 2026-01-02 12:47 UTC (permalink / raw)
  To: mingo, peterz, vincent.guittot
  Cc: sshegde, linux-kernel, kprateek.nayak, juri.lelli, vschneid,
	tglx, dietmar.eggemann, anna-maria, frederic, wangyang.guo

Running on large systems nohz.nr_cpus cacheline was seen as contended.
There is atomic inc/dec and read happening on many
CPUs at a time and it is possible for this line to bounce often.

Gist of the series is to get rid of nr_cpus. Instead, use the cpumask
which is always updated alongside with it. Functionally it should serve
the same purpose. Rest of the fields aren't updated that often. So this
line shouldn't bounce that often.

Contention issue with nohz.idle_cpus_mask still remains. Mostly it is in
separate cacheline than nohz. There are ongoing efforts to mitigate it. It
is not addressed by this series.

v1 -> v2:
- Dropped patch to check has_blocked based on time.
- Detailed changelog for removing nr_cpus (Thanks to Ingo Molnar)

v1: https://lore.kernel.org/all/20251201183146.74443-1-sshegde@linux.ibm.com/

Shrikanth Hegde (3):
  sched/fair: Move checking for nohz cpus after time check
  sched/fair: Change likelyhood of nohz.nr_cpus and do stats update if
    its due
  sched/fair: Remove nohz.nr_cpus and use weight of cpumask instead

 kernel/sched/fair.c | 17 +++++++----------
 1 file changed, 7 insertions(+), 10 deletions(-)

-- 
2.47.3


^ permalink raw reply	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2026-01-06 15:58 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-01-02 12:47 [PATCH v2 0/3] sched/fair: improve nohz fields for large systems Shrikanth Hegde
2026-01-02 12:47 ` [PATCH v2 1/3] sched/fair: Move checking for nohz cpus after time check Shrikanth Hegde
2026-01-06 15:50   ` Peter Zijlstra
2026-01-06 15:57     ` Shrikanth Hegde
2026-01-02 12:47 ` [PATCH v2 2/3] sched/fair: Change likelyhood of nohz.nr_cpus and do stats update if its due Shrikanth Hegde
2026-01-05  3:52   ` K Prateek Nayak
2026-01-05  5:07     ` Shrikanth Hegde
2026-01-05  6:41       ` K Prateek Nayak
2026-01-05 10:39         ` Shrikanth Hegde
2026-01-06  3:03           ` K Prateek Nayak
2026-01-06  4:23             ` Shrikanth Hegde
2026-01-06  5:50               ` K Prateek Nayak
2026-01-06  6:44                 ` Shrikanth Hegde
2026-01-02 12:47 ` [PATCH v2 3/3] sched/fair: Remove nohz.nr_cpus and use weight of cpumask instead Shrikanth Hegde

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®