public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH RESEND v3 0/5]
@ 2017-10-05 11:45 Brendan Jackman
  2017-10-05 11:45 ` [PATCH RESEND v3 1/5] sched/fair: Move select_task_rq_fair slow-path into its own function Brendan Jackman
                   ` (4 more replies)
  0 siblings, 5 replies; 11+ messages in thread
From: Brendan Jackman @ 2017-10-05 11:45 UTC (permalink / raw)
  To: linux-kernel, Peter Zijlstra

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

Changes v2 -> v3:

 - 1/5 through 4/5 unchanged.

 - 5/5: Essentially undid [1]. Vincent pointed out that this isn't really a
   bugfix but more of a change in policy. Now find_idlest_group still returns
   NULL when the local group is idlest.

   I previously said some extra code could be removed in this case, but after
   more careful inspection I changed my mind.

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.

[1]
 - 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 | 93 ++++++++++++++++++++++++++++++++---------------------
 1 file changed, 56 insertions(+), 37 deletions(-)

-- 
2.14.1

^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2017-10-10 11:05 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-10-05 11:45 [PATCH RESEND v3 0/5] Brendan Jackman
2017-10-05 11:45 ` [PATCH RESEND v3 1/5] sched/fair: Move select_task_rq_fair slow-path into its own function Brendan Jackman
2017-10-10 10:59   ` [tip:sched/core] sched/fair: Move select_task_rq_fair() " tip-bot for Brendan Jackman
2017-10-05 11:45 ` [PATCH RESEND v3 2/5] sched/fair: Remove unnecessary comparison with -1 Brendan Jackman
2017-10-10 10:59   ` [tip:sched/core] " tip-bot for Brendan Jackman
2017-10-05 11:45 ` [PATCH RESEND v3 3/5] sched/fair: Fix find_idlest_group when local group is not allowed Brendan Jackman
2017-10-10 11:00   ` [tip:sched/core] sched/fair: Fix find_idlest_group() " tip-bot for Brendan Jackman
2017-10-05 11:45 ` [PATCH RESEND v3 4/5] sched/fair: Fix use of find_idlest_group when no groups are allowed Brendan Jackman
2017-10-10 11:00   ` [tip:sched/core] sched/fair: Fix usage of find_idlest_group() " tip-bot for Brendan Jackman
2017-10-05 11:45 ` [PATCH RESEND v3 5/5] sched/fair: Fix use of find_idlest_group when local group is idlest Brendan Jackman
2017-10-10 11:01   ` [tip:sched/core] sched/fair: Fix usage of find_idlest_group() when the " tip-bot for Brendan Jackman

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox