mirror of
https://github.com/python/cpython.git
synced 2025-08-04 00:48:58 +00:00
GH-90997: Shrink the LOAD_GLOBAL caches (#102569)
This commit is contained in:
parent
767d3a8f6f
commit
08b67fb34f
11 changed files with 187 additions and 172 deletions
|
@ -431,12 +431,17 @@ _code_type = type(_write_atomic.__code__)
|
|||
# Python 3.12a5 3515 (Embed jump mask in COMPARE_OP oparg)
|
||||
# Python 3.12a5 3516 (Add COMPARE_AND_BRANCH instruction)
|
||||
# Python 3.12a5 3517 (Change YIELD_VALUE oparg to exception block depth)
|
||||
# Python 3.12a5 3518 (Add RETURN_CONST instruction)
|
||||
# Python 3.12a5 3519 (Modify SEND instruction)
|
||||
# Python 3.12a5 3520 (Remove PREP_RERAISE_STAR, add CALL_INTRINSIC_2)
|
||||
# Python 3.12a6 3518 (Add RETURN_CONST instruction)
|
||||
# Python 3.12a6 3519 (Modify SEND instruction)
|
||||
# Python 3.12a6 3520 (Remove PREP_RERAISE_STAR, add CALL_INTRINSIC_2)
|
||||
# Python 3.12a7 3521 (Shrink the LOAD_GLOBAL caches)
|
||||
|
||||
# Python 3.13 will start with 3550
|
||||
|
||||
# Please don't copy-paste the same pre-release tag for new entries above!!!
|
||||
# You should always use the *upcoming* tag. For example, if 3.12a6 came out
|
||||
# a week ago, I should put "Python 3.12a7" next to my new magic number.
|
||||
|
||||
# MAGIC must change whenever the bytecode emitted by the compiler may no
|
||||
# longer be understood by older implementations of the eval loop (usually
|
||||
# due to the addition of new opcodes).
|
||||
|
@ -446,7 +451,7 @@ _code_type = type(_write_atomic.__code__)
|
|||
# Whenever MAGIC_NUMBER is changed, the ranges in the magic_values array
|
||||
# in PC/launcher.c must also be updated.
|
||||
|
||||
MAGIC_NUMBER = (3520).to_bytes(2, 'little') + b'\r\n'
|
||||
MAGIC_NUMBER = (3521).to_bytes(2, 'little') + b'\r\n'
|
||||
|
||||
_RAW_MAGIC_NUMBER = int.from_bytes(MAGIC_NUMBER, 'little') # For import.c
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue