diff options
author | Brandt Bucher <brandtbucher@microsoft.com> | 2022-03-03 23:31:00 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-03-03 23:31:00 (GMT) |
commit | 05a8bc1c944709e7468f157bd1b6032f368e43bf (patch) | |
tree | 8bd069cf131d3d1f32bd388bba71eb856bdf3616 /Lib/importlib | |
parent | 65b92ccdec2ee4a99e54aaf7ae2d9bbc2ebfe549 (diff) | |
download | cpython-05a8bc1c944709e7468f157bd1b6032f368e43bf.zip cpython-05a8bc1c944709e7468f157bd1b6032f368e43bf.tar.gz cpython-05a8bc1c944709e7468f157bd1b6032f368e43bf.tar.bz2 |
bpo-46841: Use inline caching for attribute accesses (GH-31640)
Diffstat (limited to 'Lib/importlib')
-rw-r--r-- | Lib/importlib/_bootstrap_external.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/Lib/importlib/_bootstrap_external.py b/Lib/importlib/_bootstrap_external.py index dd1f6ff..9d36bc2 100644 --- a/Lib/importlib/_bootstrap_external.py +++ b/Lib/importlib/_bootstrap_external.py @@ -390,6 +390,8 @@ _code_type = type(_write_atomic.__code__) # Python 3.11a5 3481 (Use inline cache for BINARY_OP) # Python 3.11a5 3482 (Use inline caching for UNPACK_SEQUENCE and LOAD_GLOBAL) # Python 3.11a5 3483 (Use inline caching for COMPARE_OP and BINARY_SUBSCR) +# Python 3.11a5 3484 (Use inline caching for LOAD_ATTR, LOAD_METHOD, and +# STORE_ATTR) # Python 3.12 will start with magic number 3500 @@ -404,7 +406,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 = (3483).to_bytes(2, 'little') + b'\r\n' +MAGIC_NUMBER = (3484).to_bytes(2, 'little') + b'\r\n' _RAW_MAGIC_NUMBER = int.from_bytes(MAGIC_NUMBER, 'little') # For import.c _PYCACHE = '__pycache__' |