Guest PMU: Difference between revisions
From KVM
No edit summary |
m (Fix presentation link) |
||
Line 1: | Line 1: | ||
Guest PMU (Performance Monitoring Unit) currently exists in the form of an out-of-tree patchset. | Guest PMU (Performance Monitoring Unit) currently exists in the form of an out-of-tree patchset. | ||
See the [http://www.linux-kvm.org/wiki/images/6/6d/Kvm-forum-2011-performance-monitoring.pdf | See the [http://www.linux-kvm.org/wiki/images/6/6d/Kvm-forum-2011-performance-monitoring.pdf KVM Forum 2011 presentation] about the state as of August 2011. | ||
= Current status = | = Current status = |
Revision as of 03:56, 28 September 2011
Guest PMU (Performance Monitoring Unit) currently exists in the form of an out-of-tree patchset.
See the KVM Forum 2011 presentation about the state as of August 2011.
Current status
Version 1 Architectural PMU on Intel and AMD hosts is implemented and works.
TODO
Guest visible features
- Implement Version 2 Architectural PMU - allows faster switch times using PERF_GLOBAL_ENABLE MSR
- Implement Version 3 Architectural PMU
- Model specific PMU - allows access to more events and support for more tools; but restricts live migration capabilities
- Need per-event validation to avoid leaking socket-wide or core-wide information
- PEBS - Preceise Event Based Sampling - allows examining program state
- BTS - Branch Trace Store - allows tracing program execution accurately
Accuracy
- Update Joerg Roedel's exclude_guest/exclude_host patchset to support Intel hosts, using vmx's ability to load PERF_GLOBAL_ENABLE on vmentry/vmexit
Performance
- Investigate reports that enabling the guest PMU reduces performance
- Update the perf_event subsystem to make use of the PERF_GLOBAL_ENABLE MSR to speed up context switching, on both guest and host
- Check whether perf_event does unnecessary RMW operations on MSRs, which are significantly slow in a guest
- Add a paravirt batch MSR read/write facility, update perf to use it when available
- Change perf to use an ordinary interrupt instead of NMI when profiling only user space, or only a guest (reduces work in NMI context)
Git repositories
Guest PMU: git://github.com/avikivity/kvm.git pmu
exclude_host: git://github.com/avikivity/kvm.git perf-guest-counting