Re: State of current pv_ops backend for KVM?

Rusty Russell
2007-05-30T02:35:44Z

On Tue, 2007-05-29 at 17:00 +0300, Avi Kivity wrote:
> Anthony Liguori wrote:
> > Avi Kivity wrote:
> >> I think we should aim for a full direct paging implementation, where
> >> the cr3 cache is just the cherry on top that makes context switches
> >> proceed at native speed. Jun has a paper on it for OLS and I hope
> >> patches too.
> >
> > That's a bit more ambitious than I was thinking. I would be very
> > happy with a pv timer, interrupt controller, and some basic CPU
> > optimizations. I'm still not convinced the perf benefits of direct
> > paging justify the annoyances that come with it (guests being aware of
> > pfns).
>
> I thought that with paravirt_ops, all the awareness is limited to the
> paravirt implementation, and nothing in the core kernel is actually
> aware of host pfns.

It is, but now you've broken the abstraction you get other messes. You
can no longer simply swap out pages behind the guest's back, copy on
write or combine identical pages or other tricks without synchronizing
with the guest.

It can be done, but it's not clear to me that verifying PTEs is that
much faster than shadowing them if you're prepared to be that invasive
in the guest anyway.

Cheers,
Rusty.