Re: [RFC 2/4] sched/numa: replace runnable_load_avg by load_avg
From: Mel Gorman
Date: Thu Feb 13 2020 - 12:02:27 EST
On Thu, Feb 13, 2020 at 05:38:31PM +0100, Vincent Guittot wrote:
> > > Your test doesn't explicitly ensure that the 1 condition is met
> > >
> > > That being said, I'm not sure it's really a wrong thing ? I mean
> > > load_balance will probably try to pull back some tasks on src but as
> > > long as it is not a task with dst node as preferred node, it should
> > > not be that harmfull
> >
> > My thinking was that if source has as many or more running tasks than
> > the destination *after* the move that it's not harmful and does not add
> > work for the load balancer.
>
> load_balancer will see an imbalance but fbq_classify_group/queue
> should be there to prevent from pulling back tasks that are on the
> preferred node but only other tasks
>
Yes, exactly. Between fbq_classify and migrate_degrades_locality, I'm
expecting that the load balancer will only override NUMA balancing when
there is no better option. When the imbalance check, I want to avoid
the situation where NUMA balancing moves a task for locality, LB pulls
it back for balance, NUMA retries the move etc because it's stupid. The
locality matters but being continually dequeue/enqueue is unhelpful.
While there might be grounds for relaxing the degree an imbalance is
allowed across SD domains, I am avoiding looking in that direction again
until the load balancer and NUMA balancer stop overriding each other for
silly reasons (or the NUMA balancer fighting itself which can happen).
--
Mel Gorman
SUSE Labs