Re: [PATCH v9 02/10] sched: Track group sched_entity usage contributions

2014-11-24 Thread Morten Rasmussen
On Mon, Nov 24, 2014 at 02:04:21PM +, Vincent Guittot wrote:
> On 21 November 2014 at 13:35, Morten Rasmussen  
> wrote:
> > What happened to the update of se->avg.utilization_avg_contrib in
> > __synchronize_entity_decay()? It seems to have disapperead after v7.
> 
> It was moved in patch 1 where it is is right place

Ahh... I missed that :)
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH v9 02/10] sched: Track group sched_entity usage contributions

2014-11-24 Thread Vincent Guittot
On 21 November 2014 at 13:35, Morten Rasmussen  wrote:
> s/usage/utilization/ in subject.
>
> On Mon, Nov 03, 2014 at 04:54:39PM +, Vincent Guittot wrote:
>> From: Morten Rasmussen 
>>
>> Adds usage contribution tracking for group entities. Unlike
>
> s/usage contribution/utilization/
>
>> se->avg.load_avg_contrib, se->avg.utilization_avg_contrib for group
>> entities is the sum of se->avg.utilization_avg_contrib for all entities on 
>> the
>> group runqueue. It is _not_ influenced in any way by the task group
>> h_load. Hence it is representing the actual cpu usage of the group, not
>
> s/usage/utilization/
>
>> its intended load contribution which may differ significantly from the
>> utilization on lightly utilized systems.
>>
>> cc: Paul Turner 
>> cc: Ben Segall 
>>
>> Signed-off-by: Morten Rasmussen 
>> Signed-off-by: Vincent Guittot 
>> ---
>>  kernel/sched/debug.c | 2 ++
>>  kernel/sched/fair.c  | 3 +++
>>  2 files changed, 5 insertions(+)
>>
>> diff --git a/kernel/sched/debug.c b/kernel/sched/debug.c
>> index f384452..efb47ed 100644
>> --- a/kernel/sched/debug.c
>> +++ b/kernel/sched/debug.c
>> @@ -94,8 +94,10 @@ static void print_cfs_group_stats(struct seq_file *m, int 
>> cpu, struct task_group
>>   P(se->load.weight);
>>  #ifdef CONFIG_SMP
>>   P(se->avg.runnable_avg_sum);
>> + P(se->avg.running_avg_sum);
>>   P(se->avg.avg_period);
>>   P(se->avg.load_avg_contrib);
>> + P(se->avg.utilization_avg_contrib);
>>   P(se->avg.decay_count);
>>  #endif
>>  #undef PN
>> diff --git a/kernel/sched/fair.c b/kernel/sched/fair.c
>> index 3a91ae6..a171e1b 100644
>> --- a/kernel/sched/fair.c
>> +++ b/kernel/sched/fair.c
>> @@ -2529,6 +2529,9 @@ static long 
>> __update_entity_utilization_avg_contrib(struct sched_entity *se)
>>
>>   if (entity_is_task(se))
>>   __update_task_entity_utilization(se);
>> + else
>> + se->avg.utilization_avg_contrib =
>> + group_cfs_rq(se)->utilization_load_avg;
>>
>>   return se->avg.utilization_avg_contrib - old_contrib;
>>  }
>
> What happened to the update of se->avg.utilization_avg_contrib in
> __synchronize_entity_decay()? It seems to have disapperead after v7.

It was moved in patch 1 where it is is right place
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH v9 02/10] sched: Track group sched_entity usage contributions

2014-11-21 Thread Morten Rasmussen
s/usage/utilization/ in subject.

On Mon, Nov 03, 2014 at 04:54:39PM +, Vincent Guittot wrote:
> From: Morten Rasmussen 
> 
> Adds usage contribution tracking for group entities. Unlike

s/usage contribution/utilization/

> se->avg.load_avg_contrib, se->avg.utilization_avg_contrib for group
> entities is the sum of se->avg.utilization_avg_contrib for all entities on the
> group runqueue. It is _not_ influenced in any way by the task group
> h_load. Hence it is representing the actual cpu usage of the group, not

