qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [RFC 0/7] Rework vhost memory region updates


From: Dr. David Alan Gilbert
Subject: Re: [Qemu-devel] [RFC 0/7] Rework vhost memory region updates
Date: Fri, 1 Dec 2017 10:19:09 +0000
User-agent: Mutt/1.9.1 (2017-09-22)

* Stefan Hajnoczi (address@hidden) wrote:
> On Wed, Nov 29, 2017 at 06:50:19PM +0000, Dr. David Alan Gilbert (git) wrote:
> > From: "Dr. David Alan Gilbert" <address@hidden>
> > 
> > Hi,
> >   This is an experimental set that reworks the way the vhost
> > code handles changes in physical address space layout that
> > came from a discussion with Igor.
> > 
> > Instead of updating and trying to merge sections of address
> > space on each add/remove callback, we wait until the commit phase
> > and go through and rebuild a list by walking the Flatview of
> > memory and end up producing an ordered list.
> > We compare the list to the old list to trigger updates.
> > 
> > Note, only very lightly tested so far, I'm just trying to see if it's
> > the right shape.
> 
> The cover letter doesn't mention why this change is necessary.  It would
> be helpful to know :).

The hope was to simplify it, and in particular make it easier for me
to add the bits I needed for postcopy support;  in the current code it
does a fairly complex merge procedure on each section ad/del call and
doesn't keep the structures in order.   Trying to add any more rules to
that just makes it more and more complex.

The hope is that this is simpler because we just do a linear walk of the
set of sections, which means any merging just happens with the top
element, and also the list is in order that's easier to work with.
Then it should be easier for me to add the postcopy stuff which needs
to do some hugepage merging.

(Bizarrely, after having rewritten the code from scratch completely
differently, the LoC is within a few lines of each other)

Dave

> Stefan


--
Dr. David Alan Gilbert / address@hidden / Manchester, UK



reply via email to

[Prev in Thread] Current Thread [Next in Thread]