Den 21.07.2010 02:51, skrev Sturla Molden:

Therefore I think both a spinlock and a gillock should be added to the threading module. These are synchronization methods that should be available.


Avtually, a spinlock would probably not even be feasible in Python: The GIL is a mutex, and we would have to give it up before we could spin on the lock, and reacquire afterwards. So the cost of a kernel mutex object is still there. The gillock is possibly the only way of getting a fast lock object in Python.

Sturla