On 08/01/21 09:11, Vincent Guittot wrote:
> On Thu, 7 Jan 2021 at 18:40, Valentin Schneider
> <[email protected]> wrote:
>>
>> On 07/01/21 13:20, Vincent Guittot wrote:
>> > On Thu, 7 Jan 2021 at 12:26, Valentin Schneider
>> > <[email protected]> wrote:
>> >> > @@ -9499,13 +9499,32 @@ asym_active_balance(struct lb_env *env)
>> >> >  }
>> >> >
>> >> >  static inline bool
>> >> > -voluntary_active_balance(struct lb_env *env)
>> >> > +imbalanced_active_balance(struct lb_env *env)
>> >> > +{
>> >> > +     struct sched_domain *sd = env->sd;
>> >> > +
>> >> > +     /*
>> >> > +      * The imbalanced case includes the case of pinned tasks 
>> >> > preventing a fair
>> >> > +      * distribution of the load on the system but also the even 
>> >> > distribution of the
>> >> > +      * threads on a system with spare capacity
>> >> > +      */
>> >>
>> >> Do you mean s/imbalanced/migrate_task/? This part here will affect
>> >> group_imbalanced, group_asym_packing, and some others.
>> >
>> > I really mean the imbalanced case which refers to the function name
>> > and includes:
>> > - the pinned tasks case aka group_imbalanced and which is the primary
>> > target of this function ( which explains its name)
>> > - but also the case where we want to evenly spread tasks on system
>> > with spare capacity and removed this imbalance
>> >
>>
>> But can't this also affect other group_types? calculate_imbalance() can
>> set
>>
>>   env->migration_type = migrate_task;
>>
>> for
>>
>>   busiest->group_type > group_fully_busy
>
> yes but we are still in the case of evenly spread tasks on system with
> spare capacity. Also, this is already the behavior for such cases.

Ah, I was parsing 'imbalance' as 'group_imbalance' and didn't read
your 'evenly spread tasks' description as accounting this case.

Reviewed-by: Valentin Schneider <[email protected]>

Reply via email to