All of lore.kernel.org
 help / color / mirror / Atom feed
From: Wei Liu <wei.liu2@citrix.com>
To: David Vrabel <david.vrabel@citrix.com>
Cc: Dario Faggioli <dario.faggioli@citrix.com>,
	Wei Liu <wei.liu2@citrix.com>, Jan Beulich <JBeulich@suse.com>,
	xen-devel@lists.xen.org
Subject: Re: RFC: vNUMA project
Date: Wed, 12 Nov 2014 12:14:48 +0000	[thread overview]
Message-ID: <20141112121448.GB28075@zion.uk.xensource.com> (raw)
In-Reply-To: <54624F6A.40002@citrix.com>

On Tue, Nov 11, 2014 at 06:03:22PM +0000, David Vrabel wrote:
> On 11/11/14 17:36, Wei Liu wrote:
> > # What's already implemented?
> > 
> > PV vNUMA support in libxl/xl and Linux kernel.
> 
> Linux doesn't have vnuma yet, although the last set of patches I saw
> looked fine and were waiting for acks from x86 maintainers I think.
> 

What I meant was I have those implemented but not yet posted. ;-)

> > # NUMA-aware ballooning
> > 
> > It's agreed that NUMA-aware ballooning should be achieved solely in
> > hypervisor. Everything should happen under the hood without guest
> > knowing vnode to pnode mapping.
> > 
> > As far as I can tell, existing guests (Linux and FreeBSD) use
> > XENMEM_populate_physmap to balloon up. There's a hypercall
> > called XENMEM_increase_reservation but it's not used
> > by Linux and FreeBSD.
> > 
> > I can think of two options to implement NUMA-aware ballooning:
> > 
> > 1. Modify XENMEM_populate_physmap to take into account vNUMA hint
> >    when it tries to allocate a page for guest.
> [...]
> > Option #1 requires less modification to guest, because guest won't
> > need to switch to new hypercall. It's unclear at this point if a guest
> > asks to populate a gpfn that doesn't belong to any vnode, what Xen
> > should do about it. Should it be permissive or strict? 
> 
> There are XENMEMF flags to request exact node or not  -- leave it up to
> the balloon driver.  The Linux balloon driver could try exact on all
> nodes before falling back to permissive or just always try inexact.
> 
> Perhaps a XENMEMF_vnode bit to indicate the node is virtual?
> 

Good idea. It should be easy to make it work.

> > 
> > # HVM vNUMA
> > 
> > HVM vNUMA is implemented as followed:
> > 
> > 1. Libxl generates vNUMA information and passes it to hvmloader.
> > 2. Hvmloader build SRAT table.
> > 
> > Note that hvmloader is capable of relocating memory. This means
> > toolstack and guest can have different ideas of the memory layout.
> 
> Why can't hvmloader update the vnuma tables after it has relocated memory?
> 

Because setvnuma is a domctl which cannot be issued by hvmloader.

Wei.

> David

  parent reply	other threads:[~2014-11-12 12:14 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-11-11 17:36 RFC: vNUMA project Wei Liu
2014-11-11 18:03 ` David Vrabel
2014-11-12  9:35   ` Jan Beulich
2014-11-12 13:45     ` Wei Liu
2014-11-12 14:13       ` Jan Beulich
2014-11-12 14:27         ` Wei Liu
2014-11-12 14:29           ` David Vrabel
2014-11-12 14:40             ` Wei Liu
2014-11-12 14:54               ` Jan Beulich
2014-11-12 12:14   ` Wei Liu [this message]
2014-11-12 14:23     ` Konrad Rzeszutek Wilk
2014-11-12 17:10       ` Wei Liu
2014-11-19 11:18 ` George Dunlap

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20141112121448.GB28075@zion.uk.xensource.com \
    --to=wei.liu2@citrix.com \
    --cc=JBeulich@suse.com \
    --cc=dario.faggioli@citrix.com \
    --cc=david.vrabel@citrix.com \
    --cc=xen-devel@lists.xen.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.