All of lore.kernel.org
 help / color / mirror / Atom feed
From: Mike Galbraith <umgwanakikbuti@gmail.com>
To: Yuyang Du <yuyang.du@intel.com>
Cc: Morten Rasmussen <morten.rasmussen@arm.com>,
	Peter Zijlstra <peterz@infradead.org>,
	Rabin Vincent <rabin.vincent@axis.com>,
	"mingo@redhat.com" <mingo@redhat.com>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	Paul Turner <pjt@google.com>, Ben Segall <bsegall@google.com>
Subject: Re: [PATCH?] Livelock in pick_next_task_fair() / idle_balance()
Date: Fri, 03 Jul 2015 06:42:32 +0200	[thread overview]
Message-ID: <1435898552.6418.14.camel@gmail.com> (raw)
In-Reply-To: <20150702184234.GC5197@intel.com>

On Fri, 2015-07-03 at 02:42 +0800, Yuyang Du wrote:

> But still, I think, even with the above, in idle balancing, pulling until the source
> rq's nr_running == 1 is not just "a short term fix", but should be there permanently
> acting like a last guard with no overhead, why not.

Yeah, seems so.  Searching for steal all samples...
(this is all with autogroup)

load_balance: idle - s_run: 0  d_run: 2 s_load: 0  d_load: 3  imb: 23  det_tasks: 2  det_load: 3  zeros: 1
load_balance: idle - s_run: 0  d_run: 2 s_load: 0  d_load: 0  imb: 32  det_tasks: 2  det_load: 0  zeros: 2
load_balance: idle - s_run: 0  d_run: 2 s_load: 0  d_load: 1  imb: 17  det_tasks: 2  det_load: 1  zeros: 1
load_balance: idle - s_run: 0  d_run: 2 s_load: 0  d_load: 37  imb: 22  det_tasks: 2  det_load: 37  zeros: 1
load_balance: idle - s_run: 0  d_run: 2 s_load: 0  d_load: 0  imb: 102  det_tasks: 2  det_load: 0  zeros: 2


load_balance: idle - s_run: 0  d_run: 1 s_load: 0  d_load: 93  imb: 47  det_tasks: 1  det_load: 93  zeros: 0
load_balance: idle - s_run: 0  d_run: 2 s_load: 0  d_load: 202  imb: 125  det_tasks: 2  det_load: 202  zeros: 0
load_balance: idle - s_run: 0  d_run: 2 s_load: 0  d_load: 243  imb: 188  det_tasks: 2  det_load: 243  zeros: 0
load_balance: idle - s_run: 0  d_run: 1 s_load: 0  d_load: 145  imb: 73  det_tasks: 1  det_load: 145  zeros: 0
load_balance: idle - s_run: 0  d_run: 1 s_load: 0  d_load: 46  imb: 24  det_tasks: 1  det_load: 46  zeros: 0

Both varieties of total pilferage (w/wo 0 load tasks involved) seem to
happen only during idle balance, never periodic (yet).

Oddity: make -j8 occasionally stacks/pulls piles of load=dinky.

homer:/sys/kernel/debug/tracing # for i in `seq 1 10`; do cat trace|grep "s_run: 1.*det_tasks: $i.*zeros: 0"|wc -l; done
71634
1567
79
15
1
3
0
2
3
0
homer:/sys/kernel/debug/tracing # cat trace|grep "s_run: 1.*det_tasks: 8.*zeros: 0"
          <idle>-0     [002] dNs.   594.973783: load_balance: norm - s_run: 1  d_run: 9 s_load: 67  d_load: 1110  imb: 86  det_tasks: 8  det_load: 86  zeros: 0
           <...>-10367 [007] d...  1456.477281: load_balance: idle - s_run: 1  d_run: 8 s_load: 805  d_load: 22  imb: 45  det_tasks: 8  det_load: 22  zeros: 0
homer:/sys/kernel/debug/tracing # cat trace|grep "s_run: 1.*det_tasks: 9.*zeros: 0"
           <...>-23317 [004] d...   486.677925: load_balance: idle - s_run: 1  d_run: 9 s_load: 888  d_load: 27  imb: 47  det_tasks: 9  det_load: 27  zeros: 0
           <...>-11485 [002] d...   573.411095: load_balance: idle - s_run: 1  d_run: 9 s_load: 124  d_load: 78  imb: 82  det_tasks: 9  det_load: 78  zeros: 0
           <...>-23286 [000] d...  1510.378740: load_balance: idle - s_run: 1  d_run: 9 s_load: 102  d_load: 58  imb: 63  det_tasks: 9  det_load: 58  zeros: 0


  reply	other threads:[~2015-07-03  4:42 UTC|newest]

Thread overview: 31+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-06-30 14:30 [PATCH?] Livelock in pick_next_task_fair() / idle_balance() Rabin Vincent
2015-07-01  5:36 ` Mike Galbraith
2015-07-01 14:55   ` Rabin Vincent
2015-07-01 15:47     ` Mike Galbraith
2015-07-01 20:44     ` Peter Zijlstra
2015-07-01 23:25       ` Yuyang Du
2015-07-02  8:05         ` Mike Galbraith
2015-07-02  1:05           ` Yuyang Du
2015-07-02 10:25             ` Mike Galbraith
2015-07-02 11:40             ` Morten Rasmussen
2015-07-02 19:37               ` Yuyang Du
2015-07-03  9:34                 ` Morten Rasmussen
2015-07-03 16:38                   ` Peter Zijlstra
2015-07-05 22:31                     ` Yuyang Du
2015-07-09 14:32                       ` Morten Rasmussen
2015-07-09 23:24                         ` Yuyang Du
2015-07-05 20:12                   ` Yuyang Du
2015-07-06 17:36                     ` Dietmar Eggemann
2015-07-07 11:17                       ` Rabin Vincent
2015-07-13 17:43                         ` Dietmar Eggemann
2015-07-09 13:53                     ` Morten Rasmussen
2015-07-09 22:34                       ` Yuyang Du
2015-07-02 10:53         ` Peter Zijlstra
2015-07-02 11:44           ` Morten Rasmussen
2015-07-02 18:42             ` Yuyang Du
2015-07-03  4:42               ` Mike Galbraith [this message]
2015-07-03 16:39         ` Peter Zijlstra
2015-07-05 22:11           ` Yuyang Du
2015-07-09  6:15             ` Stefan Ekenberg
2015-07-26 18:57             ` Yuyang Du
2015-08-03 17:05             ` [tip:sched/core] sched/fair: Avoid pulling all tasks in idle balancing tip-bot for Yuyang Du

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=1435898552.6418.14.camel@gmail.com \
    --to=umgwanakikbuti@gmail.com \
    --cc=bsegall@google.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@redhat.com \
    --cc=morten.rasmussen@arm.com \
    --cc=peterz@infradead.org \
    --cc=pjt@google.com \
    --cc=rabin.vincent@axis.com \
    --cc=yuyang.du@intel.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 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.