]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
GH-113710: Add a "globals to constants" pass (GH-114592)
authorMark Shannon <mark@hotpy.org>
Fri, 2 Feb 2024 12:14:34 +0000 (12:14 +0000)
committerGitHub <noreply@github.com>
Fri, 2 Feb 2024 12:14:34 +0000 (12:14 +0000)
commit0e71a295e9530c939a5efcb45db23cf31e0303b4
treeba3a22d5bece296073aa250a04bc3f4192607281
parent2091fb2a85c1aa2d9b22c02736b07831bd875c2a
GH-113710: Add a "globals to constants" pass (GH-114592)

Converts specializations of `LOAD_GLOBAL` into constants during tier 2 optimization.
16 files changed:
Include/cpython/dictobject.h
Include/cpython/optimizer.h
Include/internal/pycore_dict.h
Include/internal/pycore_dict_state.h
Include/internal/pycore_interp.h
Include/internal/pycore_optimizer.h
Include/internal/pycore_uop_ids.h
Include/internal/pycore_uop_metadata.h
Lib/test/test_capi/test_watchers.py
Modules/_testcapi/watchers.c
Objects/dictobject.c
Python/bytecodes.c
Python/executor_cases.c.h
Python/optimizer.c
Python/optimizer_analysis.c
Python/pylifecycle.c