[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [RFC] Next gen kvm api
From: |
Avi Kivity |
Subject: |
Re: [Qemu-devel] [RFC] Next gen kvm api |
Date: |
Sat, 18 Feb 2012 12:00:30 +0200 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:10.0) Gecko/20120131 Thunderbird/10.0 |
On 02/17/2012 02:19 AM, Alexander Graf wrote:
> >
> > Or we try to be less clever unless we have a really compelling reason.
> > qemu monitor and gdb support aren't compelling reasons to optimize.
>
> The goal here was simplicity with a grain of performance concerns.
>
Shared memory is simple in one way, but in other ways it is more
complicated since it takes away the kernel's freedom in how it manages
the data, how it's laid out, and whether it can lazify things or not.
> So what would you be envisioning? Should we make all of the MMU walker code
> in target-ppc KVM aware so it fetches that single way it actually cares about
> on demand from the kernel? That is pretty intrusive and goes against the
> general nicely fitting in principle of how KVM integrates today.
First, it's trivial, when you access a set you call
cpu_synchronize_tlb(set), just like how you access the registers when
you want them.
Second, and more important, how a random version of qemu works is
totally immaterial to the kvm userspace interface. qemu could change in
15 different ways and so could the kernel, and other users exist.
Fitting into qemu's current model is not a goal (if qemu happens to have
a good model, use it by all means; and clashing with qemu is likely an
indication the something is wrong -- but the two projects need to be
decoupled).
> Also, we need to store the guest TLB somewhere. With this model, we can just
> store it in user space memory, so we keep only a single copy around, reducing
> memory footprint. If we had to copy it, we would need more than a single copy.
That's the whole point. You could store it on the cpu hardware, if the
cpu allows it. Forcing it into always-synchronized shared memory takes
that ability away from you.
>
> >
> > At least on x86, we synchronize only rarely.
>
> Yeah, on s390 we only know which registers actually contain the information
> we need for traps / hypercalls when in user space, since that's where the
> decoding happens. So we better have all GPRs available to read from and write
> to.
>
Ok.
--
I have a truly marvellous patch that fixes the bug which this
signature is too narrow to contain.
- Re: [Qemu-devel] [RFC] Next gen kvm api, (continued)
- Re: [Qemu-devel] [RFC] Next gen kvm api, Avi Kivity, 2012/02/15
- Re: [Qemu-devel] [RFC] Next gen kvm api, Alexander Graf, 2012/02/15
- Re: [Qemu-devel] [RFC] Next gen kvm api, Avi Kivity, 2012/02/16
- Re: [Qemu-devel] [RFC] Next gen kvm api, Alexander Graf, 2012/02/16
- Re: [Qemu-devel] [RFC] Next gen kvm api, Avi Kivity, 2012/02/16
- Re: [Qemu-devel] [RFC] Next gen kvm api, Scott Wood, 2012/02/16
- Re: [Qemu-devel] [RFC] Next gen kvm api, Alexander Graf, 2012/02/16
- Re: [Qemu-devel] [RFC] Next gen kvm api, Scott Wood, 2012/02/17
- Re: [Qemu-devel] [RFC] Next gen kvm api, Avi Kivity, 2012/02/18
- Re: [Qemu-devel] [RFC] Next gen kvm api, Alexander Graf, 2012/02/16
- Re: [Qemu-devel] [RFC] Next gen kvm api,
Avi Kivity <=
- Re: [Qemu-devel] [RFC] Next gen kvm api, Alexander Graf, 2012/02/18
- Re: [Qemu-devel] [RFC] Next gen kvm api, Scott Wood, 2012/02/15
- Re: [Qemu-devel] [RFC] Next gen kvm api, Takuya Yoshikawa, 2012/02/12
- Re: [Qemu-devel] [RFC] Next gen kvm api, Avi Kivity, 2012/02/15
- Re: [Qemu-devel] [RFC] Next gen kvm api, Anthony Liguori, 2012/02/07
- Re: [Qemu-devel] [RFC] Next gen kvm api, Alexander Graf, 2012/02/07
- Re: [Qemu-devel] [RFC] Next gen kvm api, Alan Cox, 2012/02/08
- Re: [Qemu-devel] [RFC] Next gen kvm api, Avi Kivity, 2012/02/15
- Re: [Qemu-devel] [RFC] Next gen kvm api, Arnd Bergmann, 2012/02/16
Re: [Qemu-devel] [RFC] Next gen kvm api, Jamie Lokier, 2012/02/09