diff options
| author | Tejun Heo <tj@kernel.org> | 2026-08-15 13:08:28 -1000 |
|---|---|---|
| committer | Tejun Heo <tj@kernel.org> | 2026-08-15 16:07:49 -1000 |
| commit | 006dd4d04b379f4d76c0439b3f4b15d1216dac18 (patch) | |
| tree | a4eb00f5f60552cd20d765306e2b07892337ad59 /tools/perf/scripts/python/stackcollapse.py | |
| parent | 0ec5dd0669291c8ffbee096367e078c26cbcc332 (diff) | |
sched_ext: Make core-sched task ordering hierarchy-aware
With sub-schedulers, tasks of different schedulers routinely share rqs and
SMT siblings, but scx_prio_less() consults ops.core_sched_before() only when
both tasks belong to the same scheduler. Every pair spanning two schedulers
falls back to the default ordering, so no scheduler can express ordering
across a scheduler boundary, including a root over its sub-schedulers'
tasks.
Order a pair spanning schedulers by the nearest common ancestor that
implements ops.core_sched_before(): both tasks are in its subtree, making
this the one op where a scheduler is called on tasks it delegated to its
sub-schedulers and may not be scheduling anymore. Same-scheduler pairs keep
using the owning scheduler's op so a parent never orders inside a subtree it
delegated. The op is skipped when the deciding scheduler is bypassing on
either task's CPU.
Update scx_qmap to fall back to the kernel's default ordering when handed a
delegated task it has no task_ctx for.
Signed-off-by: Tejun Heo <tj@kernel.org>
Diffstat (limited to 'tools/perf/scripts/python/stackcollapse.py')
0 files changed, 0 insertions, 0 deletions
