[Python-Dev] PEP Draft: Simplified Global Interpreter Lock acquisition for extensions
Guido van Rossum
guido@python.org
Wed, 05 Feb 2003 12:12:20 -0500
Good PEP, Mark. I support solving this problem once and for all.
One question: you claim that some implementation of TLS (Thread Local
Storage) is required to implement this API, but you don't give enough
implementation details to explain this requirement.
I wonder if instead of relying on TLS, you could return a void*
pointer from PyAutoThreadState_Ensure() which must be passed back into
PyAutoThreadState_Release()? Or is TLS used for something else too?
(I'm not a big fan of TLS, mostly because its API is different for
each native thread package; requiring it would make the burden of
providing the PyAutoThreadState API bigger.)
--Guido van Rossum (home page: http://www.python.org/~guido/)