xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
From: Dario Faggioli <dario.faggioli@citrix.com>
To: Li Yechen <lccycc123@gmail.com>
Cc: Keir Fraser <keir@xen.org>, Jan Beulich <JBeulich@suse.com>,
	Stefano Stabellini <stefano.stabellini@eu.citrix.com>,
	George Dunlap <george.dunlap@eu.citrix.com>,
	Matt Wilson <msw@linux.com>,
	Elena Ufimtseva <ufimtseva@gmail.com>,
	xen-devel <xen-devel@lists.xenproject.org>
Subject: Re: [PATCH 1/7] xen: vNUMA support for PV guests
Date: Fri, 22 Nov 2013 19:29:34 +0100	[thread overview]
Message-ID: <1385144974.21426.64.camel@Solace> (raw)
In-Reply-To: <CAP5+zHQj-_uZe_AgbXOS=5Zi3gMQiXjSbJ7EEdGC-vq+L9f1Hw@mail.gmail.com>


[-- Attachment #1.1: Type: text/plain, Size: 4044 bytes --]

On gio, 2013-11-21 at 18:00 +0800, Li Yechen wrote:
> Dario,
> I just reply to this email again in case you haven't seen it :)
> 
No, don't worry, I haven't forgot. :-)

> On Tue, Oct 22, 2013 at 10:31 PM, Li Yechen <lccycc123@gmail.com>
> wrote:
>         Hi Elena,
>         
>         Congratulations to your work again!
>         
>         
>         Have you considered the other memory operations in
>         xen/common/memory.c?
>         
>         There are two important function: decrease_reservation(&args)
>         and  populate_physmap(&args)
>         
>         decrease_reservation(&args) remove pages from domain.
>         populate_physmap(&args) alloc pages for domain.
>
Yes, that's definitely something we need to adress, probably in this
patch series, even before thinking about NUMA aware ballooning.

>         Guest domain pass the mask of nodes to xen by these two
>         hypercalls. 
>         
>         For decrease_reservation, xen will also receive a number of
>         pages. We just free them from domain. Here, we should update
>         the memory size of vnodes and pnodes
>         (I think you keep a counter for the page numbers of each vnode
>         and pnode, something as vnuma_memszs, but please forgive me
>         that you have submitted such a huge patch that I could not
>         understand everything in time : - |    )
>         
>         For populate_physmap, xen will allocate blank pages from its
>         heap for domain guest, from specific nodes, according to the
>         nodemask. Here we should update your counters too!
>         
Well, I haven't gone re-check the code, but that does make sense.

In Edinburgh, Elena told me that she did some tests of ballooning with
her series applied, and nothing exploded (which is already
something. :-D).

We definitely should double check what happens, from where the pages
came /are taken from, and ensure the accounting is done right.

>         And as I see, we don't have a protocol here on whether the
>         nodemask in (&args ) is pnode or vnode.
>         
>         I think it should be vnode, since guest domain knows nothing
>         about the node affinity.
>         
>         So my idea could be: we communicate with guest domain using
>         vnode IDs. If we need to change the memory size of guest
>         domain, for example, memory increase/decrease on pnode[0],
>         we . And in the two functions of memory.c mentioned above, we
>         received the vnode_mask, transfer it back to pnode_mask, thus
>         it will work perfectly! And we don't need an extra hypercall
>         for guest domain any more!
>         
Mmm.. it may be me, but I'm not sure I follow. I agree that the guest
should speak vnode-s, but I'm not sure I get what you mean when you say
"use your node affinity to change pnode[0] to vnodes_mask, pass it to
guest domain".

Anyway, I was thinking, you did a pretty nice job on hacking something
together when for NUMA aware ballooning when vNUMA wasn't even released.
Now that Elena's patchset is out, how about you try to adapt what you
had at the time, plus the outcome of all that nice discussion we also
had, on top of it, and show us what happens? :-)

Elena's patches are not in the final form, but that should constitute a
fairly decent basis for another, and this time easier to understand and
to review, proof of concept implementation, isn't that so?

Of course, there's no hurry, this will definitely be something we'll
consider for the next release of Xen (so 4.5, not 4.4 which will
hopefully be released in January), i.e., there should be plenty of
time. :-D

What do you think?

Thanks and Regards,
Dario

-- 
<<This happens because I choose it to happen!>> (Raistlin Majere)
-----------------------------------------------------------------
Dario Faggioli, Ph.D, http://about.me/dario.faggioli
Senior Software Engineer, Citrix Systems R&D Ltd., Cambridge (UK)


[-- Attachment #1.2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 198 bytes --]

[-- Attachment #2: Type: text/plain, Size: 126 bytes --]

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
http://lists.xen.org/xen-devel

      reply	other threads:[~2013-11-22 18:29 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-10-16 22:37 [PATCH 1/7] xen: vNUMA support for PV guests Elena Ufimtseva
2013-10-17  9:05 ` Jan Beulich
2013-10-22 14:31   ` Li Yechen
2013-11-21 10:00     ` Li Yechen
2013-11-22 18:29       ` Dario Faggioli [this message]

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=1385144974.21426.64.camel@Solace \
    --to=dario.faggioli@citrix.com \
    --cc=JBeulich@suse.com \
    --cc=george.dunlap@eu.citrix.com \
    --cc=keir@xen.org \
    --cc=lccycc123@gmail.com \
    --cc=msw@linux.com \
    --cc=stefano.stabellini@eu.citrix.com \
    --cc=ufimtseva@gmail.com \
    --cc=xen-devel@lists.xenproject.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).