public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Srivatsa Vaddagiri <vatsa@linux.vnet.ibm.com>
To: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: mingo@elte.hu, pjt@google.com, efault@gmx.de, venki@google.com,
	suresh.b.siddha@intel.com, linux-kernel@vger.kernel.org,
	" Nikunj A. Dadhania" <nikunj@linux.vnet.ibm.com>
Subject: Re: sched: Performance of Trade workload running inside VM
Date: Sat, 18 Feb 2012 13:11:27 +0530	[thread overview]
Message-ID: <20120218074127.GA9077@linux.vnet.ibm.com> (raw)
In-Reply-To: <1329327902.2293.168.camel@twins>

* Peter Zijlstra <a.p.zijlstra@chello.nl> [2012-02-15 18:45:02]:

> I'm still waiting for a problem description that isn't a book.
> 
> What does the load-balancer do,

select_idle_sibling() tries finding a core (sched group) which is fully idle
failing which will let task wakeup on prev_cpu.

> why is it wrong,

Take this scenario. wakeup source for task is cpu0 while its prev_cpu is
cpu7 (which is in another cache domain).

		cache_dom0		cache_dom1
		(0, 1) (2, 3)		(4, 5) (6, 7)
nr_running->	 1  1   1  1     	 0, 1   1, 2

In this case we let task wakeup on cpu7, resulting in it incurring some
wait time before being scheduled. A better choice would have been cpu4 (whose
core is partially idle) or in general any other less-loaded cpu which is in same
cache domain?

> why does your patch sort it etc.

The patch does result in a hunt for "least" busy cpu when the target cpu
returned by select_idle_sibling() is not idle - thus resulting in better
scheduling latencies for the task (and in turn better benchmark scores).

Another variant of the patch could be to have select_idle_sibling() look
for any idle cpu that is in same cache domain (rather than looking for a
whole group of cpus to be idle)?

- vatsa


  parent reply	other threads:[~2012-02-18  7:42 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-02-14 11:28 sched: Performance of Trade workload running inside VM Srivatsa Vaddagiri
2012-02-15 11:59 ` Peter Zijlstra
2012-02-15 17:10   ` Srivatsa Vaddagiri
2012-02-15 17:24     ` Peter Zijlstra
2012-02-15 17:38       ` Srivatsa Vaddagiri
2012-02-15 17:45         ` Peter Zijlstra
2012-02-15 17:56           ` Srivatsa Vaddagiri
2012-02-18  7:41           ` Srivatsa Vaddagiri [this message]
2012-02-20 14:56             ` Peter Zijlstra
2012-02-20 15:09               ` Srivatsa Vaddagiri
2012-02-15 17:26     ` Peter Zijlstra

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=20120218074127.GA9077@linux.vnet.ibm.com \
    --to=vatsa@linux.vnet.ibm.com \
    --cc=a.p.zijlstra@chello.nl \
    --cc=efault@gmx.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@elte.hu \
    --cc=nikunj@linux.vnet.ibm.com \
    --cc=pjt@google.com \
    --cc=suresh.b.siddha@intel.com \
    --cc=venki@google.com \
    /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