Re: [PATCH 1/1] perf tools: Add missing user space support forconfig1/config2

From: Vince Weaver
Date: Thu Apr 28 2011 - 18:11:14 EST


On Wed, 27 Apr 2011, Ingo Molnar wrote:

>
> Erm, that assumes you already know that magic incantation. Most of the users
> who want to do measurements and profiling do not know that. So there's little
> difference between:
>
> - someone shows them the 0x53cf28 magic code
> - someone shows them the L2_IFETCH:BOTH_CORES magic symbol
>
> So you while hexa values have like 10% utility, the stupid, vendor-specific
> event names you are pushing here have like 15% utility.
>
> In perf we are aiming for 100% utility, where if someone knows something about
> CPUs and can type 'cycles', 'instructions' or 'branches', will get the obvious
> result.
>
> This is not a difficult usability concept really.

yes, and this functionality belongs in the perf tool itself (or some other
user tool, like libpfm4, or PAPI). Not in the kernel.

How much larger are you willing to make the kernel to hold your
generalized events? PAPI has at least 128 that people have found useful
enough to add over the years. There are probably more.

I notice the kernel doesn't have any FP or SSE/Vector counts yet. Or
uops. Or hw-interrupt counts. Fused multiply-add?
How about GPU counters (PAPI is starting to support these)? Network
counters? Infiniband?

You're being lazy and pushing "perf" functionality into the kernel. It
belongs in userspace.

It's not the kernel's job to make things easy for users. Its job is to
make things possible, and get out of the way.

It's already bad enough that your generalized events can change from
kernel version to kernel version without warning. By being in the kernel,
aren't they a stable ABI that can't be changed?

Vince
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/