Commit graph

16 commits

Author SHA1 Message Date
Bénédikt Tran
7ce5f15981
[3.12] gh-130740: Move some stdbool.h includes after Python.h (#130738) (#130757)
gh-130740: Move some `stdbool.h` includes after `Python.h` (#130738)

Move some `#include <stdbool.h>` after `#include "Python.h"` when `pyconfig.h` is not
included first and when we are in a platform-agnostic context. This is to avoid having
features defined by `stdbool.h` before those decided by `Python.h` (this caused some
build failures when compiling CPython with `zig cc`).

(cherry-picked from commit 214562ed4d)

---------

Co-authored-by: Hugo Beauzée-Luyssen <hugo@beauzee.fr>
2025-03-04 10:38:24 +01:00
Irit Katriel
9d72a5cae7
[3.12] gh-113297: Fix segfault in compiler for with statement with 19 context managers (#113327) (#113404) 2023-12-23 13:29:11 +00:00
Dennis Sweeney
a99305e7fb
[3.12] gh-112356: LOAD_GLOBAL can only include one PUSH_NULL (#112566) 2023-12-01 00:35:49 +00:00
Miss Islington (bot)
2b96102f29
[3.12] gh-109889: fix compiler's redundant NOP detection to look past NOPs with no lineno when looking for the next instruction's lineno (GH-109987) (#110048)
gh-109889: fix compiler's redundant NOP detection to look past NOPs with no lineno when looking for the next instruction's lineno (GH-109987)
(cherry picked from commit f580edcc6a)

Co-authored-by: Irit Katriel <1055913+iritkatriel@users.noreply.github.com>
2023-10-02 17:43:16 +02:00
Irit Katriel
648198c37f
[3.12] gh-109889: comment out assertion indicating a failed optimization of a redundant NOP (#109899)
* [3.12] gh-109889: comment out assertion indicating a failed optimization of a redundant NOP

* comment out the function to avoid warnings on it being unused
2023-09-26 17:17:32 +02:00
Miss Islington (bot)
538f505a37
[3.12] gh-109823: Adjust labels in compiler when removing an empty basic block which is a jump target (GH-109839) (#109865)
gh-109823: Adjust labels in compiler when removing an empty basic block which is a jump target (GH-109839)
(cherry picked from commit d73c12b88c)

Co-authored-by: Irit Katriel <1055913+iritkatriel@users.noreply.github.com>
2023-09-26 02:37:52 +02:00
Miss Islington (bot)
633bd6e428
[3.12] gh-109719: Fix missing jump target labels when compiler reorders cold/warm blocks (GH-109734) (#109749)
gh-109719: Fix missing jump target labels when compiler reorders cold/warm blocks (GH-109734)
(cherry picked from commit 7c55399172)

Co-authored-by: Irit Katriel <1055913+iritkatriel@users.noreply.github.com>
2023-09-24 13:51:30 +02:00
Irit Katriel
107e14820a
[3.12] gh-109627: duplicated small exit blocks need to be assigned jump target labels (#109630) (#109632)
gh-109627: duplicated smalll exit blocks need to be assigned jump target labels (#109630)

(cherry picked from commit 9ccf0545ef)
2023-09-22 15:27:29 +02:00
Miss Islington (bot)
4ee9454792
[3.12] gh-107901: Fix missing line number on BACKWARD_JUMP at the end of a for loop (GH-108242) (#108275)
gh-107901: Fix missing line number on BACKWARD_JUMP at the end of a for loop (GH-108242)
(cherry picked from commit a1cc74c4ee)

Co-authored-by: Irit Katriel <1055913+iritkatriel@users.noreply.github.com>
2023-08-22 16:15:34 +02:00
Carl Meyer
0589c6a4d3
gh-104615: don't make unsafe swaps in apply_static_swaps (#104620) 2023-05-18 21:22:03 +00:00
Carl Meyer
c3b595e73e
gh-97933: (PEP 709) inline list/dict/set comprehensions (#101441)
Co-authored-by: Irit Katriel <1055913+iritkatriel@users.noreply.github.com>
Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
2023-05-09 11:02:14 -06:00
Irit Katriel
80b714835d
gh-87092: Expose assembler to unit tests (#103988) 2023-05-01 22:29:30 +01:00
Irit Katriel
fbf3596c3e
gh-87092: change assembler to use instruction sequence instead of CFG (#103933) 2023-04-29 12:06:04 +01:00
Irit Katriel
21bea68e2e
gh-91276: remove unused _PyOpcode_RelativeJump (#103156) 2023-04-11 11:20:39 +01:00
Irit Katriel
33822d037a
gh-87092: move assembler related code from compile.c to assemble.c (#103277) 2023-04-11 11:15:09 +01:00
Irit Katriel
80163e17d3
gh-87092: move CFG related code from compile.c to flowgraph.c (#103021) 2023-03-31 18:17:59 +01:00