mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Brendan Jackman <brendan.jackman@arm.com>
To: Ingo Molnar <mingo@redhat.com>,
	Peter Zijlstra <peterz@infradead.org>,
	linux-kernel@vger.kernel.org
Cc: Joel Fernandes <joelaf@google.com>,
	Andres Oportus <andresoportus@google.com>
Subject: [PATCH v2 0/5] sched/fair: Tweaks for select_task_rq_fair slowpath
Date: Fri, 25 Aug 2017 11:16:27 +0100	[thread overview]
Message-ID: <20170825101632.28065-1-brendan.jackman@arm.com> (raw)

This patchset optimises away an unused comparison, and fixes some corner cases in
the find_idlest_group path of select_task_rq_fair.

Changes v1 -> v2:

 - Reworked task affinity checks to avoid repeating them, as per Vincent's
   suggestion. To avoid excessive indentation this required moving code into its
   own function, as per PeterZ's suggestion.

 - Split up the patches.

 - Altered the caller of find_idlest_group so that it now unconditionally uses
   find_idlest_group_cpu (formerly find_idlest_cpu). This means that we more
   often use the maligned "perspective-switching" logic at the bottom of the
   while(sd) loop, but it also means the task placement algorithm is more
   consistent between whether the idlest group is local or remote.

   As mentioned in 5/5 an alternative would be to just initialise @new_cpu to
   @cpu instead of @prev_cpu (which is what PeterZ suggested in v1 review). In
   that case, some extra code could be removed in & around
   find_idlest_group_cpu.

Brendan Jackman (5):
  sched/fair: Move select_task_rq_fair slow-path into its own function
  sched/fair: Remove unnecessary comparison with -1
  sched/fair: Fix find_idlest_group when local group is not allowed
  sched/fair: Fix use of find_idlest_group when no groups are allowed
  sched/fair: Fix use of find_idlest_group when local group is idlest.

 kernel/sched/fair.c | 112 ++++++++++++++++++++++++++++------------------------
 1 file changed, 61 insertions(+), 51 deletions(-)

--
2.14.1

             reply	other threads:[~2017-08-25 10:16 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-08-25 10:16 Brendan Jackman [this message]
2017-08-25 10:16 ` [PATCH v2 1/5] sched/fair: Move select_task_rq_fair slow-path into its own function Brendan Jackman
2017-08-25 12:22   ` Josef Bacik
2017-08-25 13:40   ` Vincent Guittot
2017-08-25 10:16 ` [PATCH v2 2/5] sched/fair: Remove unnecessary comparison with -1 Brendan Jackman
2017-08-25 12:44   ` Josef Bacik
2017-08-25 13:40   ` Vincent Guittot
2017-08-25 10:16 ` [PATCH v2 3/5] sched/fair: Fix find_idlest_group when local group is not allowed Brendan Jackman
2017-08-25 13:39   ` Vincent Guittot
2017-08-25 10:16 ` [PATCH v2 4/5] sched/fair: Fix use of find_idlest_group when no groups are allowed Brendan Jackman
2017-08-25 13:39   ` Vincent Guittot
2017-08-25 10:16 ` [PATCH v2 5/5] sched/fair: Fix use of find_idlest_group when local group is idlest Brendan Jackman
2017-08-25 13:38   ` Vincent Guittot
2017-08-25 15:51     ` Brendan Jackman
2017-08-28  8:56       ` Vincent Guittot
2017-08-28  9:11         ` Vincent Guittot
2017-08-29 17:09         ` Brendan Jackman

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=20170825101632.28065-1-brendan.jackman@arm.com \
    --to=brendan.jackman@arm.com \
    --cc=andresoportus@google.com \
    --cc=joelaf@google.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@redhat.com \
    --cc=peterz@infradead.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

all inboxes | Powered by JetHome®