]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
[3.14] gh-138644: Update c-api docs of `PyInterpreterState` about PEP-684 (GH-138651...
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>
Thu, 11 Sep 2025 09:23:24 +0000 (11:23 +0200)
committerGitHub <noreply@github.com>
Thu, 11 Sep 2025 09:23:24 +0000 (12:23 +0300)
Co-authored-by: sobolevn <mail@sobolevn.me>
Co-authored-by: Peter Bierma <zintensitydev@gmail.com>
Doc/c-api/init.rst

index d34502f50b53dd1b48c947a40d7519a1eed08304..6a272a4f5fcb8742f55a473fdb64cff7f6ef00c4 100644 (file)
@@ -1184,6 +1184,12 @@ code, or when embedding the Python interpreter:
    interpreter lock is also shared by all threads, regardless of to which
    interpreter they belong.
 
+   .. versionchanged:: 3.12
+
+      :pep:`684` introduced the possibility
+      of a :ref:`per-interpreter GIL <per-interpreter-gil>`.
+      See :c:func:`Py_NewInterpreterFromConfig`.
+
 
 .. c:type:: PyThreadState
 
@@ -1875,6 +1881,8 @@ function. You can create and destroy them using the following functions:
    haven't been explicitly destroyed at that point.
 
 
+.. _per-interpreter-gil:
+
 A Per-Interpreter GIL
 ---------------------
 
@@ -1886,7 +1894,7 @@ being blocked by other interpreters or blocking any others.  Thus a
 single Python process can truly take advantage of multiple CPU cores
 when running Python code.  The isolation also encourages a different
 approach to concurrency than that of just using threads.
-(See :pep:`554`.)
+(See :pep:`554` and :pep:`684`.)
 
 Using an isolated interpreter requires vigilance in preserving that
 isolation.  That especially means not sharing any objects or mutable