Re: [PATCH 02/10] sched: Factor out code to should_we_balance()

2013-08-23 Thread Paul Turner
On Thu, Aug 22, 2013 at 3:42 AM, Peter Zijlstra wrote: > On Thu, Aug 22, 2013 at 02:58:27AM -0700, Paul Turner wrote: >> On Mon, Aug 19, 2013 at 9:01 AM, Peter Zijlstra wrote: > >> > + if (local_group) >> > load = target_load(i, load_idx); >> >> Keep the brac

Re: [PATCH 02/10] sched: Factor out code to should_we_balance()

2013-08-22 Thread Joonsoo Kim
On Thu, Aug 22, 2013 at 12:42:57PM +0200, Peter Zijlstra wrote: > > > > > > +redo: > > > > One behavioral change worth noting here is that in the redo case if a > > CPU has become idle we'll continue trying to load-balance in the > > !new-idle case. > > > > This could be unpleasant in the case wh

Re: [PATCH 02/10] sched: Factor out code to should_we_balance()

2013-08-22 Thread Peter Zijlstra
On Thu, Aug 22, 2013 at 02:58:27AM -0700, Paul Turner wrote: > On Mon, Aug 19, 2013 at 9:01 AM, Peter Zijlstra wrote: > > + if (local_group) > > load = target_load(i, load_idx); > > Keep the braces here: > > if (local_group) { > load = target_load(i,

Re: [PATCH 02/10] sched: Factor out code to should_we_balance()

2013-08-22 Thread Paul Turner
On Mon, Aug 19, 2013 at 9:01 AM, Peter Zijlstra wrote: > From: Joonsoo Kim > > Now checking whether this cpu is appropriate to balance or not > is embedded into update_sg_lb_stats() and this checking has no direct > relationship to this function. There is not enough reason to place > this checkin

[PATCH 02/10] sched: Factor out code to should_we_balance()

2013-08-19 Thread Peter Zijlstra
From: Joonsoo Kim Now checking whether this cpu is appropriate to balance or not is embedded into update_sg_lb_stats() and this checking has no direct relationship to this function. There is not enough reason to place this checking at update_sg_lb_stats(), except saving one iteration for sched_gr