linux/arch/x86/kvm
Zhai, Edwin 4b8d54f972 KVM: VMX: Add support for Pause-Loop Exiting
New NHM processors will support Pause-Loop Exiting by adding 2 VM-execution
control fields:
PLE_Gap    - upper bound on the amount of time between two successive
             executions of PAUSE in a loop.
PLE_Window - upper bound on the amount of time a guest is allowed to execute in
             a PAUSE loop

If the time, between this execution of PAUSE and previous one, exceeds the
PLE_Gap, processor consider this PAUSE belongs to a new loop.
Otherwise, processor determins the the total execution time of this loop(since
1st PAUSE in this loop), and triggers a VM exit if total time exceeds the
PLE_Window.
* Refer SDM volume 3b section 21.6.13 & 22.1.3.

Pause-Loop Exiting can be used to detect Lock-Holder Preemption, where one VP
is sched-out after hold a spinlock, then other VPs for same lock are sched-in
to waste the CPU time.

Our tests indicate that most spinlocks are held for less than 212 cycles.
Performance tests show that with 2X LP over-commitment we can get +2% perf
improvement for kernel build(Even more perf gain with more LPs).

Signed-off-by: Zhai Edwin <edwin.zhai@intel.com>
Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
2009-12-03 09:32:17 +02:00
..
emulate.c KVM: x86 emulator: Add pusha and popa instructions 2009-12-03 09:32:09 +02:00
i8254.c KVM: Drop kvm->irq_lock lock from irq injection path 2009-12-03 09:32:08 +02:00
i8254.h KVM: PIT support for HPET legacy mode 2009-09-10 08:33:12 +03:00
i8259.c KVM: Move IO APIC to its own lock 2009-12-03 09:32:08 +02:00
irq.c KVM: Remove irq_pending bitmap 2009-06-10 11:48:57 +03:00
irq.h KVM: Move irq sharing information to irqchip level 2009-12-03 09:32:06 +02:00
Kconfig KVM: remove old KVMTRACE support code 2009-09-10 08:33:03 +03:00
kvm_cache_regs.h KVM: Cache pdptrs 2009-09-10 08:32:46 +03:00
kvm_timer.h KVM: Use pointer to vcpu instead of vcpu_id in timer code. 2009-09-10 08:32:52 +03:00
lapic.c KVM: remove duplicated #include 2009-12-03 09:32:10 +02:00
lapic.h KVM: x2apic interface to lapic 2009-09-10 08:33:08 +03:00
Makefile KVM: Move assigned device code to own file 2009-12-03 09:32:09 +02:00
mmu.c KVM: Don't pass kvm_run arguments 2009-12-03 09:32:06 +02:00
mmu.h KVM: MMU: add kvm_mmu_get_spte_hierarchy helper 2009-09-10 08:32:56 +03:00
mmutrace.h KVM: Trace shadow page lifecycle 2009-09-10 08:33:10 +03:00
paging_tmpl.h KVM: MMU: add SPTE_HOST_WRITEABLE flag to the shadow ptes 2009-10-04 17:04:50 +02:00
svm.c KVM: SVM: Remove nsvm_printk debugging code 2009-12-03 09:32:17 +02:00
timer.c KVM: Drop useless atomic test from timer function 2009-09-10 08:32:57 +03:00
trace.h KVM: SVM: Add tracepoint for skinit instruction 2009-12-03 09:32:16 +02:00
tss.h KVM: x86: hardware task switching support 2008-04-27 12:00:39 +03:00
vmx.c KVM: VMX: Add support for Pause-Loop Exiting 2009-12-03 09:32:17 +02:00
x86.c KVM: SVM: Add tracepoint for skinit instruction 2009-12-03 09:32:16 +02:00
x86.h KVM: Add Directed EOI support to APIC emulation 2009-09-10 08:33:07 +03:00