* Another question
@ 2013-03-26 16:57 Christoffer Dall
2013-03-31 17:17 ` Gleb Natapov
0 siblings, 1 reply; 2+ messages in thread
From: Christoffer Dall @ 2013-03-26 16:57 UTC (permalink / raw)
To: KVM General; +Cc: Gleb Natapov, Marcelo Tosatti
Hi guys,
I have an x86 question that I really hope you can help with:
Running the kvm-unit-tests on x86, I see a quite large difference
between I/O from the kernel, and I/O user (around 6,000 cycles) on two
separate platforms.
This is probably expected, but what is the explanation? If I correlate
with system call overhead from lmbench, it's nowhere near that (in the
hundreds of cycles), so I'm sure I'm missing something obvious.
Thanks!
-Christoffer
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: Another question
2013-03-26 16:57 Another question Christoffer Dall
@ 2013-03-31 17:17 ` Gleb Natapov
0 siblings, 0 replies; 2+ messages in thread
From: Gleb Natapov @ 2013-03-31 17:17 UTC (permalink / raw)
To: Christoffer Dall; +Cc: KVM General, Marcelo Tosatti
On Tue, Mar 26, 2013 at 09:57:00AM -0700, Christoffer Dall wrote:
> Hi guys,
>
> I have an x86 question that I really hope you can help with:
>
> Running the kvm-unit-tests on x86, I see a quite large difference
> between I/O from the kernel, and I/O user (around 6,000 cycles) on two
> separate platforms.
>
> This is probably expected, but what is the explanation? If I correlate
> with system call overhead from lmbench, it's nowhere near that (in the
> hundreds of cycles), so I'm sure I'm missing something obvious.
>
KVM does not restore full CPU host state on each vmexit since not all
the state is used by the kernel while KVM is running on the CPU. Some
state is restored only when vcpu thread is scheduled out from a host CPU
and some state is restored only when CPU moves to userspace. To exit to
userspace full host CPU state need to be restored.
--
Gleb.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2013-03-31 17:17 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-03-26 16:57 Another question Christoffer Dall
2013-03-31 17:17 ` Gleb Natapov
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox