[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20210127132121.GD3592@techsingularity.net>
Date: Wed, 27 Jan 2021 13:21:21 +0000
From: Mel Gorman <mgorman@...hsingularity.net>
To: Vincent Guittot <vincent.guittot@...aro.org>
Cc: Peter Zijlstra <peterz@...radead.org>,
Ingo Molnar <mingo@...hat.com>,
Li Aubrey <aubrey.li@...ux.intel.com>,
Qais Yousef <qais.yousef@....com>,
LKML <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH 4/4] sched/fair: Merge select_idle_core/cpu()
On Wed, Jan 27, 2021 at 02:07:50PM +0100, Vincent Guittot wrote:
> > @@ -6162,18 +6162,16 @@ static int select_idle_cpu(struct task_struct *p, struct sched_domain *sd, int t
> >
> > for_each_cpu_wrap(cpu, cpus, target) {
> > if (smt) {
> > - i = select_idle_core(p, cpu, cpus, &idle_cpu);
> > - if ((unsigned int)i < nr_cpumask_bits)
> > - return i;
> > + idle_cpu = select_idle_core(p, cpu, cpus, &idle_cpu);
>
> but how do you differentiate idle core (return value) and an idle cpu
> in the core set in &idle_cpu
>
> You will return as soon as a cpu is idle and before testing all cores
>
Bah, I'm sorry, I was context switching between multiple tasks and failed
to engage brain. I'll apply your hunk and resend. I don't think this
merits retesting as the saving of avoiding the intermeriate is marginal.
--
Mel Gorman
SUSE Labs
Powered by blists - more mailing lists