public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [RFC PATCH 0/2] sched: Improve cache locality of RSEQ concurrency IDs
@ 2024-09-03 19:06 Mathieu Desnoyers
  2024-09-03 19:06 ` [RFC PATCH 1/2] cpumask: Implement cpumask_next_andnot Mathieu Desnoyers
  2024-09-03 19:06 ` [RFC PATCH 2/2] sched: Improve cache locality of RSEQ concurrency IDs for intermittent workloads Mathieu Desnoyers
  0 siblings, 2 replies; 11+ messages in thread
From: Mathieu Desnoyers @ 2024-09-03 19:06 UTC (permalink / raw)
  To: Peter Zijlstra, Ingo Molnar
  Cc: linux-kernel, Mathieu Desnoyers, Valentin Schneider, Mel Gorman,
	Steven Rostedt, Vincent Guittot, Dietmar Eggemann, Ben Segall,
	Yury Norov, Rasmus Villemoes

Intermittent workloads behaving in bursts spaced by more than 100ms
on each CPU exhibit bad cache locality and degraded performance compared
to purely per-cpu data indexing, because concurrency IDs are allocated
over various CPUs and cores, therefore losing cache locality of the
associated data.

This series addresses this shortcoming. I observed speedups up to 16.7x
compared to plain mm_cid indexing in benchmarks.

It applies on top of v6.10.6.

This deprecates the prior "sched: NUMA-aware per-memory-map concurrency
IDs" patch series with a simpler and more general approach.

Feedback is welcome!

Thanks,

Mathieu

Cc: Valentin Schneider <vschneid@redhat.com>
Cc: Mel Gorman <mgorman@suse.de>
Cc: Steven Rostedt <rostedt@goodmis.org>
Cc: Vincent Guittot <vincent.guittot@linaro.org>
Cc: Dietmar Eggemann <dietmar.eggemann@arm.com>
Cc: Ben Segall <bsegall@google.com>
Cc: Yury Norov <yury.norov@gmail.com>
Cc: Rasmus Villemoes <linux@rasmusvillemoes.dk>

Mathieu Desnoyers (2):
  cpumask: Implement cpumask_next_andnot
  sched: Improve cache locality of RSEQ concurrency IDs for intermittent
    workloads

 fs/exec.c                |  2 +-
 include/linux/cpumask.h  | 17 +++++++++++
 include/linux/mm_types.h | 66 ++++++++++++++++++++++++++++++++++------
 kernel/fork.c            |  2 +-
 kernel/sched/core.c      |  7 +++--
 kernel/sched/sched.h     | 47 +++++++++++++++++++---------
 6 files changed, 114 insertions(+), 27 deletions(-)

-- 
2.39.2

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

end of thread, other threads:[~2024-09-05 13:37 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-09-03 19:06 [RFC PATCH 0/2] sched: Improve cache locality of RSEQ concurrency IDs Mathieu Desnoyers
2024-09-03 19:06 ` [RFC PATCH 1/2] cpumask: Implement cpumask_next_andnot Mathieu Desnoyers
2024-09-03 19:28   ` Yury Norov
2024-09-04  0:47     ` Mathieu Desnoyers
2024-09-03 19:06 ` [RFC PATCH 2/2] sched: Improve cache locality of RSEQ concurrency IDs for intermittent workloads Mathieu Desnoyers
2024-09-03 19:59   ` Yury Norov
2024-09-03 23:22     ` Mathieu Desnoyers
2024-09-04 15:24       ` Yury Norov
2024-09-04 15:50         ` Mathieu Desnoyers
2024-09-04 18:28           ` Mathieu Desnoyers
2024-09-05 13:36             ` Mathieu Desnoyers

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