Over the last few weeks, I have been working with Markus Metzger from
Intel to add support
for Precise Event-Based Sampling (PEBS) to his ds.c/ds.h interface. I
thought this could help
simplify some of the perfmon code.
The current ds.h/ds.c code in 2.6.25-rc8 does not yet have PEBS
support. It only has Branch
Trace Stack (BTS) support. Markus developed the PEBS extension. It is
fairly simple and
small. I strongly believe it should be included in mainline very soon.
To verify that it would
work correctly with perfmon, I did the experiment last week.
I just wanted to report to this list that I have now successfully
connected perfmon to ds.h. It allows
some more simplifications in perfmon. In particular, it does not have
to manage the DS_AREA
MSR on context switch anymore. Similarly, the layout differences
between Pentium 4 and
Intel Core processors for the DS_AREA are now hidden, meaning more
code can be factorized.
At the user level, it also simplifies the interface as we do not have
to expose as much information
as we used to (e.g., DS_AREA is not exposed anymore).
Overall I am satisfied with this patch and I recommend you accept the
extended ds.h/ds.c interface.