All of lore.kernel.org
 help / color / mirror / Atom feed
* CFS group scheduler fairness broken starting from 2.6.29-rc1
@ 2009-07-23  7:57 Bharata B Rao
  2009-07-23 22:17 ` Ken Chen
  2009-07-27 12:09 ` Peter Zijlstra
  0 siblings, 2 replies; 7+ messages in thread
From: Bharata B Rao @ 2009-07-23  7:57 UTC (permalink / raw)
  To: linux-kernel
  Cc: Ingo Molnar, Peter Zijlstra, Dhaval Giani, Srivatsa Vaddagiri,
	Ken Chen, Balbir Singh

Hi,

Group scheduler fainess is broken since 2.6.29-rc1. git bisect led me
to this commit:

commit ec4e0e2fe018992d980910db901637c814575914
Author: Ken Chen <kenchen@google.com>
Date:   Tue Nov 18 22:41:57 2008 -0800

    sched: fix inconsistency when redistribute per-cpu tg->cfs_rq shares
    
    Impact: make load-balancing more consistent
    
    In the update_shares() path leading to tg_shares_up(), the calculation of
    per-cpu cfs_rq shares is rather erratic even under moderate task wake up
    rate.  The problem is that the per-cpu tg->cfs_rq load weight used in the
    sd_rq_weight aggregation and actual redistribution of the cfs_rq->shares
    are collected at different time.  Under moderate system load, we've seen
    quite a bit of variation on the cfs_rq->shares and ultimately wildly
    affects sched_entity's load weight.
    
    This patch caches the result of initial per-cpu load weight when doing the
    sum calculation, and then pass it down to update_group_shares_cpu() for
    redistributing per-cpu cfs_rq shares.  This allows consistent total cfs_rq
    shares across all CPUs. It also simplifies the rounding and zero load
    weight check.
    
    Signed-off-by: Ken Chen <kenchen@google.com>
    Acked-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
    Signed-off-by: Ingo Molnar <mingo@elte.hu>

======================================================================
			% CPU time division b/n groups
Group		2.6.29-rc1		2.6.29-rc1 w/o the above patch
======================================================================
a with 8 tasks	44			31
b with 5 tasks  32			34
c with 3 tasks  22			34
======================================================================
All groups had equal shares.

Regards,
Bharata.

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2009-08-02 13:13 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-07-23  7:57 CFS group scheduler fairness broken starting from 2.6.29-rc1 Bharata B Rao
2009-07-23 22:17 ` Ken Chen
2009-07-24  4:30   ` Bharata B Rao
2009-07-27 12:09 ` Peter Zijlstra
2009-07-28  4:14   ` Bharata B Rao
2009-07-28  7:28     ` Peter Zijlstra
2009-08-02 13:12   ` [tip:sched/core] sched: Fix cgroup smp fairness tip-bot for Peter Zijlstra

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.