From: Mark Brown <broonie@kernel.org>
To: Juri Lelli <juri.lelli@arm.com>
Cc: Rob Herring <robh@kernel.org>,
linux-kernel@vger.kernel.org, linux-pm@vger.kernel.org,
linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org,
peterz@infradead.org, vincent.guittot@linaro.org,
mark.rutland@arm.com, linux@arm.linux.org.uk,
sudeep.holla@arm.com, lorenzo.pieralisi@arm.com,
catalin.marinas@arm.com, will.deacon@arm.com,
morten.rasmussen@arm.com, dietmar.eggemann@arm.com,
Pawel Moll <pawel.moll@arm.com>,
Ian Campbell <ijc+devicetree@hellion.org.uk>,
Kumar Gala <galak@codeaurora.org>,
Maxime Ripard <maxime.ripard@free-electrons.com>,
Olof Johansson <olof@lixom.net>,
Gregory CLEMENT <gregory.clement@free-electrons.com>,
Paul Walmsley <paul@pwsan.com>,
Linus Walleij <linus.walleij@linaro.org>,
Chen-Yu Tsai <wens@csie.org>,
Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Subject: Re: [RFC PATCH 2/8] Documentation: arm: define DT cpu capacity bindings
Date: Mon, 14 Dec 2015 16:59:28 +0000 [thread overview]
Message-ID: <20151214165928.GV5727@sirena.org.uk> (raw)
In-Reply-To: <20151214123616.GC3308@e106622-lin>
[-- Attachment #1: Type: text/plain, Size: 5012 bytes --]
On Mon, Dec 14, 2015 at 12:36:16PM +0000, Juri Lelli wrote:
> On 11/12/15 17:49, Mark Brown wrote:
> > The purpose of the capacity values is to influence the scheduler
> > behaviour and hence performance. Without a concrete definition they're
> > just magic numbers which have meaining only in terms of their effect on
> > the performance of the system. That is a sufficiently complex outcome
> > to ensure that there will be an element of taste in what the desired
> > outcomes are. Sounds like tuneables to me.
> Capacity values are meant to describe asymmetry (if any) of the system
> CPUs to the scheduler. The scheduler can then use this additional bit of
> information to try to do better scheduling decisions. Yes, having these
> values available will end up giving you better performance, but I guess
> this apply to any information we provide to the kernel (and scheduler);
> the less dumb a subsystem is, the better we can make it work.
This information is a magic number, there's never going to be a right
answer. If it needs changing it's not like the kernel is modeling a
concrete thing like the relative performance of the A53 and A57 poorly
or whatever, it's just that the relative values of number A and number B
are not what the system integrator desires.
> > If you are saying people should use other, more sensible, ways of
> > specifying the final values that actually get used in production then
> > why take the defaults from direct numbers DT in the first place? If you
> > are saying that people should tune and then put the values in here then
> > that's problematic for the reasons I outlined.
> IMHO, people should come up with default values that describe
> heterogeneity in their system. Then use other ways to tune the system at
> run time (depending on the workload maybe).
My argument is that they should be describing the hetrogeneity of their
system by describing concrete properties of their system rather than by
providing magic numbers.
> As said, I understand your concerns; but, what I don't still get is
> where CPU capacity values are so different from, say, idle states
> min-residency-us. AFAIK there is a per-SoC benchmarking phase required
> to come up with that values as well; you have to pick some benchmark
> that stresses worst case entry/exit while measuring energy, then make
> calculations that tells you when it is wise to enter a particular idle
> state. Ideally we should derive min residency from specs, but I'm not
> sure is how it works in practice.
Those at least have a concrete physical value that it is possible to
measure in a describable way that is unlikely to change based on the
internals of the kernel. It would be kind of nice to have the broken
down numbers for entry time, exit time and power burn in suspend but
it's not clear it's worth the bother. It's also one of these things
where we don't have any real proxies that get us anywhere in the
ballpark of where we want to be.
> > It also seems a bit strange to expect people to do some tuning in one
> > place initially and then additional tuning somewhere else later, from
> > a user point of view I'd expect to always do my tuning in the same
> > place.
> I think that runtime tuning needs are much more complex and have finer
> grained needs than what you can achieve by playing with CPU capacities.
> And I agree with you, users should only play with these other methods
> I'm referring to; they should not mess around with platform description
> bits. They should provide information about runtime needs, then the
> scheduler (in this case) will do its best to give them acceptable
> performance using improved knowledge about the platform.
So then why isn't it adequate to just have things like the core types in
there and work from there? Are we really expecting the tuning to be so
much better than it's possible to come up with something that's so much
better on the scale that we're expecting this to be accurate that it's
worth just jumping straight to magic numbers?
> > Doing that and then switching to some other interface for real tuning
> > seems especially odd and I'm not sure that's something that users are
> > going to expect or understand.
> As I'm saying above, users should not care about this first step of
> platform description; not more than how much they care about other bits
> in DTs that describe their platform.
That may be your intention but I don't see how it is realistic to expect
that this is what people will actually understand. It's a number, it
has an effect and it's hard to see that people won't tune it, it's not
like people don't have to edit DTs during system integration. People
won't reliably read documentation or look in mailing list threads and
other that that it has all the properties of a tuning interface.
There's a tension here between what you're saying about people not being
supposed to care much about the numbers for tuning and the very fact
that there's a need for the DT to carry explicit numbers.
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 473 bytes --]
next prev parent reply other threads:[~2015-12-14 16:59 UTC|newest]
Thread overview: 57+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-11-23 14:28 [RFC PATCH 0/8] CPUs capacity information for heterogeneous systems Juri Lelli
2015-11-23 14:28 ` [RFC PATCH 1/8] ARM: initialize cpu_scale to its default Juri Lelli
2015-11-30 11:13 ` Vincent Guittot
2015-11-23 14:28 ` [RFC PATCH 2/8] Documentation: arm: define DT cpu capacity bindings Juri Lelli
2015-11-24 2:06 ` Rob Herring
2015-11-24 10:54 ` Juri Lelli
2015-11-30 9:59 ` Vincent Guittot
2015-12-01 11:20 ` Juri Lelli
2015-12-10 14:14 ` Dietmar Eggemann
2015-12-11 10:09 ` Juri Lelli
2015-12-10 15:30 ` Mark Brown
2015-12-10 17:58 ` Juri Lelli
2015-12-11 17:49 ` Mark Brown
2015-12-14 12:36 ` Juri Lelli
2015-12-14 16:59 ` Mark Brown [this message]
2015-12-15 12:22 ` Juri Lelli
2015-12-15 13:39 ` Mark Brown
2015-12-15 14:01 ` Mark Rutland
2015-12-15 14:24 ` Juri Lelli
2015-12-15 14:50 ` Mark Rutland
2015-12-15 15:36 ` Juri Lelli
2015-12-15 15:08 ` Mark Brown
2015-12-15 15:32 ` Mark Rutland
2015-12-15 15:46 ` Juri Lelli
2015-12-15 15:57 ` Mark Rutland
2015-12-15 16:23 ` Catalin Marinas
2015-12-15 16:41 ` Mark Rutland
2015-12-15 16:59 ` Vincent Guittot
2015-12-15 17:15 ` Mark Rutland
2015-12-15 17:47 ` Vincent Guittot
2015-12-15 18:39 ` Mark Rutland
2015-12-15 17:17 ` Mark Brown
2015-12-15 17:28 ` Mark Rutland
2015-12-15 17:45 ` Mark Brown
2015-12-15 18:10 ` Mark Rutland
2015-12-15 18:45 ` Mark Brown
2015-12-17 9:07 ` Juri Lelli
2015-12-15 13:55 ` Vincent Guittot
2015-11-23 14:28 ` [RFC PATCH 3/8] arm: parse cpu capacity from DT Juri Lelli
2015-12-10 14:14 ` Dietmar Eggemann
2015-12-11 10:12 ` Juri Lelli
2015-11-23 14:28 ` [RFC PATCH 4/8] arm, dts: add TC2 cpu capacity information Juri Lelli
2015-11-23 14:28 ` [RFC PATCH 5/8] arm64: parse cpu capacity from DT Juri Lelli
2015-12-10 14:15 ` Dietmar Eggemann
2015-12-11 10:07 ` Juri Lelli
2015-11-23 14:28 ` [RFC PATCH 6/8] arm64, dts: add Juno cpu capacity information Juri Lelli
2015-11-23 14:28 ` [RFC PATCH 7/8] arm: add sysfs cpu_capacity attribute Juri Lelli
2015-11-23 14:28 ` [RFC PATCH 8/8] arm64: " Juri Lelli
2015-12-10 14:15 ` Dietmar Eggemann
2015-12-10 15:59 ` Mark Brown
2015-12-10 18:01 ` Juri Lelli
2015-12-11 17:54 ` Mark Brown
2015-12-07 12:02 ` [RFC PATCH 0/8] CPUs capacity information for heterogeneous systems Juri Lelli
2015-12-07 12:11 ` Russell King - ARM Linux
2015-12-07 12:36 ` Juri Lelli
2015-12-07 13:18 ` Russell King - ARM Linux
2015-12-07 15:41 ` Juri Lelli
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=20151214165928.GV5727@sirena.org.uk \
--to=broonie@kernel.org \
--cc=catalin.marinas@arm.com \
--cc=devicetree@vger.kernel.org \
--cc=dietmar.eggemann@arm.com \
--cc=galak@codeaurora.org \
--cc=gregory.clement@free-electrons.com \
--cc=ijc+devicetree@hellion.org.uk \
--cc=juri.lelli@arm.com \
--cc=linus.walleij@linaro.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pm@vger.kernel.org \
--cc=linux@arm.linux.org.uk \
--cc=lorenzo.pieralisi@arm.com \
--cc=mark.rutland@arm.com \
--cc=maxime.ripard@free-electrons.com \
--cc=morten.rasmussen@arm.com \
--cc=olof@lixom.net \
--cc=paul@pwsan.com \
--cc=pawel.moll@arm.com \
--cc=peterz@infradead.org \
--cc=robh@kernel.org \
--cc=sudeep.holla@arm.com \
--cc=thomas.petazzoni@free-electrons.com \
--cc=vincent.guittot@linaro.org \
--cc=wens@csie.org \
--cc=will.deacon@arm.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
all inboxes | Powered by JetHome®