diff options
author | Irit Katriel <1055913+iritkatriel@users.noreply.github.com> | 2023-09-12 10:36:17 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-09-12 10:36:17 (GMT) |
commit | 8b55adfa8ff05477b4be7def36db7b66c73f181d (patch) | |
tree | 33552a28b4465bbf0bc6d562063320fbf0fbae8d /Lib/_opcode_metadata.py | |
parent | 247ee1bf841524667f883ebba5e343101f609026 (diff) | |
download | cpython-8b55adfa8ff05477b4be7def36db7b66c73f181d.zip cpython-8b55adfa8ff05477b4be7def36db7b66c73f181d.tar.gz cpython-8b55adfa8ff05477b4be7def36db7b66c73f181d.tar.bz2 |
gh-109256: allocate opcode IDs for internal opcodes in their own range (#109269)
Diffstat (limited to 'Lib/_opcode_metadata.py')
-rw-r--r-- | Lib/_opcode_metadata.py | 372 |
1 files changed, 186 insertions, 186 deletions
diff --git a/Lib/_opcode_metadata.py b/Lib/_opcode_metadata.py index 20975ff..4f76371 100644 --- a/Lib/_opcode_metadata.py +++ b/Lib/_opcode_metadata.py @@ -107,198 +107,198 @@ _specializations = { _specializations["BINARY_OP"].append("BINARY_OP_INPLACE_ADD_UNICODE") _specialized_opmap = { - 'BINARY_OP_ADD_FLOAT': 3, - 'BINARY_OP_ADD_INT': 4, - 'BINARY_OP_ADD_UNICODE': 5, - 'BINARY_OP_INPLACE_ADD_UNICODE': 6, - 'BINARY_OP_MULTIPLY_FLOAT': 7, - 'BINARY_OP_MULTIPLY_INT': 8, - 'BINARY_OP_SUBTRACT_FLOAT': 9, - 'BINARY_OP_SUBTRACT_INT': 10, - 'BINARY_SUBSCR_DICT': 13, - 'BINARY_SUBSCR_GETITEM': 14, - 'BINARY_SUBSCR_LIST_INT': 15, - 'BINARY_SUBSCR_STR_INT': 16, - 'BINARY_SUBSCR_TUPLE_INT': 18, - 'RESUME_CHECK': 47, - 'STORE_ATTR_INSTANCE_VALUE': 51, - 'STORE_ATTR_SLOT': 52, - 'STORE_SUBSCR_DICT': 55, - 'STORE_SUBSCR_LIST_INT': 56, - 'TO_BOOL_ALWAYS_TRUE': 58, - 'TO_BOOL_BOOL': 59, - 'TO_BOOL_INT': 60, - 'TO_BOOL_LIST': 61, - 'TO_BOOL_NONE': 62, - 'TO_BOOL_STR': 63, - 'CALL_BOUND_METHOD_EXACT_ARGS': 77, - 'CALL_BUILTIN_CLASS': 78, - 'CALL_BUILTIN_FAST_WITH_KEYWORDS': 79, - 'CALL_METHOD_DESCRIPTOR_FAST_WITH_KEYWORDS': 83, - 'CALL_NO_KW_ALLOC_AND_ENTER_INIT': 84, - 'CALL_NO_KW_BUILTIN_FAST': 85, - 'CALL_NO_KW_BUILTIN_O': 86, - 'CALL_NO_KW_ISINSTANCE': 87, - 'CALL_NO_KW_LEN': 88, - 'CALL_NO_KW_LIST_APPEND': 89, - 'CALL_NO_KW_METHOD_DESCRIPTOR_FAST': 90, - 'CALL_NO_KW_METHOD_DESCRIPTOR_NOARGS': 91, - 'CALL_NO_KW_METHOD_DESCRIPTOR_O': 92, - 'CALL_NO_KW_STR_1': 93, - 'CALL_NO_KW_TUPLE_1': 94, - 'CALL_NO_KW_TYPE_1': 95, - 'CALL_PY_EXACT_ARGS': 96, - 'CALL_PY_WITH_DEFAULTS': 97, - 'COMPARE_OP_FLOAT': 99, - 'COMPARE_OP_INT': 100, - 'COMPARE_OP_STR': 101, - 'FOR_ITER_GEN': 116, - 'FOR_ITER_LIST': 117, - 'FOR_ITER_RANGE': 118, - 'FOR_ITER_TUPLE': 119, - 'LOAD_ATTR_CLASS': 131, - 'LOAD_ATTR_GETATTRIBUTE_OVERRIDDEN': 132, - 'LOAD_ATTR_INSTANCE_VALUE': 133, - 'LOAD_ATTR_METHOD_LAZY_DICT': 134, - 'LOAD_ATTR_METHOD_NO_DICT': 135, - 'LOAD_ATTR_METHOD_WITH_VALUES': 136, - 'LOAD_ATTR_MODULE': 137, - 'LOAD_ATTR_NONDESCRIPTOR_NO_DICT': 138, - 'LOAD_ATTR_NONDESCRIPTOR_WITH_VALUES': 139, - 'LOAD_ATTR_PROPERTY': 140, - 'LOAD_ATTR_SLOT': 141, - 'LOAD_ATTR_WITH_HINT': 142, - 'LOAD_GLOBAL_BUILTIN': 152, - 'LOAD_GLOBAL_MODULE': 153, - 'LOAD_SUPER_ATTR_ATTR': 156, - 'LOAD_SUPER_ATTR_METHOD': 157, - 'SEND_GEN': 170, - 'STORE_ATTR_WITH_HINT': 175, - 'UNPACK_SEQUENCE_LIST': 185, - 'UNPACK_SEQUENCE_TUPLE': 186, - 'UNPACK_SEQUENCE_TWO_TUPLE': 187, + 'BINARY_OP_INPLACE_ADD_UNICODE': 3, + 'BINARY_OP_ADD_FLOAT': 150, + 'BINARY_OP_ADD_INT': 151, + 'BINARY_OP_ADD_UNICODE': 152, + 'BINARY_OP_MULTIPLY_FLOAT': 153, + 'BINARY_OP_MULTIPLY_INT': 154, + 'BINARY_OP_SUBTRACT_FLOAT': 155, + 'BINARY_OP_SUBTRACT_INT': 156, + 'BINARY_SUBSCR_DICT': 157, + 'BINARY_SUBSCR_GETITEM': 158, + 'BINARY_SUBSCR_LIST_INT': 159, + 'BINARY_SUBSCR_STR_INT': 160, + 'BINARY_SUBSCR_TUPLE_INT': 161, + 'CALL_BOUND_METHOD_EXACT_ARGS': 162, + 'CALL_BUILTIN_CLASS': 163, + 'CALL_BUILTIN_FAST_WITH_KEYWORDS': 164, + 'CALL_METHOD_DESCRIPTOR_FAST_WITH_KEYWORDS': 165, + 'CALL_NO_KW_ALLOC_AND_ENTER_INIT': 166, + 'CALL_NO_KW_BUILTIN_FAST': 167, + 'CALL_NO_KW_BUILTIN_O': 168, + 'CALL_NO_KW_ISINSTANCE': 169, + 'CALL_NO_KW_LEN': 170, + 'CALL_NO_KW_LIST_APPEND': 171, + 'CALL_NO_KW_METHOD_DESCRIPTOR_FAST': 172, + 'CALL_NO_KW_METHOD_DESCRIPTOR_NOARGS': 173, + 'CALL_NO_KW_METHOD_DESCRIPTOR_O': 174, + 'CALL_NO_KW_STR_1': 175, + 'CALL_NO_KW_TUPLE_1': 176, + 'CALL_NO_KW_TYPE_1': 177, + 'CALL_PY_EXACT_ARGS': 178, + 'CALL_PY_WITH_DEFAULTS': 179, + 'COMPARE_OP_FLOAT': 180, + 'COMPARE_OP_INT': 181, + 'COMPARE_OP_STR': 182, + 'FOR_ITER_GEN': 183, + 'FOR_ITER_LIST': 184, + 'FOR_ITER_RANGE': 185, + 'FOR_ITER_TUPLE': 186, + 'LOAD_ATTR_CLASS': 187, + 'LOAD_ATTR_GETATTRIBUTE_OVERRIDDEN': 188, + 'LOAD_ATTR_INSTANCE_VALUE': 189, + 'LOAD_ATTR_METHOD_LAZY_DICT': 190, + 'LOAD_ATTR_METHOD_NO_DICT': 191, + 'LOAD_ATTR_METHOD_WITH_VALUES': 192, + 'LOAD_ATTR_MODULE': 193, + 'LOAD_ATTR_NONDESCRIPTOR_NO_DICT': 194, + 'LOAD_ATTR_NONDESCRIPTOR_WITH_VALUES': 195, + 'LOAD_ATTR_PROPERTY': 196, + 'LOAD_ATTR_SLOT': 197, + 'LOAD_ATTR_WITH_HINT': 198, + 'LOAD_GLOBAL_BUILTIN': 199, + 'LOAD_GLOBAL_MODULE': 200, + 'LOAD_SUPER_ATTR_ATTR': 201, + 'LOAD_SUPER_ATTR_METHOD': 202, + 'RESUME_CHECK': 203, + 'SEND_GEN': 204, + 'STORE_ATTR_INSTANCE_VALUE': 205, + 'STORE_ATTR_SLOT': 206, + 'STORE_ATTR_WITH_HINT': 207, + 'STORE_SUBSCR_DICT': 208, + 'STORE_SUBSCR_LIST_INT': 209, + 'TO_BOOL_ALWAYS_TRUE': 210, + 'TO_BOOL_BOOL': 211, + 'TO_BOOL_INT': 212, + 'TO_BOOL_LIST': 213, + 'TO_BOOL_NONE': 214, + 'TO_BOOL_STR': 215, + 'UNPACK_SEQUENCE_LIST': 216, + 'UNPACK_SEQUENCE_TUPLE': 217, + 'UNPACK_SEQUENCE_TWO_TUPLE': 218, } opmap = { 'CACHE': 0, 'BEFORE_ASYNC_WITH': 1, 'BEFORE_WITH': 2, - 'BINARY_SLICE': 11, - 'BINARY_SUBSCR': 12, + 'BINARY_SLICE': 4, + 'BINARY_SUBSCR': 5, + 'CHECK_EG_MATCH': 6, + 'CHECK_EXC_MATCH': 7, + 'CLEANUP_THROW': 8, + 'DELETE_SUBSCR': 9, + 'END_ASYNC_FOR': 10, + 'END_FOR': 11, + 'END_SEND': 12, + 'EXIT_INIT_CHECK': 13, + 'FORMAT_SIMPLE': 14, + 'FORMAT_WITH_SPEC': 15, + 'GET_AITER': 16, 'RESERVED': 17, - 'CHECK_EG_MATCH': 19, - 'CHECK_EXC_MATCH': 20, - 'CLEANUP_THROW': 21, - 'DELETE_SUBSCR': 22, - 'END_ASYNC_FOR': 23, - 'END_FOR': 24, - 'END_SEND': 25, - 'EXIT_INIT_CHECK': 26, - 'FORMAT_SIMPLE': 27, - 'FORMAT_WITH_SPEC': 28, - 'GET_AITER': 29, - 'GET_ANEXT': 30, - 'GET_ITER': 31, - 'GET_LEN': 32, - 'GET_YIELD_FROM_ITER': 33, - 'INTERPRETER_EXIT': 34, - 'LOAD_ASSERTION_ERROR': 35, - 'LOAD_BUILD_CLASS': 36, - 'LOAD_LOCALS': 37, - 'MAKE_FUNCTION': 38, - 'MATCH_KEYS': 39, - 'MATCH_MAPPING': 40, - 'MATCH_SEQUENCE': 41, - 'NOP': 42, - 'POP_EXCEPT': 43, - 'POP_TOP': 44, - 'PUSH_EXC_INFO': 45, - 'PUSH_NULL': 46, - 'RETURN_GENERATOR': 48, - 'RETURN_VALUE': 49, - 'SETUP_ANNOTATIONS': 50, - 'STORE_SLICE': 53, - 'STORE_SUBSCR': 54, - 'TO_BOOL': 57, - 'UNARY_INVERT': 64, - 'UNARY_NEGATIVE': 65, - 'UNARY_NOT': 66, - 'WITH_EXCEPT_START': 67, - 'BINARY_OP': 68, - 'BUILD_CONST_KEY_MAP': 69, - 'BUILD_LIST': 70, - 'BUILD_MAP': 71, - 'BUILD_SET': 72, - 'BUILD_SLICE': 73, - 'BUILD_STRING': 74, - 'BUILD_TUPLE': 75, - 'CALL': 76, - 'CALL_FUNCTION_EX': 80, - 'CALL_INTRINSIC_1': 81, - 'CALL_INTRINSIC_2': 82, - 'COMPARE_OP': 98, - 'CONTAINS_OP': 102, - 'CONVERT_VALUE': 103, - 'COPY': 104, - 'COPY_FREE_VARS': 105, - 'DELETE_ATTR': 106, - 'DELETE_DEREF': 107, - 'DELETE_FAST': 108, - 'DELETE_GLOBAL': 109, - 'DELETE_NAME': 110, - 'DICT_MERGE': 111, - 'DICT_UPDATE': 112, - 'ENTER_EXECUTOR': 113, - 'EXTENDED_ARG': 114, - 'FOR_ITER': 115, - 'GET_AWAITABLE': 120, - 'IMPORT_FROM': 121, - 'IMPORT_NAME': 122, - 'IS_OP': 123, - 'JUMP_BACKWARD': 124, - 'JUMP_BACKWARD_NO_INTERRUPT': 125, - 'JUMP_FORWARD': 126, - 'KW_NAMES': 127, - 'LIST_APPEND': 128, - 'LIST_EXTEND': 129, - 'LOAD_ATTR': 130, - 'LOAD_CONST': 143, - 'LOAD_DEREF': 144, - 'LOAD_FAST': 145, - 'LOAD_FAST_AND_CLEAR': 146, - 'LOAD_FAST_CHECK': 147, - 'LOAD_FAST_LOAD_FAST': 148, - 'LOAD_FROM_DICT_OR_DEREF': 149, - 'LOAD_FROM_DICT_OR_GLOBALS': 150, - 'LOAD_GLOBAL': 151, - 'LOAD_NAME': 154, - 'LOAD_SUPER_ATTR': 155, - 'MAKE_CELL': 158, - 'MAP_ADD': 159, - 'MATCH_CLASS': 160, - 'POP_JUMP_IF_FALSE': 161, - 'POP_JUMP_IF_NONE': 162, - 'POP_JUMP_IF_NOT_NONE': 163, - 'POP_JUMP_IF_TRUE': 164, - 'RAISE_VARARGS': 165, - 'RESUME': 166, - 'RERAISE': 167, - 'RETURN_CONST': 168, - 'SEND': 169, - 'SET_ADD': 171, - 'SET_FUNCTION_ATTRIBUTE': 172, - 'SET_UPDATE': 173, - 'STORE_ATTR': 174, - 'STORE_DEREF': 176, - 'STORE_FAST': 177, - 'STORE_FAST_LOAD_FAST': 178, - 'STORE_FAST_STORE_FAST': 179, - 'STORE_GLOBAL': 180, - 'STORE_NAME': 181, - 'SWAP': 182, - 'UNPACK_EX': 183, - 'UNPACK_SEQUENCE': 184, - 'YIELD_VALUE': 188, + 'GET_ANEXT': 18, + 'GET_ITER': 19, + 'GET_LEN': 20, + 'GET_YIELD_FROM_ITER': 21, + 'INTERPRETER_EXIT': 22, + 'LOAD_ASSERTION_ERROR': 23, + 'LOAD_BUILD_CLASS': 24, + 'LOAD_LOCALS': 25, + 'MAKE_FUNCTION': 26, + 'MATCH_KEYS': 27, + 'MATCH_MAPPING': 28, + 'MATCH_SEQUENCE': 29, + 'NOP': 30, + 'POP_EXCEPT': 31, + 'POP_TOP': 32, + 'PUSH_EXC_INFO': 33, + 'PUSH_NULL': 34, + 'RETURN_GENERATOR': 35, + 'RETURN_VALUE': 36, + 'SETUP_ANNOTATIONS': 37, + 'STORE_SLICE': 38, + 'STORE_SUBSCR': 39, + 'TO_BOOL': 40, + 'UNARY_INVERT': 41, + 'UNARY_NEGATIVE': 42, + 'UNARY_NOT': 43, + 'WITH_EXCEPT_START': 44, + 'BINARY_OP': 45, + 'BUILD_CONST_KEY_MAP': 46, + 'BUILD_LIST': 47, + 'BUILD_MAP': 48, + 'BUILD_SET': 49, + 'BUILD_SLICE': 50, + 'BUILD_STRING': 51, + 'BUILD_TUPLE': 52, + 'CALL': 53, + 'CALL_FUNCTION_EX': 54, + 'CALL_INTRINSIC_1': 55, + 'CALL_INTRINSIC_2': 56, + 'COMPARE_OP': 57, + 'CONTAINS_OP': 58, + 'CONVERT_VALUE': 59, + 'COPY': 60, + 'COPY_FREE_VARS': 61, + 'DELETE_ATTR': 62, + 'DELETE_DEREF': 63, + 'DELETE_FAST': 64, + 'DELETE_GLOBAL': 65, + 'DELETE_NAME': 66, + 'DICT_MERGE': 67, + 'DICT_UPDATE': 68, + 'ENTER_EXECUTOR': 69, + 'EXTENDED_ARG': 70, + 'FOR_ITER': 71, + 'GET_AWAITABLE': 72, + 'IMPORT_FROM': 73, + 'IMPORT_NAME': 74, + 'IS_OP': 75, + 'JUMP_BACKWARD': 76, + 'JUMP_BACKWARD_NO_INTERRUPT': 77, + 'JUMP_FORWARD': 78, + 'KW_NAMES': 79, + 'LIST_APPEND': 80, + 'LIST_EXTEND': 81, + 'LOAD_ATTR': 82, + 'LOAD_CONST': 83, + 'LOAD_DEREF': 84, + 'LOAD_FAST': 85, + 'LOAD_FAST_AND_CLEAR': 86, + 'LOAD_FAST_CHECK': 87, + 'LOAD_FAST_LOAD_FAST': 88, + 'LOAD_FROM_DICT_OR_DEREF': 89, + 'LOAD_FROM_DICT_OR_GLOBALS': 90, + 'LOAD_GLOBAL': 91, + 'LOAD_NAME': 92, + 'LOAD_SUPER_ATTR': 93, + 'MAKE_CELL': 94, + 'MAP_ADD': 95, + 'MATCH_CLASS': 96, + 'POP_JUMP_IF_FALSE': 97, + 'POP_JUMP_IF_NONE': 98, + 'POP_JUMP_IF_NOT_NONE': 99, + 'POP_JUMP_IF_TRUE': 100, + 'RAISE_VARARGS': 101, + 'RERAISE': 102, + 'RETURN_CONST': 103, + 'SEND': 104, + 'SET_ADD': 105, + 'SET_FUNCTION_ATTRIBUTE': 106, + 'SET_UPDATE': 107, + 'STORE_ATTR': 108, + 'STORE_DEREF': 109, + 'STORE_FAST': 110, + 'STORE_FAST_LOAD_FAST': 111, + 'STORE_FAST_STORE_FAST': 112, + 'STORE_GLOBAL': 113, + 'STORE_NAME': 114, + 'SWAP': 115, + 'UNPACK_EX': 116, + 'UNPACK_SEQUENCE': 117, + 'YIELD_VALUE': 118, + 'RESUME': 149, 'INSTRUMENTED_RESUME': 237, 'INSTRUMENTED_END_FOR': 238, 'INSTRUMENTED_END_SEND': 239, @@ -331,4 +331,4 @@ opmap = { 'STORE_FAST_MAYBE_NULL': 267, } MIN_INSTRUMENTED_OPCODE = 237 -HAVE_ARGUMENT = 68 +HAVE_ARGUMENT = 45 |