qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [RFC PATCH v3] numa: enable sparse node numbering


From: Nishanth Aravamudan
Subject: Re: [Qemu-devel] [RFC PATCH v3] numa: enable sparse node numbering
Date: Wed, 25 Jun 2014 09:13:59 -0700
User-agent: Mutt/1.5.21 (2010-09-15)

On 25.06.2014 [13:21:34 +0200], Igor Mammedov wrote:
> On Tue, 24 Jun 2014 10:40:38 -0700
> Nishanth Aravamudan <address@hidden> wrote:
<snip>
> > diff --git a/include/sysemu/sysemu.h b/include/sysemu/sysemu.h
> > index 277230d..b90bf66 100644
> > --- a/include/sysemu/sysemu.h
> > +++ b/include/sysemu/sysemu.h
> > @@ -145,11 +145,13 @@ extern int mem_prealloc;
> >   */
> >  #define MAX_CPUMASK_BITS 255
> >  
> > -extern int nb_numa_nodes;
> > +extern int nb_numa_nodes; /* Number of NUMA nodes */
> > +extern int max_numa_node; /* Highest specified NUMA node ID */
> >  typedef struct node_info {
> >      uint64_t node_mem;
> >      DECLARE_BITMAP(node_cpu, MAX_CPUMASK_BITS);
> >      struct HostMemoryBackend *node_memdev;
> > +    bool present;
> How about dropping 'present' and replacing array with a list
> of only present nodes?

If that would be preferred, I can move to that. I assume a simple
linked-list is fine. Does qemu provide any infrastructure for defining
lists? I'll look through the source but any pointers would be helpful.

Generally speaking, sparse NUMA nodes aren't that common and when they
exist, the gaps aren't large. But it does seem to make sense if we have
sparse IDs at all, we might as well move to a list.

In any case, moving to the list means we'd have a nodeid as part of the
structure instead.

> That way it will be one more step closer to converting numa
> infrastructure to a set of QOM objects.

Sounds like a good idea to me. I'll respin the patch soon.

Thanks,
Nish




reply via email to

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