Basically yes. You can think of it as a more performant multiprocessing. Although the Python interface you mention will only be available in 3.13, for now it's strictly for the C API Answer from Yoghurt42 on reddit.com
Real Python
realpython.com โบ python312-subinterpreters
Python 3.12 Preview: Subinterpreters โ Real Python
May 3, 2024 - In this tutorial, you'll preview one of the upcoming features of Python 3.12 and a proposed change to Python 3.13, addressing how subinterpreters work in the CPython program. The changes are described in PEP 684 and PEP 554.
Are Python 3.12 subinterpreters multi-CPU? - Stack Overflow
Python 3.12 exposes the subinterpreter functionality: after starting the Python main.exe you can spawn multiple subinterpreter threads. Questions: As the subinterpreter threads run in the same pro... More on stackoverflow.com
cpython - ImportError with Numpy using Python/C 3.12 API subinterpreters - Stack Overflow
To prevent either a large number of bugs in existing extension modules or a lack of adoption of Python 3.12, methods were added so that when you want to import a module, Python can first determine whether itโs ready for this new feature. ... Note: If a subinterpreter with a per-interpreter ... More on stackoverflow.com
Independent SubInterpreters are still not concurrent with python 3.12+
I've removed any functions call even functions like sum(). It seems like SubInterpreter creations and even function starts are concurrent, but overall it's still synchronized on something (despite the fact that python 3.12+ should support per-interpreter GIL). More on github.com
Python 3.12 Preview: Subinterpreters โ Real Python
registation wall, can't read the article More on reddit.com
Videos
Reddit
reddit.com โบ r/python โบ what are the differences between python 3.12 sub-interpreters and multithreading/multiprocessing?
r/Python on Reddit: What are the differences between Python 3.12 sub-interpreters and multithreading/multiprocessing?
October 3, 2023 -
It seems like the new feature in Python 3.12 allows developers to create multiple sub-interpreters within a single main interpreter process. From the example from the PEP 554, sub-interpreters appear to be separate threads that run a dedicated piece of Python code and consequently have their own separate GILs.
interp = interpreters.create()
print('before')
interp.run('print("during")')
print('after')On practice, is this basically the new Pythonic way to run a single application in multiple threads and take advantage of multiple cores? If yes, can they be thought as multithreading with no shared state and become the future alternative of multiprocessing?
Top answer 1 of 6
60
Basically yes. You can think of it as a more performant multiprocessing. Although the Python interface you mention will only be available in 3.13, for now it's strictly for the C API
2 of 6
25
PEP 554 hasnโt been accepted and there is no interpreters module. The code that exists is C-API level only. Thereโs no Pythonic way to do it. The work accepted in 3.12 seems to be formalizing subinterpreters as a feature, where before it seemed somehow less official but still used by mod_wsgi.
Stack Overflow
stackoverflow.com โบ questions โบ 78766850 โบ are-python-3-12-subinterpreters-multi-cpu
Are Python 3.12 subinterpreters multi-CPU? - Stack Overflow
Python 3.12 exposes the subinterpreter functionality: after starting the Python main.exe you can spawn multiple subinterpreter threads. Questions: As the subinterpreter threads run in the same pro...
Readthedocs
pythondev.readthedocs.io โบ subinterpreters.html
Python Subinterpreters โ Unofficial Python Development (Victor's notes) documentation
Effects of the EXPERIMENTAL_ISOLATED_SUBINTERPRETERS macro: Good things! Per-interpreter GIL!!! Use a TSS to get the current Python thread state (โtstateโ)
GitHub
github.com โบ jsbueno โบ extrainterpreters
GitHub - jsbueno/extrainterpreters: Utilities for using Python's PEP 554 subinterpreters
This was made available in 2023 as Python 3.12 came out to allow some experiments and sending objects back and forth subinterpreters.
Starred by 122 users
Forked by 8 users
Languages ย Python 96.8% | C 3.2% | Python 96.8% | C 3.2%
Python
peps.python.org โบ pep-0554
PEP 554 โ Multiple Interpreters in the Stdlib | peps.python.org
Along with exposing the existing (in CPython) multiple interpreter support, the module will also support a basic mechanism for passing data between interpreters. That involves setting โshareableโ objects in the __main__ module of a target subinterpreter. Some such objects, like os.pipe(), may be used to communicate further.
Python documentation
docs.python.org โบ 3 โบ whatsnew โบ 3.12.html
What's New In Python 3.12 โ Python 3.14.3 documentation
February 23, 2026 - The feature was deprecated in Python 3.9. (Contributed by Victor Stinner in gh-94352.) The os module no longer accepts bytes-like paths, like bytearray and memoryview types: only the exact bytes type is accepted for bytes strings. (Contributed by Victor Stinner in gh-98393.) syslog.openlog() and syslog.closelog() now fail if used in subinterpreters.
LWN.net
lwn.net โบ Articles โบ 985041
Python subinterpreters and free-threading [LWN.net]
August 20, 2024 - In Python 3.11, there was one GIL per Python process, which is why multiprocessing is used for "fully parallel code execution". In Python 3.12, subinterpreters got their own GIL, so there was a GIL per interpreter. That means that two things can be running at once in a single Python process ...
GitHub
github.com โบ ninia โบ jep โบ issues โบ 593
Independent SubInterpreters are still not concurrent with python 3.12+ ยท Issue #593 ยท ninia/jep
January 23, 2025 - I've removed any functions call even functions like sum(). It seems like SubInterpreter creations and even function starts are concurrent, but overall it's still synchronized on something (despite the fact that python 3.12+ should support per-interpreter GIL).
Author ย novos40
GitHub
github.com โบ ChillFish8 โบ python12-subinterpreters
GitHub - ChillFish8/python12-subinterpreters: Some simple and hopefully safe-ish bindings to Python 3.12's sub-interpreters.
These are some safe-ish Rust bindings to the new CFFI API for creating and managing sub-interpreters within Python. ... Which will build and compile the library which can then be imported as subinterpreters.
Author ย ChillFish8
GitHub
github.com โบ pythonnet โบ pythonnet โบ issues โบ 2333
Support for creating python sub-interpreters ยท Issue #2333 ยท pythonnet/pythonnet
February 29, 2024 - One of the most exciting features of Python 3.12 is the possibility of creating sub-interpreters programmatically, each with an independent per-interpreter lock. This feature relies on a new C API function Py_NewInterpreterFromConfig. Ne...
Author ย glopesdev
Martin Heinz
martinheinz.dev โบ blog โบ 97
Real Multithreading is Coming to Python - Learn How You Can Use It Now | Martin Heinz | Personal Website & Blog
May 14, 2023 - While release of Python 3.12 is some months away, the code is already there, so let's take an early peek at how we can use it to write truly concurrent Python code using sub-interpreters API.
I Programmer
i-programmer.info โบ news โบ 216-python โบ 16652-python-312-is-out-and-it-has-sub-interpreters.html
Python 3.12 Is Out And It Has Sub-Interpreters - I Programmer
Programming book reviews, programming tutorials,programming news, C#, Ruby, Python,C, C++, PHP, Visual Basic, Computer book reviews, computer history, programming history, joomla, theory, spreadsheets and more.