On Tue, Mar 17, 2009 at 11:45:22AM +0100, Andi Kleen wrote: > On Tue, Mar 17, 2009 at 03:09:10AM +0200, Kornilios Kourtis wrote: > > Hi, > > > > I was wondering if you would be interested in adding a libnuma function > > for determing the node that a cpu belongs to. > > Concrete use case please. Why would you want to do that in a program? My specific case is quite simple: I have a program that creates a number of threads that are bound to run in specific cpus. I want to pre-allocate memory in the node of the cpu that the thread will run before the threads are created using numa_alloc_onnode(). Obviously, there isn't a hard requirement to include such a function in libnuma, since it could be implemented using existing functions, or make the allocations after the threads are spawned using numa_alloc_local(). On the other hand I'm guessing that it could be useful to other cases as well. cheers, -- Kornilios Kourtis -- To unsubscribe from this list: send the line "unsubscribe linux-numa" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html