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

Re: [Xen-devel] [PATCH v2] credit: generalize __vcpu_has_soft_affinity()



On Fri, 2015-03-06 at 11:38 +0000, George Dunlap wrote:
> On 03/06/2015 11:12 AM, Dario Faggioli wrote:

> > ---
> > Hard affinity balancing is always necessary and must never be skipped.
> > Soft affinity balancing is only useful if it, potentially, makes a
> > difference.
> > 
> > In more details, there is no point checking soft affinity if:
> > * there is no online pCPU in the domain's cpupool that is not in the
> >   soft affinity mask
> > * there is no pCPU in the hard affinity mask that is not in the soft
> >   affinity mask
> > * there is no overlapping between the soft affinity mask and the mask
> >   being considered (which, in most cases, is the hard affinity mask)
> > ---
> 
> I think what you've said here is almost exactly the same thing as what I
> said, except using different words. (i.e., "X not a subset of Y" means
> "there are X which are not in Y")
> 
Well, of course it is! I mean, it wouldn't have, if you comment were
wrong, which it wasn't. :-)

It's also exactly my point. In fact, in this case, adding something like
what you're suggesting to the comment seems to me to be aimed at making
the reader able to understand the code faster, isn't it? If yes, then
the words "subset" is already used in the code, and suggesting to use
different words is the entire point I'm trying to make! :-)

> I don't mind necessarily, but I'm not sure you've actually accomplished
> your purpose. :-)
> 
That's more than possible possible... It's why comments are so important
and, sometimes, so hard to write, I think! :-D

Regards,
Dario

Attachment: signature.asc
Description: This is a digitally signed message part

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

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.