GH-113464: Add the JIT to What's New by brandtbucher · Pull Request #133486 · python/cpython · GitHub
Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 15 additions & 8 deletions Doc/using/configure.rst
31 changes: 31 additions & 0 deletions Doc/whatsnew/3.14.rst
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,7 @@ Summary -- release highlights
:ref:`argparse <whatsnew314-color-argparse>`,
:ref:`json <whatsnew314-color-json>` and
:ref:`calendar <whatsnew314-color-calendar>` CLIs
* :ref:`Binary releases for the experimental just-in-time compiler <whatsnew314-jit-compiler>`


Incompatible changes
Expand Down Expand Up @@ -715,6 +716,36 @@ in the :envvar:`PYTHONSTARTUP` script.
(Contributed by Łukasz Langa in :gh:`131507`.)


.. _whatsnew314-jit-compiler:

Binary releases for the experimental just-in-time compiler
----------------------------------------------------------

The official macOS and Windows release binaries now include an *experimental*
just-in-time (JIT) compiler. Although it is **not** recommended for production
use, it can be tested by setting :envvar:`PYTHON_JIT=1 <PYTHON_JIT>` as an
environment variable. Downstream source builds and redistributors can use the
:option:`--enable-experimental-jit=yes-off` configuration option for similar
behavior.

The JIT is at an early stage and still in active development. As such, the
typical performance impact of enabling it can range from 10% slower to 20%
faster, depending on workload. To aid in testing and evaluation, a set of
introspection functions has been provided in the :data:`sys._jit` namespace.
:func:`sys._jit.is_available` can be used to determine if the current executable
supports JIT compilation, while :func:`sys._jit.is_enabled` can be used to tell
if JIT compilation has been enabled for the current process.

Currently, the most significant missing functionality is that native debuggers
and profilers like ``gdb`` and ``perf`` are unable to unwind through JIT frames
(Python debuggers and profilers, like :mod:`pdb` or :mod:`profile`, continue to
work without modification). Free-threaded builds do not support JIT compilation.

Please report any bugs or major performance regressions that you encounter!

.. seealso:: :pep:`744`


Other language changes
======================

Expand Down
6 changes: 3 additions & 3 deletions Tools/jit/README.md