lkml.org 
[lkml]   [2017]   [Dec]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v2] KVM: VMX: Cache IA32_DEBUGCTL in memory
2017-11-29 01:31-0800, Wanpeng Li:
> From: Wanpeng Li <wanpeng.li@hotmail.com>
>
> MSR_IA32_DEBUGCTLMSR is zeroed on VMEXIT, so it is saved/restored
> each time during world switch. Jim from Google pointed out that
> when running schbench in L2, vmx_vcpu_run will occupy 4% cpu time,
> and the 25% of vmx_vcpu_run cpu time is occupied by get_debugctlmsr().
> This patch caches the host IA32_DEBUGCTL MSR and saves/restores
> the host IA32_DEBUGCTL msr when guest/host switches to avoid to
> save/restore each time during world switch.
>
> Suggested-by: Jim Mattson <jmattson@google.com>
> Cc: Paolo Bonzini <pbonzini@redhat.com>
> Cc: Radim Krčmář <rkrcmar@redhat.com>
> Cc: Jim Mattson <jmattson@google.com>
> Signed-off-by: Wanpeng Li <wanpeng.li@hotmail.com>
> ---

Queued, thanks.

And there is another optimization loosely connected to the "[PATCH v3
00/16] Move vcpu_load and vcpu_put calls to arch code" series:
We only need to read the value for the KVM_RUN ioctl.

\
 
 \ /
  Last update: 2017-12-05 22:55    [W:0.091 / U:0.152 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site