Incorrect information for multiprocessing.Semaphore

There's a Note on the documentation for multiprocessing.Semaphore that says that sem_timedwait is unsupported on OS/X and that any timeout argument provided to acquire() will be ignored. I checked the Modules/_multiprocessing/semaphore.c code on the 2.6, 3.0, and 3.1 branches and I see that the module will fallback to sem_timedwait_save() if sem_timedwait is not available. That is, it will not ignore the timeout, but will instead emulate a timed wait using a sleep loop.

-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Am 17.05.2010 18:49, schrieb Mike Hobbs:
There's a Note on the documentation for multiprocessing.Semaphore that says that sem_timedwait is unsupported on OS/X and that any timeout argument provided to acquire() will be ignored. I checked the Modules/_multiprocessing/semaphore.c code on the 2.6, 3.0, and 3.1 branches and I see that the module will fallback to sem_timedwait_save() if sem_timedwait is not available. That is, it will not ignore the timeout, but will instead emulate a timed wait using a sleep loop.
Hi Mike, thanks for the report; this is now corrected in Subversion and should be online soon. regards, Georg -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.15 (GNU/Linux) iEYEARECAAYFAkv3BhoACgkQN9GcIYhpnLD1sgCeLTYRW1o3rWtR9x2kJb6FLuF7 8HkAoKtMzUX4+xkHdCLuQ97374fSz+HM =yXTn -----END PGP SIGNATURE-----
participants (2)
-
Georg Brandl
-
Mike Hobbs