Commit graph

696 commits

Author SHA1 Message Date
Stan Ulbrych
c6a142f947
Datetime: Tidy up docs (GH-144720)
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
2026-02-18 14:22:34 +01:00
Ned Batchelder
7a7521bcfa
Docs: an "improve this page" feature (#144939)
* Docs: a start on an 'improve this page' feature

* pr feedback: simplify the link, and don't scare people with the cla

* pr feedback answered

- use the actual page URL
- tighten the wording

* fix the improve link on the improve page

* news item

* Update Doc/improve-page.rst

Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>

* fix whitespace

* A nojs version of the page

* comments to help people keep the two pages in sync

* protect against XSS

* use template for issues from the nojs page

* use the template from the JS page as well

* give the docs issue template a fillable description field

* ugh, getting sloppy

* remove more sloppiness

---------

Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>
2026-02-18 04:58:30 -05:00
Stan Ulbrych
783e3fd436
Move CODEOWNERS rule from devguide (GH-144924) 2026-02-18 08:51:45 +01:00
Hugo van Kemenade
6ef2578f20
Enable CPU tests on default ARM build (#144743) 2026-02-17 12:49:31 +02:00
Pablo Galindo Salgado
23c488d619
Format CODEOWNERS file (#144842) 2026-02-15 16:11:16 +00:00
Pablo Galindo Salgado
5a6615ff92
gh-142349: Add CODEOWNERS for lazy imports (#144840) 2026-02-15 16:07:03 +00:00
Zachary Ware
fdbc135f9c
gh-144551: Update various CI jobs to OpenSSL 3.5 (GH-144808)
Also includes a fix to the address sanitizer build to build the `_ssl`
module against the expected OpenSSL build.
2026-02-13 23:02:11 +00:00
Zachary Ware
b933ef9261
gh-144551: Update CI to use latest OpenSSL versions (GH-144794)
Also update _ssl_data_36.h to include an added symbol from 3.6.1.
2026-02-13 13:06:07 -06:00
Victor Stinner
eb6ebdbc95
gh-138744: Upgrade Windows to 2025 in GitHub Actions (#144682)
Replace windows-2022 with windows-2025.
2026-02-12 16:19:50 +01:00
Roman Volosatovs
cac0c98450
gh-144675: update to WASI SDK 30 (#144676)
Signed-off-by: Roman Volosatovs <rvolosatovs@riseup.net>
Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com>
2026-02-11 16:12:08 -08:00
Savannah Ostrowski
30cfe6ee23
GH-144552: Clean up tail-call.yml CI (#144553)
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
2026-02-09 14:52:45 -08:00
Ken Jin
895e83727d
gh-144549: Fix tail calling interpreter on Windows for FT (GH-144550) 2026-02-06 19:20:28 +00:00
Ken Jin
25e99b375d
gh-132132: Upgrade to VS 2026 on Windows tailcall CI (GH-144544)
Upgrade to VS 2026 on Windows tailcall CI
2026-02-06 16:36:51 +00:00
Seth Michael Larson
5f91577cdd
gh-144376: Only run 'address' fuzzer for python3-libraries (#144398) 2026-02-02 17:55:11 +02:00
Stan Ulbrych
a447828565
gh-144242: Note that issues aren't needed for typos in docs template (GH-144288) 2026-02-02 14:56:45 +00:00
Brett Cannon
6181b69970
GH-143941: Move WASI-related files to Platforms/WASI (GH-143942)
Along the way, leave a deprecated Tools/wasm/wasi/__main__.py behind for backwards-compatibility.

Co-authored-by: Zachary Ware <zachary.ware@gmail.com>
2026-01-21 14:31:58 -08:00
Hugo van Kemenade
a126893fa8
gh-143960: Add support for OpenSSL 3.6, drop EOL 3.2 (#143961)
Co-authored-by: Gregory P. Smith <68491+gpshead@users.noreply.github.com>
2026-01-20 17:25:31 +02:00
🇺🇦 Sviatoslav Sydorenko (Святослав Сидоренко)
78b1370de9
Notify Sviat of GHA changes through codeowners (#143945)
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
2026-01-19 00:28:38 +02:00
Ken Jin
7e28ae550f
gh-142913: Export JIT functions for _testinternalcapi (#143958)
* Export JIT functions for _testinternalcapi

* Add testinternalcapi to paths to run JIT CI on
2026-01-17 13:31:38 +00:00
Seth Michael Larson
edeebe22cb
gh-143572: Run 'python3-libraries' fuzzer in CI using CIFuzz (#143749)
Co-authored-by: 🇺🇦 Sviatoslav Sydorenko (Святослав Сидоренко) <578543+webknjaz@users.noreply.github.com>
Co-authored-by: 🇺🇦 Sviatoslav Sydorenko (Святослав Сидоренко) <wk.cvs.github@sydorenko.org.ua>
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
2026-01-16 18:09:39 +02:00
Savannah Ostrowski
313d5cde5d
Add Savannah to CODEOWNERS for WASI (#143847) 2026-01-14 12:08:32 -08:00
Hugo van Kemenade
80e9eaf071
Bump GitHub Actions (#143757) 2026-01-13 15:43:26 +02:00
Stan Ulbrych
e5b5a15804
gh-141004: GHA: Run check-c-api-docs check on docs-only PRs (GH-143573)
Co-authored-by: 🇺🇦 Sviatoslav Sydorenko (Святослав Сидоренко) <wk.cvs.github@sydorenko.org.ua>
2026-01-13 10:18:48 +01:00
Savannah Ostrowski
0bee481576
Add Savannah to optimizer CODEOWNERS (#143761) 2026-01-12 14:56:05 -08:00
Pablo Galindo Salgado
fe78c1e749
gh-143253: Add libabigail suppression file for internal types (#143254)
Co-authored-by: Petr Viktorin <encukou@gmail.com>
2026-01-12 17:37:43 +02:00
Hugo van Kemenade
efb4e6c733
Allow Android to fail CI (GH-143471) 2026-01-06 12:31:21 +00:00
Johann Christensen
864c5985ea
gh-143148: Replace pre-commit with prek in CI (#143149)
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com>
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
2026-01-02 16:58:23 +02:00
Hugo van Kemenade
f783cc37eb
Update pre-commit with zizmor and Ruff fixes (#143095) 2025-12-23 17:51:02 +02:00
Chris Eibl
be3c131640
GH-139922: Tail calling for MSVC (VS 2026) (GH-143068)
Co-authored-by: Ken Jin <28750310+Fidget-Spinner@users.noreply.github.com>
Co-authored-by: Brandt Bucher <brandt@python.org>
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
2025-12-22 23:01:34 +00:00
sobolevn
248eb3efb3
gh-142859: Add Tools/check-c-api-docs to mypy check (#142860) 2025-12-17 13:23:30 +02:00
Ken Jin
b6d708ff2c
Add Fidget-Spinner to more JIT CODEOWNERS (GH-142768) 2025-12-15 21:50:42 +00:00
Hugo van Kemenade
04a9009a53
gh-140189: Revert "Temporarily allow CI failures for iOS (#142365)" (#142660) 2025-12-14 12:54:42 +02:00
Pablo Galindo Salgado
ff52e90ea4
Add pablogsal as codeowner for profiling sampling files and docs (#142678) 2025-12-13 19:10:59 +00:00
Russell Keith-Magee
91884838bc
gh-140189: Use macos-14 runner for iOS CI tests (#142444)
Switch to the macos-14 runner for iOS CI, working around some instability 
in the macos-15 runner.
2025-12-10 05:52:52 +08:00
Stan Ulbrych
9e3d7cdec1
gh-142278: Add granular change detection for platforms in CI (#142350)
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
2025-12-08 18:04:17 +00:00
Savannah Ostrowski
9d39c02498
Temporarily allow CI failures for iOS (#142365)
iOS tests are flaky right now. Based on the convo in Discord, it seems like allowing failures is the best option.

Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
2025-12-08 11:54:47 -05:00
Peter Bierma
1a7824a927
gh-141004: Add a CI job ensuring that new C APIs include documentation (GH-142102)
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
2025-12-04 03:14:25 +00:00
Bartosz Sławecki
88cd5d9850
gh-142170: Add pymanager link to issue template menu (#142199)
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
2025-12-03 11:11:40 +02:00
Stan Ulbrych
9f2a34af74
Remove references to `Misc/ACKS from CONTRIBUTING.md` (#141952)
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
2025-11-25 18:59:28 +00:00
Gregory P. Smith
2746c698e3
[security] Add a cooldown period to dependabot (GH-141866)
See https://blog.yossarian.net/2025/11/21/We-should-all-be-using-dependency-cooldowns and the description in the comment.
2025-11-23 01:34:48 -08:00
Alex Crichton
9b69a55be3
gh-141172: Update to wasi-sdk-29 (GH-141684)
This commit updates CI and configuration from wasi-sdk-25 to wasi-sdk-29
which was released recently. This notably includes stubs for pthreads
which all return errors, so some adjustment in logic is necessary to
retain knowledge that WASI cannot yet spawn threads for example.

This additionally increases the wasm stack allowance to 32MiB from 16MiB
to accomodate the `test_recursive_pickle` test in the
`test_functools.py` file. It looks like the Clang/LLVM update that
happened in wasi-sdk-29 relative to wasi-sdk-25 is likely the cause of
this where presumably functions have more locals than before and/or a
slightly adjusted stack space requirement which overflows the stack.
2025-11-19 10:03:30 -08:00
Mark Shannon
b420f6be53
GH-139109: Support switch/case dispatch with the tracing interpreter. (GH-141703) 2025-11-18 13:31:48 +00:00
Hugo van Kemenade
181a2f4f2e
gh-139596: Cease caching config.cache & ccache in GH Actions (#141451) 2025-11-14 11:59:19 +02:00
Ken Jin
4fa80ce74c
gh-139109: A new tracing JIT compiler frontend for CPython (GH-140310)
This PR changes the current JIT model from trace projection to trace recording. Benchmarking: better pyperformance (about 1.7% overall) geomean versus current https://raw.githubusercontent.com/facebookexperimental/free-threading-benchmarking/refs/heads/main/results/bm-20251108-3.15.0a1%2B-7e2bc1d-JIT/bm-20251108-vultr-x86_64-Fidget%252dSpinner-tracing_jit-3.15.0a1%2B-7e2bc1d-vs-base.svg, 100% faster Richards on the most improved benchmark versus the current JIT. Slowdown of about 10-15% on the worst benchmark versus the current JIT. **Note: the fastest version isn't the one merged, as it relies on fixing bugs in the specializing interpreter, which is left to another PR**. The speedup in the merged version is about 1.1%. https://raw.githubusercontent.com/facebookexperimental/free-threading-benchmarking/refs/heads/main/results/bm-20251112-3.15.0a1%2B-f8a764a-JIT/bm-20251112-vultr-x86_64-Fidget%252dSpinner-tracing_jit-3.15.0a1%2B-f8a764a-vs-base.svg

Stats: 50% more uops executed, 30% more traces entered the last time we ran them. It also suggests our trace lengths for a real trace recording JIT are too short, as a lot of trace too long aborts https://github.com/facebookexperimental/free-threading-benchmarking/blob/main/results/bm-20251023-3.15.0a1%2B-eb73378-CLANG%2CJIT/bm-20251023-vultr-x86_64-Fidget%252dSpinner-tracing_jit-3.15.0a1%2B-eb73378-pystats-vs-base.md .

This new JIT frontend is already able to record/execute significantly more instructions than the previous JIT frontend. In this PR, we are now able to record through custom dunders, simple object creation, generators, etc. None of these were done by the old JIT frontend. Some custom dunders uops were discovered to be broken as part of this work gh-140277

The optimizer stack space check is disabled, as it's no longer valid to deal with underflow.

Pros:
* Ignoring the generated tracer code as it's automatically created, this is only additional 1k lines of code. The maintenance burden is handled by the DSL and code generator.
* `optimizer.c` is now significantly simpler, as we don't have to do strange things to recover the bytecode from a trace.
* The new JIT frontend is able to handle a lot more control-flow than the old one.
* Tracing is very low overhead. We use the tail calling interpreter/computed goto interpreter to switch between tracing mode and non-tracing mode. I call this mechanism dual dispatch, as we have two dispatch tables dispatching to each other. Specialization is still enabled while tracing.
* Better handling of polymorphism. We leverage the specializing interpreter for this.

Cons:
* (For now) requires tail calling interpreter or computed gotos. This means no Windows JIT for now :(. Not to fret, tail calling is coming soon to Windows though https://github.com/python/cpython/pull/139962

Design:
* After each instruction, the `record_previous_inst` function/label is executed. This does as the name suggests.
* The tracing interpreter lowers bytecode to uops directly so that it can obtain "fresh" values at the point of lowering.
* The tracing version behaves nearly identical to the normal interpreter, in fact it even has specialization! This allows it to run without much of a slowdown when tracing. The actual cost of tracing is only a function call and writes to memory.
* The tracing interpreter uses the specializing interpreter's deopt to naturally form the side exit chains. This allows it to side exit chain effectively, without repeating much code. We force a re-specializing when tracing a deopt.
* The tracing interpreter can even handle goto errors/exceptions, but I chose to disable them for now as it's not tested.
* Because we do not share interpreter dispatch, there is should be no significant slowdown to the original specializing interpreter on tailcall and computed got with JIT disabled. With JIT enabled, there might be a slowdown in the form of the JIT trying to trace.
* Things that could have dynamic instruction pointer effects are guarded on. The guard deopts to a new instruction --- `_DYNAMIC_EXIT`.
2025-11-13 18:08:32 +00:00
Savannah Ostrowski
d162c42790
GH-140479: Update JIT builds to use LLVM 21 (#140973) 2025-11-12 18:09:25 +00:00
Adam Turner
c744ccb2c9
GH-139596: Cease caching config.cache & ccache in GH Actions (GH-139623)
* Cease caching config.cache in GH Actions\
* Remove ccache action
2025-11-11 13:51:22 -08:00
Ken Jin
947bb4642c
gh-140889: Bump tailcall and JIT CI to llvm 20 (#140963) 2025-11-03 12:37:29 -08:00
Hugo van Kemenade
cf1a2c1ee4
gh-133600: Run Tools/wasm/wasi on CI instead of deprecated Tools/wasm/wasi.py (#140907) 2025-11-03 21:26:09 +02:00
Ken Jin
9791a506c2
gh-140889: Test tailcall and JIT in CI (GH-140891) 2025-11-03 19:07:55 +00:00
Savannah Ostrowski
4e2ff4ac4c
GH-136895: Update JIT builds to use LLVM 20 (#140329)
Co-authored-by: Emma Harper Smith <emma@emmatyping.dev>
2025-11-03 10:01:44 -08:00