Re: [PATCH 6/7] perf, x86: Example code for AMD IBS

From: Robert Richter
Date: Wed Aug 03 2011 - 14:03:10 EST


On 03.08.11 04:27:08, Michael Cree wrote:
> On 02/08/11 22:37, Peter Zijlstra wrote:

> > Possibly, but having just looked at the example again I don't really see
> > it doing anything perf-record doesn't already do, so why does it deserve
> > to live at all?

I also got it running with perf-record with Lin's patch

perf tool: Parse general/raw events from sysfs

with no other changes using:

perf record -R -e ibs_fetch:r0 -a -c 10000 <command>

What is missing here is a parser for the IBS sampling data that is
very specific, which would be the perf-ibs-annotate tool you
recommended.

> > Initially I thought it was a record+report like example, some code
> > interpreting the 'mess' that comes out of IBS would be most appreciated
> > and I think we can even ship that as perf-ibs-report/perf-ibs-annotate
> > or so (and if its still remotely similar to its Alpha precursor that
> > might make the Alpha folks happy too).

Yes, the example I wrote could use perf-record as backend. The parser
for IBS could be part of perf-record, if we encode the pmu name
(ibs_op/ibs_fetch) in perf.data. Then we don't neeed a special tool
for IBS anymore.

> Sure would be nice if the infrastructure to support ProfileMe mode
> appeared in the perf. events subsystem. I am not going to go full out
> to implement all the support needed for it because there are too few
> users on Alpha to justify the effort. But if we could score an
> implementation of ProfileMe mode with minimal effort on the back of an
> AMD implementation that would make us happy.

ProfileMe looks similar to IBS, so the above would fit there too.

-Robert

--
Advanced Micro Devices, Inc.
Operating System Research Center

--
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/