From: Odin Ugedal <odin@ugedal.com>
To: Vincent Guittot <vincent.guittot@linaro.org>
Cc: Odin Ugedal <odin@uged.al>, Ingo Molnar <mingo@redhat.com>,
Peter Zijlstra <peterz@infradead.org>,
Juri Lelli <juri.lelli@redhat.com>,
Dietmar Eggemann <dietmar.eggemann@arm.com>,
Steven Rostedt <rostedt@goodmis.org>,
Ben Segall <bsegall@google.com>, Mel Gorman <mgorman@suse.de>,
Daniel Bristot de Oliveira <bristot@redhat.com>,
"open list:CONTROL GROUP (CGROUP)" <cgroups@vger.kernel.org>,
linux-kernel <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH 0/1] sched/fair: Fix unfairness caused by missing load decay
Date: Tue, 27 Apr 2021 10:36:23 +0200 [thread overview]
Message-ID: <CAFpoUr2t0OXLJZi9wJzYg2uOhSLfwRa7sxCxxWzriJgXDsgEdA@mail.gmail.com> (raw)
In-Reply-To: <CAKfTPtBHm+CjBTA614P9F2Vx3Bj7vv9Pt0CGFsiwqcrTFmKzjg@mail.gmail.com>
Also, instead of bpftrace, one can look at the /proc/sched_debug file,
and infer from there.
Something like:
$ cat /proc/sched_debug | grep ":/slice" -A 28 | egrep "(:/slice)|load_avg"
gives me the output (when one stress proc gets 99%, and the other one 1%):
cfs_rq[0]:/slice/cg-2/sub
.load_avg : 1023
.removed.load_avg : 0
.tg_load_avg_contrib : 1035
.tg_load_avg : 1870
.se->avg.load_avg : 56391
cfs_rq[0]:/slice/cg-1/sub
.load_avg : 1023
.removed.load_avg : 0
.tg_load_avg_contrib : 1024
.tg_load_avg : 1847
.se->avg.load_avg : 4
cfs_rq[0]:/slice/cg-1
.load_avg : 4
.removed.load_avg : 0
.tg_load_avg_contrib : 4
.tg_load_avg : 794
.se->avg.load_avg : 5
cfs_rq[0]:/slice/cg-2
.load_avg : 56401
.removed.load_avg : 0
.tg_load_avg_contrib : 56700
.tg_load_avg : 57496
.se->avg.load_avg : 1008
cfs_rq[0]:/slice
.load_avg : 1015
.removed.load_avg : 0
.tg_load_avg_contrib : 1009
.tg_load_avg : 2314
.se->avg.load_avg : 447
As can be seen here, no other cfs_rq for the relevant cgroups are
"active" and listed, but they still contribute to eg. the "tg_load_avg". In this
example, "cfs_rq[0]:/slice/cg-1" has a load_avg of 4, and contributes with 4 to
tg_load_avg. However, the total total tg_load_avg is 794. That means
that the other 790 have to come from somewhere, and in this example,
they come from the cfs_rq on another cpu.
Hopefully that clarified a bit.
For reference, here is the output when the issue is not occuring:
cfs_rq[1]:/slice/cg-2/sub
.load_avg : 1024
.removed.load_avg : 0
.tg_load_avg_contrib : 1039
.tg_load_avg : 1039
.se->avg.load_avg : 1
cfs_rq[1]:/slice/cg-1/sub
.load_avg : 1023
.removed.load_avg : 0
.tg_load_avg_contrib : 1034
.tg_load_avg : 1034
.se->avg.load_avg : 49994
cfs_rq[1]:/slice/cg-1
.load_avg : 49998
.removed.load_avg : 0
.tg_load_avg_contrib : 49534
.tg_load_avg : 49534
.se->avg.load_avg : 1023
cfs_rq[1]:/slice/cg-2
.load_avg : 1
.removed.load_avg : 0
.tg_load_avg_contrib : 1
.tg_load_avg : 1
.se->avg.load_avg : 1023
cfs_rq[1]:/slice
.load_avg : 2048
.removed.load_avg : 0
.tg_load_avg_contrib : 2021
.tg_load_avg : 2021
.se->avg.load_avg : 1023
Odin
prev parent reply other threads:[~2021-04-27 8:37 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-04-25 8:09 [PATCH 0/1] sched/fair: Fix unfairness caused by missing load decay Odin Ugedal
2021-04-25 8:09 ` [PATCH 1/1] " Odin Ugedal
2021-04-27 14:26 ` Vincent Guittot
2021-04-28 13:10 ` Odin Ugedal
2021-04-28 15:35 ` Vincent Guittot
2021-04-28 15:50 ` Dietmar Eggemann
2021-05-01 14:41 ` Odin Ugedal
2021-05-05 9:43 ` Dietmar Eggemann
2021-05-01 14:33 ` Odin Ugedal
2021-04-26 14:58 ` [PATCH 0/1] " Vincent Guittot
2021-04-26 16:33 ` Odin Ugedal
2021-04-27 10:55 ` Vincent Guittot
2021-04-27 11:24 ` Odin Ugedal
2021-04-27 12:44 ` Vincent Guittot
2021-04-27 8:36 ` Odin Ugedal [this message]
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=CAFpoUr2t0OXLJZi9wJzYg2uOhSLfwRa7sxCxxWzriJgXDsgEdA@mail.gmail.com \
--to=odin@ugedal.com \
--cc=bristot@redhat.com \
--cc=bsegall@google.com \
--cc=cgroups@vger.kernel.org \
--cc=dietmar.eggemann@arm.com \
--cc=juri.lelli@redhat.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mgorman@suse.de \
--cc=mingo@redhat.com \
--cc=odin@uged.al \
--cc=peterz@infradead.org \
--cc=rostedt@goodmis.org \
--cc=vincent.guittot@linaro.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;
as well as URLs for NNTP newsgroup(s).