s/usage/utilization/

> its intended load contribution which may differ significantly from the
> utilization on lightly utilized systems.
> 
> cc: Paul Turner 
> cc: Ben Segall 
> 
> Signed-off-by: Morten Rasmussen 
> Signed-off-by: Vincent Guittot 
> ---
>  kernel/sched/debug.c | 2 ++
>  kernel/sched/fair.c  | 3 +++
>  2 files changed, 5 insertions(+)
> 
> diff --git a/kernel/sched/debug.c b/kernel/sched/debug.c
> index f384452..efb47ed 100644
> --- a/kernel/sched/debug.c
> +++ b/kernel/sched/debug.c
> @@ -94,8 +94,10 @@ static void print_cfs_group_stats(struct seq_file *m, int 
> cpu, struct task_group
>   P(se->load.weight);
>  #ifdef CONFIG_SMP
>   P(se->avg.runnable_avg_sum);
> + P(se->avg.running_avg_sum);
>   P(se->avg.avg_period);
>   P(se->avg.load_avg_contrib);
> + P(se->avg.utilization_avg_contrib);
>   P(se->avg.decay_count);
>  #endif
>  #undef PN
> diff --git a/kernel/sched/fair.c b/kernel/sched/fair.c
> index 3a91ae6..a171e1b 100644
> --- a/kernel/sched/fair.c
> +++ b/kernel/sched/fair.c
> @@ -2529,6 +2529,9 @@ static long 
> __update_entity_utilization_avg_contrib(struct sched_entity *se)
>  
>   if (entity_is_task(se))
>   __update_task_entity_utilization(se);
> + else
> + se->avg.utilization_avg_contrib =
> + group_cfs_rq(se)->utilization_load_avg;
>  
>   return se->avg.utilization_avg_contrib - old_contrib;
>  }

What happened to the update of se->avg.utilization_avg_contrib in
__synchronize_entity_decay()? It seems to have disapperead after v7.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[PATCH v9 02/10] sched: Track group sched_entity usage contributions

2014-11-03 Thread Vincent Guittot
From: Morten Rasmussen 

Adds usage contribution tracking for group entities. Unlike
se->avg.load_avg_contrib, se->avg.utilization_avg_contrib for group
entities is the sum of se->avg.utilization_avg_contrib for all entities on the
group runqueue. It is _not_ influenced in any way by the task group
h_load. Hence it is representing the actual cpu usage of the group, not
its intended load contribution which may differ significantly from the
utilization on lightly utilized systems.

cc: Paul Turner 
cc: Ben Segall 

Signed-off-by: Morten Rasmussen 
Signed-off-by: Vincent Guittot 
---
 kernel/sched/debug.c | 2 ++
 kernel/sched/fair.c  | 3 +++
 2 files changed, 5 insertions(+)

diff --git a/kernel/sched/debug.c b/kernel/sched/debug.c
index f384452..efb47ed 100644
--- a/kernel/sched/debug.c
+++ b/kernel/sched/debug.c
@@ -94,8 +94,10 @@ static void print_cfs_group_stats(struct seq_file *m, int 
cpu, struct task_group
P(se->load.weight);
 #ifdef CONFIG_SMP
P(se->avg.runnable_avg_sum);
+   P(se->avg.running_avg_sum);
P(se->avg.avg_period);
P(se->avg.load_avg_contrib);
+   P(se->avg.utilization_avg_contrib);
P(se->avg.decay_count);
 #endif
 #undef PN
diff --git a/kernel/sched/fair.c b/kernel/sched/fair.c
index 3a91ae6..a171e1b 100644
--- a/kernel/sched/fair.c
+++ b/kernel/sched/fair.c
@@ -2529,6 +2529,9 @@ static long 
__update_entity_utilization_avg_contrib(struct sched_entity *se)
 
if (entity_is_task(se))
__update_task_entity_utilization(se);
+   else
+   se->avg.utilization_avg_contrib =
+   group_cfs_rq(se)->utilization_load_avg;
 
return se->avg.utilization_avg_contrib - old_contrib;
 }
-- 
1.9.1

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/