Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1398734

Re: [RFC][PATCH 5/7] sched: Rewrite select_idle_siblings()

From Yuyang Du <yuyang.du@intel.com>
Newsgroups linux.kernel
Subject Re: [RFC][PATCH 5/7] sched: Rewrite select_idle_siblings()
Date 2016-05-11 09:30 +0200
Message-ID <rxwKJ-3ri-7@gated-at.bofh.it> (permalink)
References <rwR4S-3QS-9@gated-at.bofh.it> <rwR4S-3QS-7@gated-at.bofh.it> <rxufU-11W-3@gated-at.bofh.it> <rxwro-3gT-17@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Wed, May 11, 2016 at 09:00:29AM +0200, Peter Zijlstra wrote:
> On Wed, May 11, 2016 at 05:05:50AM +0800, Yuyang Du wrote:
> > On Mon, May 09, 2016 at 12:48:12PM +0200, Peter Zijlstra wrote:
> > > +	i = select_idle_core(p, sd, target);
> > > +	if ((unsigned)i < nr_cpumask_bits)
> > > +		return i;
> > > +
> > > +	i = select_idle_cpu(p, sd, target);
> > > +	if ((unsigned)i < nr_cpumask_bits)
> > > +		return i;
> > > +
> > > +	i = select_idle_smt(p, sd, target);
> > > +	if ((unsigned)i < nr_cpumask_bits)
> > > +		return i;
> > 
> > First, on smt, these three scans have a lot of overlap,
> 
> Limited, we stop doing the idle_core scan the moment we fail to find
> one. And on a busy system it is unlikely to come back.
> 
> Which leaves us with the straight idle_cpu scan. Sure, the one time we
> fail to find an idle core and fall through we'll scan double, but that
> should be rare.

Yes, I was sorta well educated about how important finding an idle is ("one
stack, game over"), which therefore is sure worth the effort.

Looks to me, it is just about how much opportunisic-spinning should be applied
here. Great.

Do you have any suggestion about doing other part of select_task_rq_fair?

Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

[RFC][PATCH 5/7] sched: Rewrite select_idle_siblings() Peter Zijlstra <peterz@infradead.org> - 2016-05-09 13:00 +0200
  Re: [RFC][PATCH 5/7] sched: Rewrite select_idle_siblings() Yuyang Du <yuyang.du@intel.com> - 2016-05-11 06:50 +0200
    Re: [RFC][PATCH 5/7] sched: Rewrite select_idle_siblings() Peter Zijlstra <peterz@infradead.org> - 2016-05-11 09:10 +0200
      Re: [RFC][PATCH 5/7] sched: Rewrite select_idle_siblings() Yuyang Du <yuyang.du@intel.com> - 2016-05-11 09:30 +0200
        Re: [RFC][PATCH 5/7] sched: Rewrite select_idle_siblings() Mike Galbraith <mgalbraith@suse.de> - 2016-05-11 09:50 +0200

csiph-web