The reliability of python threads
Thu Jan 25 01:11:07 CET 2007
"Klaas" <mike.klaas at gmail.com> writes:
> POSIX issues aside, Python's threading model should be less susceptible
> to memory-barrier problems that are possible in other languages (this
> is due to the GIL).
But the GIL is not part of Python's threading model; it's just a
particular implementation artifact. Programs that rely on it are
asking for trouble.
> Double-checked locking, frinstance, is safe in python even though it
> isn't in java.
> Are you ever relying solely on the GIL to access shared data?
I think a lot of programs do that, which is probably unwise in the
More information about the Python-list