Hacker News new | ask | show | jobs
by stavros 704 days ago
Hmm, that's interesting, thank you. I didn't realize extensions can control the GIL.
1 comments

Yup, I think its described here: https://docs.python.org/3/c-api/init.html#releasing-the-gil-....

My understanding, is that many extensions will release the GIL when doing anything expensive. So, if you are doing CPU or IO bound operations in an extension _and_ you are calling that operation in multiple threads, even with the GIL you can potentially fully utilize all of the CPUs in your machine.