linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Rohit Jain <rohit.k.jain@oracle.com>
To: Peter Zijlstra <peterz@infradead.org>
Cc: linux-kernel@vger.kernel.org, mingo@redhat.com,
	vincent.guittot@linaro.org, morten.rasmussen@arm.com,
	dietmar.eggemann@arm.com
Subject: Re: [PATCH] sched: Introduce scaled capacity awareness in enqueue
Date: Wed, 31 May 2017 15:19:46 -0700	[thread overview]
Message-ID: <63736e6f-37e6-e287-a920-56ab0d0586b7@oracle.com> (raw)
In-Reply-To: <20170530122831.5fyywtplq4jawj3j@hirez.programming.kicks-ass.net>

On 05/30/2017 05:28 AM, Peter Zijlstra wrote:
> On Mon, May 22, 2017 at 01:48:14PM -0700, Rohit Jain wrote:
>> The patch introduces capacity awarness in scheduler (CAS) which avoids
>> CPUs which might have their capacities reduced (due to IRQ/RT activity)
>> when trying to schedule threads (on the push side) in the system. This
>> awareness has been added into the fair scheduling class.
>>
>> It does so by, using the following algorithm:
>> --------------------------------------------------------------------------
>> 1) As in rt_avg the scaled capacities are already calculated.
>>
>> 2) This scaled capacity is normalized and mapped into buckets.
> Why?

This is done to deterministically define the CPUs which are low on
capacities. By mapping it into buckets it becomes easier to do a
percentile calculation.

>> 3) Any CPU which lies below the 80th percentile in terms of percentage
>> capacity available is considered as a low capacity CPU.
> Random number; can we do better? What does existing code do?
>

Existing code checks to see if the waker is running on a CPU with better
capacity than the 'previous cpu'. If that is the case the waker cpu is
provided as 'target' to select_idle_sibling. (When I say capacity this
is not the scaled one because of IRQ, RT, etc.)

However, in case this 'target' is not an idle CPU, the rest of
select_idle_sibling would ignore the capacities altogether.

  reply	other threads:[~2017-05-31 22:17 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-05-22 20:48 [PATCH] sched: Introduce scaled capacity awareness in enqueue Rohit Jain
2017-05-30 12:28 ` Peter Zijlstra
2017-05-31 22:19   ` Rohit Jain [this message]
2017-06-01 12:28     ` Peter Zijlstra
2017-06-01 12:37       ` Peter Zijlstra
2017-06-02 18:20         ` Rohit Jain
2017-06-02 18:26           ` Peter Zijlstra
2017-06-05 18:08             ` Rohit Jain
2017-06-12 15:36               ` Peter Zijlstra
2017-06-13  0:31                 ` Rohit Jain

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=63736e6f-37e6-e287-a920-56ab0d0586b7@oracle.com \
    --to=rohit.k.jain@oracle.com \
    --cc=dietmar.eggemann@arm.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@redhat.com \
    --cc=morten.rasmussen@arm.com \
    --cc=peterz@infradead.org \
    --cc=vincent.guittot@linaro.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).