Re: [PATCH 3/3] sched/fair: fix unnecessary increase of balance interval

2018-12-21 Thread Vincent Guittot
On Fri, 21 Dec 2018 at 18:15, Valentin Schneider wrote: > > On 21/12/2018 14:49, Vincent Guittot wrote: > [...] > > After looking at shed.c at this sha1, (sd->nr_balance_failed > > > sd->cache_nice_tries+2) was the only condition for doing active > > migration and as a result it was the only reas

Re: [PATCH 3/3] sched/fair: fix unnecessary increase of balance interval

2018-12-21 Thread Valentin Schneider
On 21/12/2018 14:49, Vincent Guittot wrote: [...] > After looking at shed.c at this sha1, (sd->nr_balance_failed > > sd->cache_nice_tries+2) was the only condition for doing active > migration and as a result it was the only reason for doubling > sd->balance_interval. > My patch keeps exactly the

Re: [PATCH 3/3] sched/fair: fix unnecessary increase of balance interval

2018-12-21 Thread Vincent Guittot
On Thu, 20 Dec 2018 at 18:24, Valentin Schneider wrote: > > On 20/12/2018 14:50, Vincent Guittot wrote: > [...] > >> So now we reset the interval for all active balances (expect last active > >> balance case), even when it is done as a last resort because all other > >> tasks were pinned. > >> >

Re: [PATCH 3/3] sched/fair: fix unnecessary increase of balance interval

2018-12-20 Thread Valentin Schneider
On 20/12/2018 14:50, Vincent Guittot wrote: [...] >> So now we reset the interval for all active balances (expect last active >> balance case), even when it is done as a last resort because all other >> tasks were pinned. >> >> Arguably the current code isn't much better (always increase the inter

Re: [PATCH 3/3] sched/fair: fix unnecessary increase of balance interval

2018-12-20 Thread Vincent Guittot
On Thu, 20 Dec 2018 at 12:22, Valentin Schneider wrote: > > On 20/12/2018 07:55, Vincent Guittot wrote: > > In case of active balance, we increase the balance interval to cover > > pinned tasks cases not covered by all_pinned logic. Neverthless, the > > active migration triggered by asym packing s

Re: [PATCH 3/3] sched/fair: fix unnecessary increase of balance interval

2018-12-20 Thread Valentin Schneider
On 20/12/2018 07:55, Vincent Guittot wrote: > In case of active balance, we increase the balance interval to cover > pinned tasks cases not covered by all_pinned logic. Neverthless, the > active migration triggered by asym packing should be treated as the normal > unbalanced case and reset the inte

Re: [PATCH 3/3] sched/fair: fix unnecessary increase of balance interval

2018-12-13 Thread Vincent Guittot
On Thu, 13 Dec 2018 at 14:52, Peter Zijlstra wrote: > > On Tue, Aug 07, 2018 at 05:56:27PM +0200, Vincent Guittot wrote: > > +static inline bool > > +asym_active_balance(enum cpu_idle_type idle, unsigned int flags, int dst, > > int src) > > { > > + if (idle != CPU_NOT_IDLE) { > > > >

Re: [PATCH 3/3] sched/fair: fix unnecessary increase of balance interval

2018-12-13 Thread Peter Zijlstra
On Tue, Aug 07, 2018 at 05:56:27PM +0200, Vincent Guittot wrote: > +static inline bool > +asym_active_balance(enum cpu_idle_type idle, unsigned int flags, int dst, > int src) > { > + if (idle != CPU_NOT_IDLE) { > > /* >* ASYM_PACKING needs to force migrate task