From: Paolo Bonzini Date: Fri, 21 Feb 2014 09:32:27 +0000 (+0100) Subject: KVM: vmx: Allow the guest to run with dirty debug registers X-Git-Tag: v3.15-rc1~118^2~25 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=81908bf44340eb5ebc9969f67e6c8be0c92f2857;p=pandora-kernel.git KVM: vmx: Allow the guest to run with dirty debug registers When not running in guest-debug mode (i.e. the guest controls the debug registers, having to take an exit for each DR access is a waste of time. If the guest gets into a state where each context switch causes DR to be saved and restored, this can take away as much as 40% of the execution time from the guest. If the guest is running with vcpu->arch.db == vcpu->arch.eff_db, we can let it write freely to the debug registers and reload them on the next exit. We still need to exit on the first access, so that the KVM_DEBUGREG_WONT_EXIT flag is set in switch_db_regs; after that, further accesses to the debug registers will not cause a vmexit. Signed-off-by: Paolo Bonzini --- Reading git-diff-tree failed