lkml.org 
[lkml]   [2019]   [May]   [27]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH 7/7] sched/fair: Rename weighted_cpuload() to cpu_load()
From
Date
On Mon, 2019-05-27 at 07:21 +0100, Dietmar Eggemann wrote:
> This is done to align the per cpu (i.e. per rq) load with the util
> counterpart (cpu_util(int cpu)). The term 'weighted' is not needed
> since there is no 'unweighted' load to distinguish it from.

I can see why you want to make cpu_util() and cpu_load()
have the same parameter, but ...

> @@ -7931,7 +7928,7 @@ static inline void update_sg_lb_stats(struct
> lb_env *env,
> if ((env->flags & LBF_NOHZ_STATS) &&
> update_nohz_stats(rq, false))
> env->flags |= LBF_NOHZ_AGAIN;
>
> - sgs->group_load += weighted_cpuload(rq);
> + sgs->group_load += cpu_load(i);
> sgs->group_util += cpu_util(i);
> sgs->sum_nr_running += rq->cfs.h_nr_running;

... now we end up dereferencing cpu_rq(cpu) 3 times.

I guess per-cpu variables are so cheap that we should
never notice, but I thought I'd ask anyway while looking
over these patches :)

Thank you for removing a bunch of code that slowed down
my understanding of fair.c

--
All Rights Reversed.
[unhandled content-type:application/pgp-signature]
\
 
 \ /
  Last update: 2019-05-27 18:24    [W:0.046 / U:28.028 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site