[Python-Dev] Reworking the GIL

Antoine Pitrou solipsis at pitrou.net
Sun Nov 1 23:27:35 CET 2009


Christian Heimes <lists <at> cheimes.de> writes:
> 
> +1 from me. I trust you like Brett does.
> 
> How much work would it cost to make your patch optional at compile time?

Quite a bit, because it changes the logic for processing asynchronous pending
calls (signals) and asynchronous exceptions in the eval loop. The #defines would
get quite convoluted, I think; I'd prefer not to do that.

> For what it's worth we could compare your work on different machines and
> on different platforms before it gets enabled by default. Can you
> imagine scenarios where your implementation might be slower than the
> current GIL implementation?

I don't really think so. The GIL is taken and released much more predictably
than it was before. The thing that might be worth checking is a workload with
many threads (say 50 or 100). Does anyone have that?

Regards

Antoine.




More information about the Python-Dev mailing list