Martin v. Löwis <mar...@v.loewis.de> wrote: > OSX doesn't really support thread affinity. The affinity API that they > have is described on > > http://developer.apple.com/mac/library/releasenotes/Performance/RN-AffinityAPI/index.html > > You can't bind a thread to specific core with it, though, but you can > requests that multiple threads all run on the same core (leaving the > choice "which core" to the system).
I believe that would be sufficient to fix the problem with Python, though I wonder about the effect on JCC-generated modules like pylucene, where the threads are really Java threads as well as Python threads. So the patch to the threading code would presumably, for those OSs where the capability exists, try to put all created threads in the same affinity set. Presumably there would also be a way to clear that binding, for folks who know what they're doing. Bill _______________________________________________ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com