[Python-Dev] The endless GIL debate: why not remove thread support instead?

Christian Heimes lists at cheimes.de
Fri Dec 19 00:28:13 CET 2008


Paul Moore schrieb:
> OK, but how close is it to providing isolation for threads running
> under the control of the GIL? I'm thinking of something along the
> lines of an in-process version of fork(), which spawns a new
> interpreter and runs the 2 interpreters as threads, still using the
> GIL to enforce serialisation, but otherwise independent. I believe
> that Perl uses this model for its "interpreter threads"
> implementation.

How is your idea different from subinterpreters? Today you can have
multiple subinterpreters inside a single process. Each subinterpreter
has its own state and can see only its own objects.

Christian



More information about the Python-Dev mailing list