Re: [PATCH 1/6] sched/proxy: Remove superfluous clear_task_blocked_in()
From: K Prateek Nayak
Date: Fri May 29 2026 - 04:24:41 EST
Hello John,
On 5/29/2026 12:44 PM, John Stultz wrote:
> You see these things so quickly! :) Beat me sending out my own
> analysis (which is maybe a slightly different case, but still).
That was an interesting case too! My brain defaults to one lock and two
CPUs but your brain goes a few step (and a few locks, CPUs) further ;-)
>> Part of that belongs in commit e2ff8b7bde07 ("sched/proxy: Only return
>> migrate when needed") and the first hunk of 83f9b04ef50c ("sched/proxy:
>> Switch proxy to use p->is_blocked") in proxy_needs_return() should be
>> dropped.
>
> Very nice, yes this does help when the "Only return migrate when
> needed" is added!
>
> So I've included this and reworked the order of Peter's doodles slightly to be:
> sched/proxy: Optimize try_to_wake_up()
> sched: Be more strict about p->is_blocked
> sched/proxy: Only return migrate when needed
> FOLD: k prateek's fixup
> sched/proxy: Switch proxy to use p->is_blocked
> sched/proxy: Remove PROXY_WAKING
> sched/proxy: Remove superfluous clear_task_blocked_in()
> sched: Simplify ttwu_runnable()
Ack! That should cover all bases.
>
> Which seems to be working at each step. Though I've only lightly
> tested and I didn't trip this initially with the series, so more
> testing will be needed tommorow.
Meanwhile, I'll rearrange the patches like you suggested above and run
some testes too. Fingers crossed
--
Thanks and Regards,
Prateek