[Lguest] [PATCH] lguest: Change over to using KVM hypercalls mechanism

Rusty Russell rusty at rustcorp.com.au
Mon Oct 20 10:50:41 EST 2008


On Monday 20 October 2008 05:23:10 Matias Zabaljauregui wrote:
> Hello,
>
> > Good question... I guess we should measure performance impact.  We could
> > rewrite the hypercall site to do an int 15 after the first time
> > (rewriting is what kvm does, so it's allowed).  Bonus is that old code
> > would "just work".
>
> Could you please elaborate on this? I´d like to help with this issue.

Hi Matias,

    Sorry I've been absent for so long.  I found some bugs in your PAE support 
patches on the weekend, too: expect mail soon.

    First step is to benchmark the old int $15 hypercalls vs the new fault 
hypercalls.  I'm sure you can come up with something (1,000,000 hypercalls in 
a test loop in the guest kernel or something).  If the new one really is 
slower, then the fault handler should simply do:

	if (is_hypercall())
		rewrite_hypercall();

    On returning to the guest, it would immediately do an int $15.  This is 
slow, but simple and we only have to rewrite once.

> My question is, should I build on top of my previous patchs, or should
> I wait until we arrive to a definitive soultion ?

Previous patches are OK, see feedback.

Cheers!
Rusty.



More information about the Lguest mailing list