From: Paolo Bonzini <pbonzini@redhat.com>
To: Gleb Natapov <gleb@kernel.org>
Cc: Avi Kivity <avi.kivity@gmail.com>,
Andy Lutomirski <luto@amacapital.net>,
kvm list <kvm@vger.kernel.org>
Subject: Re: Seeking a KVM benchmark
Date: Wed, 12 Nov 2014 12:33:32 +0100 [thread overview]
Message-ID: <5463458C.2070000@redhat.com> (raw)
In-Reply-To: <20141110173835.GA26770@minantech.com>
On 10/11/2014 18:38, Gleb Natapov wrote:
> On Mon, Nov 10, 2014 at 06:28:25PM +0100, Paolo Bonzini wrote:
>> On 10/11/2014 15:23, Avi Kivity wrote:
>>> It's not surprising [1]. Since the meaning of some PTE bits change [2],
>>> the TLB has to be flushed. In VMX we have VPIDs, so we only need to flush
>>> if EFER changed between two invocations of the same VPID, which isn't the
>>> case.
>>>
>>> [1] after the fact
>>> [2] although those bits were reserved with NXE=0, so they shouldn't have
>>> any TLB footprint
>>
>> You're right that this is not that surprising after the fact, and that
>> both Sandy Bridge and Ivy Bridge have VPIDs (even the non-Xeon ones).
>> This is also why I'm curious about the Nehalem.
>>
>> However note that even toggling the SCE bit is flushing the TLB. The
>> NXE bit is not being toggled here! That's the more surprising part.
>>
> Just a guess, but may be because writing EFER is not something that happens
> often in regular OSes it is not optimized to handle different bits differently.
Yes, that's what Intel said too.
Nehalem results:
userspace exit, urn 17560 17726 17628 17572 17417
lightweight exit, urn 3316 3342 3342 3319 3328
userspace exit, LOAD_EFER, guest!=host 12200 11772 12130 12164 12327
lightweight exit, LOAD_EFER, guest!=host 3214 3220 3238 3218 3337
userspace exit, LOAD_EFER, guest=host 11983 11780 11920 11919 12040
lightweight exit, LOAD_EFER, guest=host 3178 3193 3193 3187 3220
So the benchmark results also explain why skipping the LOAD_EFER does
not give a benefit for guest EFER=host EFER.
Paolo
next prev parent reply other threads:[~2014-11-12 11:33 UTC|newest]
Thread overview: 30+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-11-07 6:27 Seeking a KVM benchmark Andy Lutomirski
2014-11-07 7:17 ` Paolo Bonzini
2014-11-07 17:59 ` Andy Lutomirski
2014-11-07 18:11 ` Andy Lutomirski
2014-11-08 12:01 ` Gleb Natapov
2014-11-08 16:00 ` Andy Lutomirski
2014-11-08 16:44 ` Andy Lutomirski
2014-11-09 8:52 ` Gleb Natapov
2014-11-09 16:36 ` Andy Lutomirski
2014-11-10 10:03 ` Paolo Bonzini
2014-11-10 10:45 ` Gleb Natapov
2014-11-10 12:15 ` Paolo Bonzini
2014-11-10 14:23 ` Avi Kivity
2014-11-10 17:28 ` Paolo Bonzini
2014-11-10 17:38 ` Gleb Natapov
2014-11-12 11:33 ` Paolo Bonzini [this message]
2014-11-12 15:22 ` Gleb Natapov
2014-11-12 15:26 ` Paolo Bonzini
2014-11-12 15:32 ` Gleb Natapov
2014-11-12 15:51 ` Paolo Bonzini
2014-11-12 16:07 ` Andy Lutomirski
2014-11-12 17:56 ` Paolo Bonzini
2014-11-17 11:17 ` Wanpeng Li
2014-11-17 11:18 ` Paolo Bonzini
2014-11-17 12:00 ` Wanpeng Li
2014-11-17 12:04 ` Paolo Bonzini
2014-11-17 12:14 ` Wanpeng Li
2014-11-17 12:22 ` Paolo Bonzini
2014-11-11 11:07 ` Paolo Bonzini
2014-11-10 19:17 ` Andy Lutomirski
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=5463458C.2070000@redhat.com \
--to=pbonzini@redhat.com \
--cc=avi.kivity@gmail.com \
--cc=gleb@kernel.org \
--cc=kvm@vger.kernel.org \
--cc=luto@amacapital.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.