aboutsummaryrefslogtreecommitdiffstats
path: root/tools/perf/scripts/python/sched-migration.py
diff options
context:
space:
mode:
authorJohn Stultz <[email protected]>2025-07-12 03:33:46 +0000
committerPeter Zijlstra <[email protected]>2025-07-14 15:16:32 +0000
commitaa4f74dfd42ba4399f785fb9c460a11bd1756f0a (patch)
tree193e027519bfbc5bc10fdfea5407031b9e707802 /tools/perf/scripts/python/sched-migration.py
parentsched: Move update_curr_task logic into update_curr_se (diff)
downloadkernel-aa4f74dfd42ba4399f785fb9c460a11bd1756f0a.tar.gz
kernel-aa4f74dfd42ba4399f785fb9c460a11bd1756f0a.zip
sched: Fix runtime accounting w/ split exec & sched contexts
Without proxy-exec, we normally charge the "current" task for both its vruntime as well as its sum_exec_runtime. With proxy, however, we have two "current" contexts: the scheduler context and the execution context. We want to charge the execution context rq->curr (ie: proxy/lock holder) execution time to its sum_exec_runtime (so it's clear to userland the rq->curr task *is* running), as well as its thread group. However the rest of the time accounting (such a vruntime and cgroup accounting), we charge against the scheduler context (rq->donor) task, because it is from that task that the time is being "donated". If the donor and curr tasks are the same, then it's the same as without proxy. Signed-off-by: John Stultz <[email protected]> Signed-off-by: Peter Zijlstra (Intel) <[email protected]> Tested-by: K Prateek Nayak <[email protected]> Link: https://lkml.kernel.org/r/[email protected]
Diffstat (limited to 'tools/perf/scripts/python/sched-migration.py')
0 files changed, 0 insertions, 0 deletions