-
-
Notifications
You must be signed in to change notification settings - Fork 32k
Configure Tier 2 interpreter at build time #118335
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
That should be easy enough to deal with, but I'll hold off on shipping that change until #118339 is merged. |
Understood, but then how can I run a benchmark that tells me how Tier 2 fares with my changes before merging it? (Possibly we won't care. We should discuss this in today's meeting.) |
Oh, good point. If I'm reading correctly, we could probably do both the |
Off-line we decided on a different configure experience. The
(enum names subject to bikeshedding) which selects whether the JIT or the Tier 2 interpreter is built, and whether it's on or off by default. An environment variable, |
Meanwhile, Brandt and I solved the Windows failure, which was due to |
The code for Tier 2 is now only compiled when configured with `--enable-experimental-jit[=yes|interpreter]`. We drop support for `PYTHON_UOPS` and -`Xuops`, but you can disable the interpreter or JIT at runtime by setting `PYTHON_JIT=0`. You can also build it without enabling it by default using `--enable-experimental-jit=yes-off`; enable with `PYTHON_JIT=1`. On Windows, the `build.bat` script supports `--experimental-jit`, `--experimental-jit-off`, `--experimental-interpreter`. In the C code, `_Py_JIT` is defined as before when the JIT is enabled; the new variable `_Py_TIER2` is defined when the JIT *or* the interpreter is enabled. It is actually a bitmask: 1: JIT; 2: default-off; 4: interpreter.
…ntal-jit-interpreter (#118497) Also fix docs for this in whatsnew.
…18339) The code for Tier 2 is now only compiled when configured with `--enable-experimental-jit[=yes|interpreter]`. We drop support for `PYTHON_UOPS` and -`Xuops`, but you can disable the interpreter or JIT at runtime by setting `PYTHON_JIT=0`. You can also build it without enabling it by default using `--enable-experimental-jit=yes-off`; enable with `PYTHON_JIT=1`. On Windows, the `build.bat` script supports `--experimental-jit`, `--experimental-jit-off`, `--experimental-interpreter`. In the C code, `_Py_JIT` is defined as before when the JIT is enabled; the new variable `_Py_TIER2` is defined when the JIT *or* the interpreter is enabled. It is actually a bitmask: 1: JIT; 2: default-off; 4: interpreter.
…abled (python#118493) Also patch up news blurb for pythongh-118339 (add warning that PYTHON_UOPS is now PYTHON_JIT).
…perimental-jit-interpreter (python#118497) Also fix docs for this in whatsnew.
It would be nice if by default we didn't ship the optimizer infrastructure, since approximately nobody is going to use it, so we should ship (and by default build) binaries that just don't include it.
I propose to enable it only when configured with
--enable-experimental-jit-interpreter
. We drop support forPYTHON_UOPS
and-Xuops
, in favor ofPYTHON_JIT=0|1
.@mdboom this will have some consequences for the benchmarking infra; checking the
Tier 2
box should use this configure option rather than setting thePYTHON_UOPS=1
env var. It should be possible to use both (./configure
gives a warning but otherwise seems to ignore incorrect flags, and the env var will just be ignored).Linked PRs
The text was updated successfully, but these errors were encountered: