On Tue, Nov 26, 2013 at 04:02:36PM +0800, Arthur Chunqi Li wrote: > Hi Gleb, > > I noticed that arch/x86/kvm/pmu.c is on your management and I have > some questions about PMU in KVM. Thanks ahead if you can spare time > answering these questions. > > 1. How could PMU cooperate with Intel VT? For example, I only find > flags in IA32_PERFEVTSELx MSRs to count in OS and USER mode (Ring 0 > and other rings). What is the consequence when I open VMXON with PMU > enabled? Can I distinguish the counts in root and non-root mode? I > cannot find the related descriptions in Intel manual. > No you cannot. You can disable/enable PMU counters before/after vmexit/vmentry and in this way know in what sate event was counted. That what MPU emulation does. > 2. What is the current status of vPMU in KVM? Is it auto-enabled? And > how can I use (or enable/disable) it? > If you run with -cpu host on Intel machine it will be enabled. -- Gleb. -- To unsubscribe from this list: send the line "unsubscribe kvm" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html