sched/fair: Rearrange select_task_rq_fair() to optimize it
authorViresh Kumar <viresh.kumar@linaro.org>
Thu, 26 Apr 2018 10:30:50 +0000 (16:00 +0530)
committerIngo Molnar <mingo@kernel.org>
Fri, 4 May 2018 08:00:07 +0000 (10:00 +0200)
commitf1d88b4468188ddcd2620b8d612068faf6662a62
tree7f9ee18eb9d6e7974e608112a151a37837e42e17
parentb5bf9a90bbebffba888c9144c5a8a10317b04064
sched/fair: Rearrange select_task_rq_fair() to optimize it

Rearrange select_task_rq_fair() a bit to avoid executing some
conditional statements in few specific code-paths. That gets rid of the
goto as well.

This shouldn't result in any functional changes.

Tested-by: Rohit Jain <rohit.k.jain@oracle.com>
Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Reviewed-by: Valentin Schneider <valentin.schneider@arm.com>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Vincent Guittot <vincent.guittot@linaro.org>
Link: http://lkml.kernel.org/r/20831b8d237bf3a20e4e328286f678b425ff04c9.1524738578.git.viresh.kumar@linaro.org
Signed-off-by: Ingo Molnar <mingo@kernel.org>
kernel/sched/fair.c