From: George Dunlap <george.dunlap@eu.citrix.com>
To: Dario Faggioli <dario.faggioli@citrix.com>, xen-devel@lists.xen.org
Cc: keir@xen.org, Ian.Campbell@citrix.com, Andrew.Cooper3@citrix.com,
George.Dunlap@citrix.com, JBeulich@suse.com,
Ian.Jackson@citrix.com
Subject: Re: [v7 PATCH 03/10] xen: derive NUMA node affinity from hard and soft CPU affinity
Date: Tue, 10 Jun 2014 15:53:03 +0100 [thread overview]
Message-ID: <53971BCF.1090608@eu.citrix.com> (raw)
In-Reply-To: <20140610004443.16660.61987.stgit@Solace>
On 06/10/2014 01:44 AM, Dario Faggioli wrote:
> if a domain's NUMA node-affinity (which is what controls
> memory allocations) is provided by the user/toolstack, it
> just is not touched. However, if the user does not say
> anything, leaving it all to Xen, let's compute it in the
> following way:
>
> 1. cpupool's cpus & hard-affinity & soft-affinity
> 2. if (1) is empty: cpupool's cpus & hard-affinity
>
> This guarantees memory to be allocated from the narrowest
> possible set of NUMA nodes, ad makes it relatively easy to
> set up NUMA-aware scheduling on top of soft affinity.
>
> Note that such 'narrowest set' is guaranteed to be non-empty.
>
> Signed-off-by: Dario Faggioli <dario.faggioli@citrix.com>
> Reviewed-by: George Dunlap <george.dunlap@eu.citrix.com>
> Acked-by: Jan Beulich <jbeulich@suse.com>
> ---
> Chenges from v6:
> * fixed a bug when a domain was being created inside a
> cpupool;
This definitely should have erased the Reviewed-by, as it implies I
reviewed the bug fix.
> * coding style.
>
> Changes from v3:
> * avoid pointless calls to cpumask_clear(), as requested
> during review;
> * ASSERT() non emptyness of cpupool & hard affinity, as
> suggested during review.
>
> Changes from v2:
> * the loop computing the mask is now only executed when
> it really is useful, as suggested during review;
> * the loop, and all the cpumask handling is optimized,
> in a way similar to what was suggested during review.
> ---
> xen/common/domain.c | 61 +++++++++++++++++++++++++++++++------------------
> xen/common/schedule.c | 4 ++-
> 2 files changed, 42 insertions(+), 23 deletions(-)
>
> diff --git a/xen/common/domain.c b/xen/common/domain.c
> index e20d3bf..c3a576e 100644
> --- a/xen/common/domain.c
> +++ b/xen/common/domain.c
> @@ -409,17 +409,17 @@ struct domain *domain_create(
>
> void domain_update_node_affinity(struct domain *d)
> {
> - cpumask_var_t cpumask;
> - cpumask_var_t online_affinity;
> + cpumask_var_t dom_cpumask, dom_cpumask_soft;
> + cpumask_t *dom_affinity;
Also, just curious, did you rename these variables since the last series?
Acked-by: George Dunlap <george.dunlap@eu.citrix.com>
next prev parent reply other threads:[~2014-06-10 14:53 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-06-10 0:44 [v7 PATCH 00/10] Implement vcpu soft affinity for credit1 Dario Faggioli
2014-06-10 0:44 ` [v7 PATCH 01/10] xen: sched: rename v->cpu_affinity into v->cpu_hard_affinity Dario Faggioli
2014-06-10 0:44 ` [v7 PATCH 02/10] xen: sched: introduce soft-affinity and use it instead d->node-affinity Dario Faggioli
2014-06-10 11:26 ` George Dunlap
2014-06-10 0:44 ` [v7 PATCH 03/10] xen: derive NUMA node affinity from hard and soft CPU affinity Dario Faggioli
2014-06-10 14:53 ` George Dunlap [this message]
2014-06-10 15:20 ` Dario Faggioli
2014-06-10 15:33 ` George Dunlap
2014-06-10 0:44 ` [v7 PATCH 04/10] xen/libxc: sched: DOMCTL_*vcpuaffinity works with hard and soft affinity Dario Faggioli
2014-06-10 0:45 ` [v7 PATCH 05/10] libxc/libxl: bump library SONAMEs Dario Faggioli
2014-06-10 13:46 ` Ian Campbell
2014-06-10 0:45 ` [v7 PATCH 06/10] libxc: get and set soft and hard affinity Dario Faggioli
2014-06-10 0:45 ` [v7 PATCH 07/10] libxl: get and set soft affinity Dario Faggioli
2014-06-10 14:02 ` Ian Campbell
2014-06-11 7:13 ` Dario Faggioli
2014-06-10 15:39 ` George Dunlap
2014-06-10 15:44 ` Ian Campbell
2014-06-10 0:45 ` [v7 PATCH 08/10] xl: enable getting and setting soft Dario Faggioli
2014-06-10 14:10 ` Ian Campbell
2014-06-10 15:10 ` Dario Faggioli
2014-06-10 0:45 ` [v7 PATCH 09/10] xl: enable for specifying soft-affinity in the config file Dario Faggioli
2014-06-10 14:38 ` Ian Campbell
2014-06-10 15:36 ` Dario Faggioli
2014-06-10 15:46 ` Ian Campbell
2014-06-10 0:45 ` [v7 PATCH 10/10] libxl: automatic NUMA placement affects soft affinity Dario Faggioli
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=53971BCF.1090608@eu.citrix.com \
--to=george.dunlap@eu.citrix.com \
--cc=Andrew.Cooper3@citrix.com \
--cc=George.Dunlap@citrix.com \
--cc=Ian.Campbell@citrix.com \
--cc=Ian.Jackson@citrix.com \
--cc=JBeulich@suse.com \
--cc=dario.faggioli@citrix.com \
--cc=keir@xen.org \
--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.