[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <87lf9eldsx.mognet@arm.com>
Date: Mon, 19 Apr 2021 12:22:06 +0100
From: Valentin Schneider <valentin.schneider@....com>
To: Rik van Riel <riel@...riel.com>, linux-kernel@...r.kernel.org
Cc: kernel-team@...com, Peter Zijlstra <peterz@...radead.org>,
Ingo Molnar <mingo@...nel.org>,
Vincent Guittot <vincent.guittot@...aro.org>,
Dietmar Eggemann <dietmar.eggemann@....com>,
Mel Gorman <mgorman@...e.de>
Subject: Re: [PATCH] sched,fair: skip newidle_balance if a wakeup is pending
On 18/04/21 22:17, Rik van Riel wrote:
> @@ -10661,7 +10669,8 @@ static int newidle_balance(struct rq *this_rq, struct rq_flags *rf)
> * Stop searching for tasks to pull if there are
> * now runnable tasks on this rq.
> */
> - if (pulled_task || this_rq->nr_running > 0)
> + if (pulled_task || this_rq->nr_running > 0 ||
> + this_rq->ttwu_pending)
> break;
I thought newidle_balance() would already handle this by checking
idle_cpu(), but that can't work due to rq->curr never being rq->idle here
(we're trying very hard to prevent this!).
Would there be any point in bunching up these two checks from idle_cpu()
into an inline helper and reusing it here?
_nohz_idle_balance() "accidentally" already checks for that, but at the
head of the domain loop. What's the reason for doing it at the tail here?
It means we try at least one loop, but is there a point in that?
> }
> rcu_read_unlock();
> --
> 2.25.4
Powered by blists - more mailing lists