Ethan Furman wrote: > On 02/22/2015 11:41 PM, Steven D'Aprano wrote: > >> If you want *CPython* to work without a GIL, well, are you volunteering >> to do the work? It is a massive job, and the core devs aren't terribly >> interested. Probably because they understand that the GIL is not often an >> unsurmountable problem in real life. That brings us to the point I was >> making: I believe, and the core devs appear to think the same, that the >> *actual* number of people who would benefit from CPython losing the GIL >> is not large enough to justify the work it would require. > > If memory serves, the first and primary point to losing the GIL is that > single-threaded code must run just as fast (or at least close to just as > fast) as the GIL version, and previous attempts have all badly failed that > requisite.
That was then. Now even smartphones have multiple cores. It might be time to reconsider. If not now, then surely by the time entry-level machines have 8 cores, the requirement that 1-core machines aren't penalized will surely be dropped :-) It may turn out that removing the GIL doesn't improve things *enough*, who knows what will happen. I recall from the first attempt, back in Python 1.5 days, that there was a 40% slowdown for single core machines, a very slight speedup for two-core, and increasing the number of cores beyond four made no real difference. So it might turn out that "removing the GIL" is great in theory and not so useful in practice, but I guess only time will tell. -- Steve -- https://mail.python.org/mailman/listinfo/python-list