What's new in Python 2.6
docs.python.org
docs.python.org
I would prefer not having a GIL, anyway, but this is far better than nothing.
This has been tried before, with disappointing results, which is why I'm reluctant to put much effort into it myself. In 1999 Greg Stein (with Mark Hammond?) produced a fork of Python (1.5 I believe) that removed the GIL, replacing it with fine-grained locks on all mutable data structures. He also submitted patches that removed many of the reliances on global mutable data structures, which I accepted. However, after benchmarking, it was shown that even on the platform with the fastest locking primitive (Windows at the time) it slowed down single-threaded execution nearly two-fold, meaning that on two CPUs, you could get just a little more work done without the GIL than on a single CPU with the GIL.
BTW, how is threading under Jython?
Update: Jython 2.5 Easter egg
>>> from __future__ import GIL
Traceback (most recent call last):
(no code object) at line 0
File "", line 0
SyntaxError: Never going to happen!
http://zyasoft.com/pythoneering/2008/06/realizing-jython-25...."To reduce memory usage, the garbage collector will now clear internal free lists when garbage-collecting the highest generation of objects. This may return memory to the operating system sooner."
For someone building long running processes or loading data generating millions of unique ints or floats over and over, this is major (though still hard to believe it was ever an issue).
The old behavior didn't effect server sized systems and typical workloads but it did piss off some embedded apps.