4 ms·
Jython and Iron Python lack the GIL. It's just an implementation detail of the underlying VM. There's nothing in the language itself which requires a GIL.
by ryanjl 9y ago
Jython and Iron Python lack the GIL. It's just an implementation detail of the underlying VM. There's nothing in the language itself which requires a GIL.
- fijal 9y agoC API... You can argue it's not a part of the language, but PyPy was forced to support it at the end
- xenadu02 9y agoIronPython interoperates with a whole host of C and C++ code. I'm not sure why this would matter? The initial implementation may need to assume single-threaded C interface support and take a global lock but it wouldn't be a stretch to have these things declare they are multithread aware and relax that restriction. Forgive me but most of these objections seem like post-hoc rationalizations. The first step is deciding to support a GIL-less multithreaded mode. After that, solve the problems one step at a time. It is amazing how many times accomplishing "magic" boils down to: 1. Decide we're going to solve this problem. 2. Iterate toward the solution in manageable steps. #1 is by far the most difficult aspect :)
- ryanjl 9y agoJython uses the JNI and IronPython does it through C++/CLI, neither of them support the CPython extension interface, meaning the C modules aren't compatible. Because of this, Jython and IronPython inherit the interface properties of their respective VMs and they can remain thread safe without the GIL.
- dom0 9y ago> It's just an implementation detail of the underlying VM. Python itself is just an implementation detail of the underlying VM.