mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Tim Chen <tim.c.chen@linux.intel.com>
To: Linus Torvalds <torvalds@linux-foundation.org>,
	Mike Galbraith <efault@gmx.de>, Paul Turner <pjt@google.com>,
	Ingo Molnar <mingo@kernel.org>
Cc: Alex Shi <alex.shi@intel.com>,
	Changlong Xie <changlongx.xie@intel.com>,
	linux-kernel <linux-kernel@vger.kernel.org>,
	Peter Zijlstra <peterz@infradead.org>
Subject: Load balancing behavior for sched autogroup
Date: Fri, 29 Mar 2013 16:20:19 -0700	[thread overview]
Message-ID: <1364599219.27102.56.camel@schen9-DESK> (raw)

During our testings of 3.8 kernel, we noticed that after the patch

Revert "sched: Update_cfs_shares at period edge" (commit 17bc14b7), 

the load between the sockets or larger system can have 
large imbalance.  For example, for a 4 socket Westmere-EX 
(10 cores/socket), we notice the loadings between the sockets
can differ by more than a factor of 4. 

We did a simple experiment that kicks off 29 simple 
processes that execute a tight loop.  We noticed
socket 3 is already starting to schedule on hyperthreaded cpus 
(13 loaded cpus) while socket 1 still have lots of 
idle cores (3 loaded cpus).  Before the patch, the 
load was evenly distributed across sockets.  
If I turn off CONFIG_SCHED_AUTOGROUP,the loads are also 
distributed evenly.

(load on cpus, running on 4)
socket                    0                    1                    2                    3
---------------------------------------------------------------------------------------------
cpu:    0-3               0.00                 0.00                 0.00                99.00
cpu:    4-7               0.00                 0.00                 0.00                99.20
cpu:    8-11              0.00                 0.00                 0.00                99.00
cpu:   12-15             99.20                 0.00                 0.00                 0.00
cpu:   16-19              0.00                 0.00                 0.00                99.00
cpu:   20-23              0.00                 0.00                 0.00                 0.00
cpu:   24-27              0.00                 0.00                 0.00                 0.00
cpu:   28-31              0.00                 0.00                 0.00                 0.00
cpu:   32-35             99.20                 0.00                 0.00                99.00
cpu:   36-39             99.20                99.40                99.20                 0.00
cpu:   40-43              0.00                99.40                99.40                99.20
cpu:   44-47              0.00                99.40                99.40                99.20
cpu:   48-51             99.40                 0.00                99.40                99.20
cpu:   52-55             99.20                 0.00                99.40                99.20
cpu:   56-59              0.00                 0.00                99.40                99.40
cpu:   60-63              0.00                 0.00                 0.00                99.00
cpu:   64-67              0.00                 0.00                 0.00                99.40
cpu:   68-71              0.00                 0.00                 0.00                99.40
cpu:   72-75             99.40                 0.00                 0.00                 0.00
cpu:   76-79             99.40                 0.00                 0.00                 0.00
---------------------------------------------------------------------------------------------
Loaded cpus                  7                    3                    6                   13

Is this the intended behavior of sched autogroup? I'm a bit surprised 
that we are reserving this much cpu bandwidth for very low load 
processes (or interactive processes) in other groups.

So should the sched autogroup config option be turned off by default for server 
system, when we are not concerned about interactivity but want to maximize 
throughput by balancing out the load?

Thanks for clarifying.

Tim



             reply	other threads:[~2013-03-29 23:20 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-03-29 23:20 Tim Chen [this message]
2013-03-29 23:35 ` Paul Turner
2013-04-08 16:19   ` Tim Chen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1364599219.27102.56.camel@schen9-DESK \
    --to=tim.c.chen@linux.intel.com \
    --cc=alex.shi@intel.com \
    --cc=changlongx.xie@intel.com \
    --cc=efault@gmx.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@kernel.org \
    --cc=peterz@infradead.org \
    --cc=pjt@google.com \
    --cc=torvalds@linux-foundation.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®