On Mar 11, 2010, at 3:57 PM, Samuel Thibault wrote: > > What *is* hwloc's policy about thread safety, anyway? > > It would be odd to not be threadsafe, considering the target > applications :) and I believe hwloc is already.
Hmm. I'm not so sure. Consider: 1. thread A calls hwloc_topology_init(&a) 2. thread A calls hwloc_topology_load(a) 3. thread A launches thread B 4. thread B calls hwloc_topology_get_*(a...) 5. thread A calls hwloc_topology_load(a) On the one hand, you could say that an app would be dumb to do this. But OTOH, if we say that hwloc is "thread safe", it might be a reasonable expectation to assume that multiple threads can read/write topologies simultaneously and hwloc makes it safe. It depends on exactly what you mean by "thread safe" (kinda like MPI's 4 different levels of thread support). Which do we want for hwloc? -- Jeff Squyres jsquy...@cisco.com For corporate legal information go to: http://www.cisco.com/web/about/doing_business/legal/cri/