Jirka Hladky, le Thu 11 Nov 2010 20:03:20 +0100, a écrit : > On Thursday, November 11, 2010 07:19:41 pm Samuel Thibault wrote: > > Jirka Hladky, le Thu 11 Nov 2010 14:50:46 +0100, a écrit : > > > "On this system function XYZ is not supported by GLIBC/KERNEL)" > > > > > > I'm missing the information: > > > > > > -which function is not implemented > > > > Well, you have it: hwloc_proc_getmembind() > > How it'd be called by the OS in the future is unknown of course. > > > > > -where this function belong - is it system call, glibc or hwloc's > > > function? > > > > It's always system call or glibc function, it depends on the system and > > we can't know where it'd be implemented in the future. Or our lack of > > knowledge of which system call can provide the functionality. > > Well, I think I have not expressed myself correctly. At the moment we have: > > hwloc_get_membind failed (errno 38 Function not implemented) > > I would like to see which glibc/system call has failed. > Example: > ============================================ > err = get_mempolicy(&linuxpolicy, linuxmask, max_os_index, 0, 0); > if (err < 0) { > perror("get_mempolicy"); <====== ADD THIS LINE > goto out_with_mask; > }
My point is that the fix here is _not_ about get_mempolicy. Hwloc didn't even call it. Hwloc just knows that Linux doesn't provide any function to get the mempolicy of another process. The get_mempolicy function doesn't take a pid, and thus will never take one, so another OS function will have to be defined in the future by Linux people, which will wear another name. So printing "get_mempolicy" will not actually help. > My first impression when I saw the error message above was that function > "hwloc_get_membind" is not implemented. hwloc_bind should probably print "hwloc_proc_get_membind" instead when it gives the flag, indeed. I don't think much more can be printed. Samuel