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

Re: [Xen-devel] [PATCH 08 of 10 v3] libxl: enable automatic placement of guests on NUMA nodes

On 06/07/12 14:00, Dario Faggioli wrote:
On Fri, 2012-07-06 at 12:30 +0100, George Dunlap wrote:
One question I have:  Is there any particular reason to sort the whole
list, rather than just finding the maximum based on the comparison function?

That is basically a leftover from my previous "let's make things a bit
more general" approach. Don't get me wrong, I still think that and like
sorting more than anything else for the interface (although it's an
"internal interface") but yes, right now looking for the max won't be
anything different from sorting descending and taking the #0 element.

But I think it's been a long time and it looks good enough to me:

Acked-by: George Dunlap<george.dunlap@xxxxxxxxxxxxx>

Ok, I get this like I can leave it as it is... Or you want me to kill
the sorting?
I can't really foresee a time when anyone would want to use anything other than the best option. Just choosing the best makes a slightly simpler interface, and simplified the code somewhat. At the moment, sorting shouldn't take too long, but suppose we get systems with 128 nodes at some point in the future -- then the number of possible combinations might be pretty large, and sorting that even at n log n might take a noticeable amount of time.

So I think it's up to you: If you thinking sorting will be useful in the future, then I think keep it. But if you also think it's not going to be very useful, I think it would make more sense to take it out.


Xen-devel mailing list



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