Status of Python threading support (GIL removal)?

Carl Banks pavlovevidence at
Fri Jun 19 15:08:55 EDT 2009

On Jun 19, 6:53 am, Ben Charrow <bchar... at> wrote:
> Jure Erznožnik wrote:
> > See here for introduction:
> >
> > Digging through my problem, I discovered Python isn't exactly thread
> > safe and to solve the issue, there's this Global Interpreter Lock
> > (GIL) in place.
> > Effectively, this causes the interpreter to utilize one core when
> > threading is not used and .95 of a core when threading is utilized.
> > Is there any work in progess on core Python modules that will
> > permanently resolve this issue?
> > Is there any other way to work around the issue aside from forking new
> > processes or using something else?
> There is a group of people working on an alternative implementation to Python
> that, among other things, will not have a GIL:

That's not a foregone conclusion.  Well it's not a foregone conclusion
that unladen-swallow will succeed at all, but even if it does they
only say they intend to remove the GIL, not that they necessarily

The GIL actually "solves" two problems: the overhead of synchronizing
reference counts, and the difficulty of writing threaded extensions.
The unladen-swallow team only address the first problem in their
plans.  So, even if they do remove the GIL,  I doubt GvR will allow it
to be merged back into CPython unless makes extensions are just as
easy to write.  That is something I have serious doubts they can pull

Which means a GIL-less unladen-swallow is likely to end being another
fork like IronPython and Jython.  Those projects already have no GIL.

Carl Banks

More information about the Python-list mailing list