lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Tue, 25 Jun 2019 09:51:30 -0400
From:   Rik van Riel <riel@...riel.com>
To:     Dietmar Eggemann <dietmar.eggemann@....com>, peterz@...radead.org
Cc:     mingo@...hat.com, linux-kernel@...r.kernel.org, kernel-team@...com,
        morten.rasmussen@....com, tglx@...utronix.de,
        Mel Gorman <mgorman@...hsingularity.net>,
        vincent.guittot@...aro.org
Subject: Re: [PATCH 8/8] sched,fair: flatten hierarchical runqueues

On Tue, 2019-06-25 at 11:50 +0200, Dietmar Eggemann wrote:
> On 6/12/19 9:32 PM, Rik van Riel wrote:
> 
> [...]
> 
> > @@ -410,6 +412,11 @@ static inline struct sched_entity
> > *parent_entity(struct sched_entity *se)
> >  	return se->parent;
> >  }
> >  
> > +static inline bool task_se_in_cgroup(struct sched_entity *se)
> > +{
> > +	return parent_entity(se);
> > +}
> 
> IMHO, s/in_cgroup/not_in_root_tg/ reads easier. "/", i.e. the root tg
> is
> still a cgroup, I guess. But you could use existing parent_entity(se)
> as
> well.

I agree my name is not the prettiest, but I am not
entirely convinced your idea is an improvement.

I'll hold out for better ideas by other reviewers :)

> > @@ -679,22 +710,16 @@ static inline u64 calc_delta_fair(u64 delta,
> > struct sched_entity *se)
> >  static u64 sched_slice(struct cfs_rq *cfs_rq, struct sched_entity
> > *se)
> >  {
> >  	u64 slice = sysctl_sched_latency;
> > +	struct load_weight *load = &cfs_rq->load;
> > +	struct load_weight lw;
> >  
> > -	for_each_sched_entity(se) {
> > -		struct load_weight *load;
> > -		struct load_weight lw;
> > +	if (unlikely(!se->on_rq)) {
> > +		lw = cfs_rq->load;
> >  
> > -		cfs_rq = cfs_rq_of(se);
> > -		load = &cfs_rq->load;
> > -
> > -		if (unlikely(!se->on_rq)) {
> > -			lw = cfs_rq->load;
> > -
> > -			update_load_add(&lw, se->load.weight);
> > -			load = &lw;
> > -		}
> > -		slice = __calc_delta(slice, se->load.weight, load);
> > +		update_load_add(&lw, task_se_h_load(se));
> > +		load = &lw;
> >  	}
> > +	slice = __calc_delta(slice, task_se_h_load(se), load);
> 
> task_se_h_load(se) and se->load.weight are off my factor of >= 1024
> on
> 64bit.

Oh indeed they are!

I wonder if this is the root cause of that
performance regression I have been hunting for
the past few weeks :)

Let me go test some things...

> ...
>     bash pid=3250: task_se_h_load(se)=1023 se->load.weight=1048576
>     sysctl_sched_latency=18000000 slice=0 old_slice=17999995
> ...
> 
> [...]
> 
-- 
All Rights Reversed.

Download attachment "signature.asc" of type "application/pgp-signature" (489 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