]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
Docs: Add central references to free-threading-related options (#119017)
authorBrett Simmers <swtaarrs@users.noreply.github.com>
Tue, 21 May 2024 21:49:23 +0000 (17:49 -0400)
committerGitHub <noreply@github.com>
Tue, 21 May 2024 21:49:23 +0000 (17:49 -0400)
Doc/c-api/module.rst
Doc/using/cmdline.rst
Doc/using/configure.rst
Doc/whatsnew/3.13.rst

index 6fe1ce9e99483208774ca65d5e1dbfa51222ab31..63e3bed67279878bbdfc2e3063d97e35735863b2 100644 (file)
@@ -427,14 +427,14 @@ The available slot types are:
    This slot is ignored by Python builds not configured with
    :option:`--disable-gil`.  Otherwise, it determines whether or not importing
    this module will cause the GIL to be automatically enabled. See
-   :envvar:`PYTHON_GIL` and :option:`-X gil <-X>` for more detail.
+   :ref:`free-threaded-cpython` for more detail.
 
    Multiple ``Py_mod_gil`` slots may not be specified in one module definition.
 
    If ``Py_mod_gil`` is not specified, the import machinery defaults to
    ``Py_MOD_GIL_USED``.
 
-   .. versionadded: 3.13
+   .. versionadded:: 3.13
 
 See :PEP:`489` for more details on multi-phase initialization.
 
index dcca9060899a0fced1899aecf7f9b7fc6c330330..7b2019625eb27a17b488df37dce2f6668d629365 100644 (file)
@@ -622,7 +622,8 @@ Miscellaneous options
 
    * :samp:`-X gil={0,1}` forces the GIL to be disabled or enabled,
      respectively. Only available in builds configured with
-     :option:`--disable-gil`. See also :envvar:`PYTHON_GIL`.
+     :option:`--disable-gil`. See also :envvar:`PYTHON_GIL` and
+     :ref:`free-threaded-cpython`.
 
      .. versionadded:: 3.13
 
@@ -1212,7 +1213,7 @@ conflict.
    forced on. Setting it to ``0`` forces the GIL off.
 
    See also the :option:`-X gil <-X>` command-line option, which takes
-   precedence over this variable.
+   precedence over this variable, and :ref:`free-threaded-cpython`.
 
    Needs Python configured with the :option:`--disable-gil` build option.
 
index d30356d2058effb5b5f1bf6b88746829fbd17277..428ee5275276a03d47c7c8f32faac823a43050db 100644 (file)
@@ -299,7 +299,7 @@ General Options
    Defines the ``Py_GIL_DISABLED`` macro and adds ``"t"`` to
    :data:`sys.abiflags`.
 
-   See :pep:`703` "Making the Global Interpreter Lock Optional in CPython".
+   See :ref:`free-threaded-cpython` for more detail.
 
    .. versionadded:: 3.13
 
index 8cd174f01ff6007e3f5d11d65618d8f415a7942a..7edfdd4f8167a0048551d9313ac9b6df2e914339 100644 (file)
@@ -368,7 +368,8 @@ CPython will run with the :term:`global interpreter lock` (GIL) disabled when
 configured using the ``--disable-gil`` option at build time. This is an
 experimental feature and therefore isn't used by default. Users need to
 either compile their own interpreter, or install one of the experimental
-builds that are marked as *free-threaded*.
+builds that are marked as *free-threaded*. See :pep:`703` "Making the Global
+Interpreter Lock Optional in CPython" for more detail.
 
 Free-threaded execution allows for full utilization of the available
 processing power by running threads in parallel on available CPU cores.