mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Peter Zijlstra <peterz@infradead.org>
To: Christian Loehle <christian.loehle@arm.com>
Cc: linux-kernel@vger.kernel.org, mingo@redhat.com,
	vincent.guittot@linaro.org, dietmar.eggemann@arm.com,
	kayracizmeci@gmail.com, kprateek.nayak@amd.com,
	elif.topuz@arm.com, sh@gentwo.org
Subject: Re: [PATCH v2 1/5] sched/fair: Take slice protection into account when arming HRTICK
Date: Thu, 1 Oct 2026 15:43:20 +0200	[thread overview]
Message-ID: <20261001134320.GR2009045@noisy.programming.kicks-ass.net> (raw)
In-Reply-To: <20261001134016.3881268-2-christian.loehle@arm.com>

On Thu, Oct 01, 2026 at 02:40:12PM +0100, Christian Loehle wrote:
> EEVDF can end a task's slice protection before its virtual deadline when
> shorter requests compete on the runqueue. update_curr() requests a new
> selection once protection expires, but hrtick_start_fair() still arms the
> timer for the virtual deadline. Without an intervening scheduling event,
> the next opportunity to reconsider the task can therefore arrive much
> later than the protection boundary.
> 
> Arm the fair hrtick for the earlier of the virtual deadline and live
> slice protection. Keep the deadline fallback once protection expires.
> With RUN_TO_PARITY disabled, vprot remains the minimum progress quantum,
> so the timer must reconsider current at that boundary too. A same-task
> repick restarts the timer without renewing protection, so newly eligible
> tasks can compete without waiting for another protected quantum.
> 
> A wakeup can shorten protection without preempting current. The enqueue
> path calls hrtick_update() before wakeup_preempt_fair() updates protection,
> and hrtick_update() leaves an active timer alone. Recompute the fair
> hrtick after update_protect_slice() changes vprot, including when a timer
> is already active. If the new protection boundary has already passed,
> request lazy rescheduling, as update_curr() does on protection expiry,
> instead of falling back to the later deadline.
> 

Right, so I don't much like this. This wrecks the steady state behaviour
in favour of our 'dodgy' wakeup heuristics.

I would much rather we stick to the paper for steady state, and let
wakeups be wakeups.

  reply	other threads:[~2026-10-01 13:43 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-10-01 13:40 [PATCH v2 0/5] sched/eevdf: Keep slice protection boundaries consistent Christian Loehle
2026-10-01 13:40 ` [PATCH v2 1/5] sched/fair: Take slice protection into account when arming HRTICK Christian Loehle
2026-10-01 13:43   ` Peter Zijlstra [this message]
2026-10-01 14:01     ` Christian Loehle
2026-10-01 13:40 ` [PATCH v2 2/5] sched/eevdf: Share the slice protection calculation Christian Loehle
2026-10-01 13:40 ` [PATCH v2 3/5] sched/eevdf: Cap protection when current has the shortest slice Christian Loehle
2026-10-01 13:55   ` Peter Zijlstra
2026-10-01 13:57     ` Christian Loehle
2026-10-01 13:40 ` [PATCH v2 4/5] sched/eevdf: Keep expired protection expired across reweighting Christian Loehle
2026-10-01 16:46   ` Kayra Cizmeci
2026-10-01 21:51     ` Christian Loehle
2026-10-02 14:57       ` Kayra Cizmeci
2026-10-01 13:40 ` [PATCH v2 5/5] sched/eevdf: Update protection after restoring current Christian Loehle

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20261001134320.GR2009045@noisy.programming.kicks-ass.net \
    --to=peterz@infradead.org \
    --cc=christian.loehle@arm.com \
    --cc=dietmar.eggemann@arm.com \
    --cc=elif.topuz@arm.com \
    --cc=kayracizmeci@gmail.com \
    --cc=kprateek.nayak@amd.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@redhat.com \
    --cc=sh@gentwo.org \
    --cc=vincent.guittot@linaro.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®