From: Ingo Molnar <mingo@elte.hu>
To: eranian@gmail.com
Cc: Paul Mackerras <paulus@samba.org>,
Peter Zijlstra <a.p.zijlstra@chello.nl>,
Thomas Gleixner <tglx@linutronix.de>,
LKML <linux-kernel@vger.kernel.org>,
linux-arch@vger.kernel.org,
Andrew Morton <akpm@linux-foundation.org>,
Eric Dumazet <dada1@cosmosbay.com>,
Robert Richter <robert.richter@amd.com>,
Arjan van de Veen <arjan@infradead.org>,
Peter Anvin <hpa@zytor.com>, Steven Rostedt <rostedt@goodmis.org>,
David Miller <davem@davemloft.net>
Subject: Re: [patch 0/3] [Announcement] Performance Counters for Linux
Date: Mon, 8 Dec 2008 12:11:53 +0100 [thread overview]
Message-ID: <20081208111153.GA12377@elte.hu> (raw)
In-Reply-To: <7c86c4470812072318n33e27045k50490f180ecfd8c0@mail.gmail.com>
* stephane eranian <eranian@googlemail.com> wrote:
> Let me explain the HW complexity a bit. It's all a matter of tradeoffs.
> I have regular discussions with the PMU design architects about this.
> If you talk to them, then you understand the environment they have to
> live in and you understand why those constraints are there. The key
> point to understand is that the PMU is never critical to the chip. The
> chip can work well without. The real-estate on the chip is always very
> tight. PMU is a 2nd class citizen, thus low in the priority list. [...]
The chip designers i talk to with my scheduler maintainer hat on do point
out that performance monitoring is (of course) in the critical path of
any chip, and hence its overhead and impact on the gate count of various
critical components of the CPU core and its impact on the power envelope
must be kept very low.
Nevertheless, the same chip designers rely on performance counters on a
daily basis to plan their next-gen chip. They very much want them to work
fine, and they work hard on making them relevant and easy to use. Often
the performance counters are the _only_ real cheap hands-on insight into
the dynamic situation of a modern CPU core, even for hw designers.
And all the current hw trends show that it's not just talk but action as
well: the Core2 PMCs are already much saner (less constrained) than the
P4 ones, and now they even expanded on them: Nehalem / Core i7 doubled
the number of generic PMCs from two to four.
So, contrary to your suggestion, chip designers very much care about
performance counters and they are working very hard to make this stuff
useful to us. [ Yes, there are constraints even with generic counters
(for example you only want a single line towards a PMC register from
divider units), but the number of cross-counter constraints and their
relevance is decreasing, not increasing. ]
Anyway ... i think your reply highlights why the fundamental premise of
your patchset is so wrong: i believe you have designed your code and APIs
at the wrong level by (paradoxically) assuming in essence that
performance counters do not matter in the general scheme of things. (!)
So you introduced limited, special-purpose but still quite complex APIs
that tailored the ABIs to intricate low level details of PMUs. I see an
explosion in complexity due to that incorrect design choice: too many
syscalls, too broad interaction between core code and architecture code,
and too little practical utility in the end.
We did what we believe to be the right thing: we gave performance
counters the proper high-level abstraction they _deserve_, and we made
performance counters a prime-time Linux citizen as well.
Ingo
next prev parent reply other threads:[~2008-12-08 11:12 UTC|newest]
Thread overview: 74+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-12-04 23:44 [patch 0/3] [Announcement] Performance Counters for Linux Thomas Gleixner
2008-12-04 23:44 ` [patch 1/3] performance counters: core code Thomas Gleixner
2008-12-05 10:55 ` Paul Mackerras
2008-12-05 11:20 ` Ingo Molnar
2008-12-04 23:44 ` [patch 2/3] performance counters: documentation Thomas Gleixner
2008-12-05 0:33 ` Paul Mackerras
2008-12-05 0:37 ` David Miller
2008-12-05 2:50 ` Arjan van de Ven
2008-12-05 3:26 ` David Miller
2008-12-05 2:33 ` Andi Kleen
2008-12-04 23:45 ` [patch 3/3] performance counters: x86 support Thomas Gleixner
2008-12-05 0:22 ` [patch 0/3] [Announcement] Performance Counters for Linux Paul Mackerras
2008-12-05 6:31 ` Ingo Molnar
2008-12-05 7:02 ` Arjan van de Ven
2008-12-05 7:52 ` David Miller
2008-12-05 7:03 ` Ingo Molnar
2008-12-05 7:03 ` Ingo Molnar
2008-12-05 7:16 ` Peter Zijlstra
2008-12-05 7:57 ` Paul Mackerras
2008-12-05 8:03 ` Peter Zijlstra
2008-12-05 8:07 ` David Miller
2008-12-05 8:11 ` Ingo Molnar
2008-12-05 8:17 ` David Miller
2008-12-05 8:24 ` Ingo Molnar
2008-12-05 8:27 ` David Miller
2008-12-05 8:42 ` Ingo Molnar
2008-12-05 8:49 ` David Miller
2008-12-05 12:13 ` Ingo Molnar
2008-12-05 12:13 ` Ingo Molnar
2008-12-05 12:39 ` Andi Kleen
2008-12-05 20:08 ` David Miller
2008-12-10 3:48 ` Paul Mundt
2008-12-10 4:42 ` Paul Mackerras
2008-12-10 8:43 ` Mikael Pettersson
2008-12-10 10:28 ` Andi Kleen
2008-12-10 10:23 ` Paul Mundt
2008-12-10 11:03 ` Andi Kleen
2008-12-10 11:03 ` Andi Kleen
2008-12-10 10:28 ` Andi Kleen
2008-12-05 15:00 ` Arjan van de Ven
2008-12-05 9:16 ` Paul Mackerras
2008-12-05 7:57 ` David Miller
2008-12-05 8:18 ` Ingo Molnar
2008-12-05 8:20 ` David Miller
2008-12-05 7:54 ` Paul Mackerras
2008-12-05 8:08 ` Ingo Molnar
2008-12-05 8:15 ` David Miller
2008-12-05 13:25 ` Ingo Molnar
2008-12-05 9:10 ` Paul Mackerras
2008-12-05 12:07 ` Ingo Molnar
2008-12-06 0:05 ` Paul Mackerras
2008-12-06 1:23 ` Mikael Pettersson
2008-12-06 12:34 ` Peter Zijlstra
2008-12-07 5:15 ` Paul Mackerras
2008-12-08 7:18 ` stephane eranian
2008-12-08 11:11 ` Ingo Molnar [this message]
2008-12-08 11:58 ` David Miller
2008-12-09 0:21 ` stephane eranian
2008-12-09 0:21 ` stephane eranian
2008-12-05 0:22 ` H. Peter Anvin
2008-12-05 0:43 ` Paul Mackerras
2008-12-05 1:12 ` David Miller
2008-12-05 6:10 ` Ingo Molnar
2008-12-05 7:50 ` David Miller
2008-12-05 9:34 ` Paul Mackerras
2008-12-05 10:41 ` Ingo Molnar
2008-12-05 10:05 ` Ingo Molnar
2008-12-05 3:30 ` Andrew Morton
2008-12-06 2:36 ` stephane eranian
2008-12-08 2:12 ` [perfmon2] [patch 0/3] [Announcement] Performance Counters forLinux Dan Terpstra
2008-12-10 16:27 ` [patch 0/3] [Announcement] Performance Counters for Linux Rob Fowler
2008-12-10 16:27 ` [perfmon2] " Rob Fowler
2008-12-10 17:11 ` Andi Kleen
2008-12-10 17:11 ` Andi Kleen
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=20081208111153.GA12377@elte.hu \
--to=mingo@elte.hu \
--cc=a.p.zijlstra@chello.nl \
--cc=akpm@linux-foundation.org \
--cc=arjan@infradead.org \
--cc=dada1@cosmosbay.com \
--cc=davem@davemloft.net \
--cc=eranian@gmail.com \
--cc=hpa@zytor.com \
--cc=linux-arch@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=paulus@samba.org \
--cc=robert.richter@amd.com \
--cc=rostedt@goodmis.org \
--cc=tglx@linutronix.de \
/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