3 ms·
Preface: I rarely use Python. But to me, the logical, manageable thing seems to be a double implementation: one version with, one version without gil. Pick the
by tgv 3y ago
Preface: I rarely use Python. But to me, the logical, manageable thing seems to be a double implementation: one version with, one version without gil. Pick the one that suits you.
Computer vision often has tasks independent of the global state; pure functions, if you will. But many applications have different "state" pools all over the place. JIRA is written in Python. Their library for accessing their API alone is 8k lines of Python. I suspect JIRA's code base won't be all pure functions.
A large group (probably a comfortable majority) uses Python at a basic level. They may use numpy and matplot, but that's about it. They will notice a slow down when the GIL is removed. Don't expect smiles.
More advanced users may use concurrent code. If you use an external C library, chances are it has to be updated to work with a no-gil python version. This won't go swimmingly. It puts the burden on the maintainers of those libs, and they may not be able or willing to fix the problem. That will lead to unhappy faces.
And then there will be the subtle bugs in complex systems. Python programmers are not really used to synchronicity problems, so they'll slap locks all over the place, leading to slow down or dead-locks. More unhappy faces.
So I see the commitment to a single, no-GIL version as a serious threat to Python.