Jython, GILs and object locking.
Andrew Dalke
adalke at mindspring.com
Thu Oct 9 15:30:53 EDT 2003
Alan Kennedy:
> Would the following statements be correct?
>
> 1. CPython has a Global Interpreter Lock (GIL), which allows only one
> thread to execute python code at a time. This "macro-level" of locking
> was chosen because empirical evidence from experimental
> implementations (a long time ago, in a galaxy far, far, away) showed
> that it gave better performance than approaches using more
> fine-grained locking, i.e. object-level locking.
I suspect it was done first because it was the easiest to do. Then
there was the free-threaded version, which provided the empirical
evidence.
Andrew
dalke at dalkescientific.com
More information about the Python-list
mailing list