[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CA+KHdyVOsQTUo6QqZMg1OMpGD4W_JhTLuyf2fFOA8tTwm_B5Jg@mail.gmail.com>
Date: Thu, 9 Feb 2017 11:12:20 +0100
From: Uladzislau Rezki <urezki@...il.com>
To: Mike Galbraith <efault@....de>
Cc: Ingo Molnar <mingo@...hat.com>,
LKML <linux-kernel@...r.kernel.org>,
Peter Zijlstra <peterz@...radead.org>,
Uladzislau 2 Rezki <uladzislau2.rezki@...ymobile.com>
Subject: Re: [RFC,v2 3/3] sched: ignore task_h_load for CPU_NEWLY_IDLE
>
> On Wed, 2017-02-08 at 09:43 +0100, Uladzislau Rezki wrote:
> > From: Uladzislau 2 Rezki <uladzislau2.rezki@...ymobile.com>
> >
> > A load balancer calculates imbalance factor for particular shed
> ^sched
Will fix that.
> > domain and tries to steal up the prescribed amount of weighted load.
> > However, a small imbalance factor would sometimes prevent us from
> > stealing any tasks at all. When a CPU is newly idle, it should
> > steal first task which passes a migration criteria.
> s/passes a/meets the
Will change the description.
> >
> > Signed-off-by: Uladzislau 2 Rezki <uladzislau2.rezki@...ymobile.com>
> > ---
> > kernel/sched/fair.c | 13 +++++++++++--
> > 1 file changed, 11 insertions(+), 2 deletions(-)
> >
> > diff --git a/kernel/sched/fair.c b/kernel/sched/fair.c
> > index 232ef3c..29e0d7f 100644
> > --- a/kernel/sched/fair.c
> > +++ b/kernel/sched/fair.c
> > > > env->loop++;
> > @@ -6824,8 +6832,9 @@ static int detach_tasks(struct lb_env *env)
> > > > > if (sched_feat(LB_MIN) && load < 16 && !env->sd->nr_balance_failed)
> > > > > > goto next;
> >
> > -> > > if ((load / 2) > env->imbalance)
> > -> > > > goto next;
> > +> > > if (env->idle != CPU_NEWLY_IDLE)
> > +> > > > if ((load / 2) > env->imbalance)
> > +> > > > > goto next;
>
> Those two ifs could be one ala if (foo && bar).
Agree.
--
Uladzislau Rezki
Powered by blists - more mailing lists