diff options
| author | Thomas Gleixner <tglx@kernel.org> | 2026-02-24 17:35:52 +0100 |
|---|---|---|
| committer | Peter Zijlstra <peterz@infradead.org> | 2026-02-27 16:40:05 +0100 |
| commit | 96d1610e0b20b5a627773874b4514ae922ad98f6 (patch) | |
| tree | 53660db37e290e25d0fbaa1344dc9e7cc34f6ff8 /tools/perf/scripts/python | |
| parent | c3a92213eb3dd8ea6f664d16a08eda800e34eaad (diff) | |
sched: Optimize hrtimer handling
schedule() provides several mechanisms to update the hrtick timer:
1) When the next task is picked
2) When the balance callbacks are invoked before rq::lock is released
Each of them can result in a first expiring timer and cause a reprogram of
the clock event device.
Solve this by deferring the rearm to the end of schedule() right before
releasing rq::lock by setting a flag on entry which tells hrtick_start() to
cache the runtime constraint in rq::hrtick_delay without touching the timer
itself.
Right before releasing rq::lock evaluate the flags and either rearm or
cancel the hrtick timer.
Signed-off-by: Thomas Gleixner <tglx@kernel.org>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Link: https://patch.msgid.link/20260224163429.273068659@kernel.org
Diffstat (limited to 'tools/perf/scripts/python')
0 files changed, 0 insertions, 0 deletions
