diff options
Diffstat (limited to 'Lib')
-rw-r--r-- | Lib/importlib/_bootstrap_external.py | 2 | ||||
-rw-r--r-- | Lib/opcode.py | 2 | ||||
-rw-r--r-- | Lib/test/test_capi.py | 2 | ||||
-rw-r--r-- | Lib/test/test_sys.py | 4 |
4 files changed, 6 insertions, 4 deletions
diff --git a/Lib/importlib/_bootstrap_external.py b/Lib/importlib/_bootstrap_external.py index c69c0c7..dd1f6ff 100644 --- a/Lib/importlib/_bootstrap_external.py +++ b/Lib/importlib/_bootstrap_external.py @@ -389,7 +389,7 @@ _code_type = type(_write_atomic.__code__) # Python 3.11a5 3480 (New CALL opcodes, second iteration) # 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) +# Python 3.11a5 3483 (Use inline caching for COMPARE_OP and BINARY_SUBSCR) # Python 3.12 will start with magic number 3500 diff --git a/Lib/opcode.py b/Lib/opcode.py index dc45cff..9b08562 100644 --- a/Lib/opcode.py +++ b/Lib/opcode.py @@ -68,7 +68,7 @@ def_op('UNARY_NOT', 12) def_op('UNARY_INVERT', 15) -def_op('BINARY_SUBSCR', 25) +def_op('BINARY_SUBSCR', 25, 4) def_op('GET_LEN', 30) def_op('MATCH_MAPPING', 31) diff --git a/Lib/test/test_capi.py b/Lib/test/test_capi.py index 8832292..d961543 100644 --- a/Lib/test/test_capi.py +++ b/Lib/test/test_capi.py @@ -335,7 +335,7 @@ class CAPITest(unittest.TestCase): *_, count = line.split(b' ') count = int(count) self.assertLessEqual(count, i*5) - self.assertGreaterEqual(count, i*5-1) + self.assertGreaterEqual(count, i*5-2) def test_mapping_keys_values_items(self): class Mapping1(dict): diff --git a/Lib/test/test_sys.py b/Lib/test/test_sys.py index f828d1b..70768f5 100644 --- a/Lib/test/test_sys.py +++ b/Lib/test/test_sys.py @@ -1501,7 +1501,9 @@ class SizeofTest(unittest.TestCase): '3P' # PyMappingMethods '10P' # PySequenceMethods '2P' # PyBufferProcs - '6P') + '6P' + '1P' # Specializer cache + ) class newstyleclass(object): pass # Separate block for PyDictKeysObject with 8 keys and 5 entries check(newstyleclass, s + calcsize(DICT_KEY_STRUCT_FORMAT) + 64 + 42*calcsize("n2P")) |