Re: [patch v5 02/15] sched: set initial load avg of new forked task

Preeti U Murthy
2013-02-28T07:04:46Z

Hi Alex,

>>> diff --git a/kernel/sched/fair.c b/kernel/sched/fair.c
>>> index 81fa536..cae5134 100644
>>> --- a/kernel/sched/fair.c
>>> +++ b/kernel/sched/fair.c
>>> @@ -1509,6 +1509,10 @@ static inline void enqueue_entity_load_avg(struct cfs_rq *cfs_rq,
>>> * We track migrations using entity decay_count <= 0, on a wake-up
>>> * migration we use a negative decay count to track the remote decays
>>> * accumulated while sleeping.
>>> + *
>>> + * When enqueue a new forked task, the se->avg.decay_count == 0, so
>>> + * we bypass update_entity_load_avg(), use avg.load_avg_contrib initial
>>> + * value: se->load.weight.
>>
>> I disagree with the comment.update_entity_load_avg() gets called for all
>> forked tasks.
>> enqueue_task_fair->update_entity_load_avg() during the second
>> iteration.But __update_entity_load_avg() in update_entity_load_avg()
>>
>
> When goes 'enqueue_task_fair->update_entity_load_avg()' during the
> second iteration. the se is changed.
> That is different se.
>
>
Correct Alex,sorry I overlooked this.

Regards
Preeti U Murthy