summaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/stackcollapse.py
diff options
context:
space:
mode:
authorAndrea Righi <arighi@nvidia.com>2026-09-22 18:51:54 +0200
committerTejun Heo <tj@kernel.org>2026-09-28 09:48:05 -1000
commitb58f3d2d5d881d17338936c9b5e589bc258269f3 (patch)
treeee2ba23790e247766b03af34d92cb099ba4d8f9d /tools/perf/scripts/python/stackcollapse.py
parentf73ec679142421236e082e79650765c1ad44a47c (diff)
downloadlinux-next-b58f3d2d5d881d17338936c9b5e589bc258269f3.tar.gz
linux-next-b58f3d2d5d881d17338936c9b5e589bc258269f3.zip
sched_ext: scx_qmap: Add proxy execution support
Add a -X option to opt scx_qmap into queueing mutex-blocked tasks for proxy execution. Without the option, SCX_OPS_ENQ_BLOCKED remains clear and mutex waiters block normally. With -X, blocked donors are passed to qmap_enqueue() with SCX_ENQ_BLOCKED. When scx_qmap receives a blocked donor, select a cid allowed by the task and held by qmap, preferring its current cid. Dispatch the donor to that cid's local DSQ with a fresh slice and SCX_ENQ_PREEMPT, adding SCX_ENQ_IMMED when the cid is time-shared. This places the donor at the head of an eligible DSQ and requests an immediate reschedule, allowing the core proxy-exec path to run the mutex owner using the donor's scheduling context as soon as the donor is selected. Partition ownership can change concurrently with enqueue, so the self-cid intersection can disappear between the initial check and cid selection. Validate the selected cid before indexing per-cid state or constructing a local DSQ id, and fall back to rescue placement if the intersection has disappeared. The blocked policy is intentionally unfair and can strongly prioritize tasks using contended mutexes, but scx_qmap is a demo scheduler and such aggressive behavior makes proxy-exec support easy to observe. Count all blocked dispatch attempts in nr_enq_blocked and report their per-interval delta. Acked-by: John Stultz <jstultz@google.com> Signed-off-by: Andrea Righi <arighi@nvidia.com> Signed-off-by: Tejun Heo <tj@kernel.org>
Diffstat (limited to 'tools/perf/scripts/python/stackcollapse.py')
0 files changed, 0 insertions, 0 deletions