[Python-checkins] gh-101799: implement PREP_RERAISE_STAR as an intrinsic function (#101800)

iritkatriel webhook-mailer at python.org
Tue Feb 14 06:54:51 EST 2023


https://github.com/python/cpython/commit/81e3aa835c32363f4547b6566edf1125386f1f6d
commit: 81e3aa835c32363f4547b6566edf1125386f1f6d
branch: main
author: Irit Katriel <1055913+iritkatriel at users.noreply.github.com>
committer: iritkatriel <1055913+iritkatriel at users.noreply.github.com>
date: 2023-02-14T11:54:13Z
summary:

gh-101799: implement PREP_RERAISE_STAR as an intrinsic function (#101800)

files:
A Misc/NEWS.d/next/Core and Builtins/2023-02-13-18-21-14.gh-issue-101799.wpHbCn.rst
M Doc/library/dis.rst
M Include/internal/pycore_intrinsics.h
M Include/internal/pycore_opcode.h
M Include/opcode.h
M Lib/importlib/_bootstrap_external.py
M Lib/opcode.py
M Python/bytecodes.c
M Python/compile.c
M Python/generated_cases.c.h
M Python/intrinsics.c
M Python/opcode_metadata.h
M Python/opcode_targets.h

diff --git a/Doc/library/dis.rst b/Doc/library/dis.rst
index b1e61d7e77b2..a5bc5e7fb6ea 100644
--- a/Doc/library/dis.rst
+++ b/Doc/library/dis.rst
@@ -768,16 +768,6 @@ iterations of the loop.
 
    .. versionadded:: 3.11
 
-.. opcode:: PREP_RERAISE_STAR
-
-   Combines the raised and reraised exceptions list from ``STACK[-1]``, into an
-   exception group to propagate from a try-except* block. Uses the original exception
-   group from ``STACK[-2]`` to reconstruct the structure of reraised exceptions. Pops
-   two items from the stack and pushes the exception to reraise or ``None``
-   if there isn't one.
-
-   .. versionadded:: 3.11
-
 .. opcode:: WITH_EXCEPT_START
 
     Calls the function in position 4 on the stack with arguments (type, val, tb)
@@ -1515,7 +1505,8 @@ iterations of the loop.
 .. opcode:: CALL_INTRINSIC_1
 
    Calls an intrinsic function with one argument. Passes ``STACK[-1]`` as the
-   argument and sets ``STACK[-1]`` to the result. Used to implement functionality that is necessary but not performance critical.
+   argument and sets ``STACK[-1]`` to the result. Used to implement
+   functionality that is necessary but not performance critical.
 
     The operand determines which intrinsic function is called:
 
@@ -1529,6 +1520,19 @@ iterations of the loop.
 
    .. versionadded:: 3.12
 
+.. opcode:: CALL_INTRINSIC_2
+
+   Calls an intrinsic function with two arguments. Passes ``STACK[-2]``, ``STACK[-1]`` as the
+   arguments and sets ``STACK[-1]`` to the result. Used to implement functionality that is
+   necessary but not performance critical.
+
+    The operand determines which intrinsic function is called:
+
+    * ``0`` Not valid
+    * ``1`` Calculates the :exc:`ExceptionGroup` to raise from a ``try-except*``.
+
+   .. versionadded:: 3.12
+
 
 **Pseudo-instructions**
 
diff --git a/Include/internal/pycore_intrinsics.h b/Include/internal/pycore_intrinsics.h
index 1da618f2b4a5..deac145fff76 100644
--- a/Include/internal/pycore_intrinsics.h
+++ b/Include/internal/pycore_intrinsics.h
@@ -1,4 +1,6 @@
 
+/* Unary Functions: */
+
 #define INTRINSIC_PRINT 1
 #define INTRINSIC_IMPORT_STAR 2
 #define INTRINSIC_STOPITERATION_ERROR 3
@@ -8,6 +10,17 @@
 
 #define MAX_INTRINSIC_1 6
 
+
+/* Binary Functions: */
+
+#define INTRINSIC_PREP_RERAISE_STAR 1
+
+#define MAX_INTRINSIC_2 1
+
+
 typedef PyObject *(*instrinsic_func1)(PyThreadState* tstate, PyObject *value);
+typedef PyObject *(*instrinsic_func2)(PyThreadState* tstate, PyObject *value1, PyObject *value2);
 
 extern instrinsic_func1 _PyIntrinsics_UnaryFunctions[];
+extern instrinsic_func2 _PyIntrinsics_BinaryFunctions[];
+
diff --git a/Include/internal/pycore_opcode.h b/Include/internal/pycore_opcode.h
index 5e65adee9e00..f9ab95ca4bb9 100644
--- a/Include/internal/pycore_opcode.h
+++ b/Include/internal/pycore_opcode.h
@@ -87,6 +87,7 @@ const uint8_t _PyOpcode_Deopt[256] = {
     [CALL_BUILTIN_FAST_WITH_KEYWORDS] = CALL,
     [CALL_FUNCTION_EX] = CALL_FUNCTION_EX,
     [CALL_INTRINSIC_1] = CALL_INTRINSIC_1,
+    [CALL_INTRINSIC_2] = CALL_INTRINSIC_2,
     [CALL_METHOD_DESCRIPTOR_FAST_WITH_KEYWORDS] = CALL,
     [CALL_NO_KW_BUILTIN_FAST] = CALL,
     [CALL_NO_KW_BUILTIN_O] = CALL,
@@ -187,7 +188,6 @@ const uint8_t _PyOpcode_Deopt[256] = {
     [POP_JUMP_IF_NOT_NONE] = POP_JUMP_IF_NOT_NONE,
     [POP_JUMP_IF_TRUE] = POP_JUMP_IF_TRUE,
     [POP_TOP] = POP_TOP,
-    [PREP_RERAISE_STAR] = PREP_RERAISE_STAR,
     [PUSH_EXC_INFO] = PUSH_EXC_INFO,
     [PUSH_NULL] = PUSH_NULL,
     [RAISE_VARARGS] = RAISE_VARARGS,
@@ -319,7 +319,7 @@ static const char *const _PyOpcode_OpName[263] = {
     [SETUP_ANNOTATIONS] = "SETUP_ANNOTATIONS",
     [STORE_ATTR_INSTANCE_VALUE] = "STORE_ATTR_INSTANCE_VALUE",
     [STORE_ATTR_SLOT] = "STORE_ATTR_SLOT",
-    [PREP_RERAISE_STAR] = "PREP_RERAISE_STAR",
+    [STORE_ATTR_WITH_HINT] = "STORE_ATTR_WITH_HINT",
     [POP_EXCEPT] = "POP_EXCEPT",
     [STORE_NAME] = "STORE_NAME",
     [DELETE_NAME] = "DELETE_NAME",
@@ -344,7 +344,7 @@ static const char *const _PyOpcode_OpName[263] = {
     [JUMP_FORWARD] = "JUMP_FORWARD",
     [JUMP_IF_FALSE_OR_POP] = "JUMP_IF_FALSE_OR_POP",
     [JUMP_IF_TRUE_OR_POP] = "JUMP_IF_TRUE_OR_POP",
-    [STORE_ATTR_WITH_HINT] = "STORE_ATTR_WITH_HINT",
+    [STORE_FAST__LOAD_FAST] = "STORE_FAST__LOAD_FAST",
     [POP_JUMP_IF_FALSE] = "POP_JUMP_IF_FALSE",
     [POP_JUMP_IF_TRUE] = "POP_JUMP_IF_TRUE",
     [LOAD_GLOBAL] = "LOAD_GLOBAL",
@@ -374,7 +374,7 @@ static const char *const _PyOpcode_OpName[263] = {
     [JUMP_BACKWARD] = "JUMP_BACKWARD",
     [COMPARE_AND_BRANCH] = "COMPARE_AND_BRANCH",
     [CALL_FUNCTION_EX] = "CALL_FUNCTION_EX",
-    [STORE_FAST__LOAD_FAST] = "STORE_FAST__LOAD_FAST",
+    [STORE_FAST__STORE_FAST] = "STORE_FAST__STORE_FAST",
     [EXTENDED_ARG] = "EXTENDED_ARG",
     [LIST_APPEND] = "LIST_APPEND",
     [SET_ADD] = "SET_ADD",
@@ -384,20 +384,20 @@ static const char *const _PyOpcode_OpName[263] = {
     [YIELD_VALUE] = "YIELD_VALUE",
     [RESUME] = "RESUME",
     [MATCH_CLASS] = "MATCH_CLASS",
-    [STORE_FAST__STORE_FAST] = "STORE_FAST__STORE_FAST",
     [STORE_SUBSCR_DICT] = "STORE_SUBSCR_DICT",
+    [STORE_SUBSCR_LIST_INT] = "STORE_SUBSCR_LIST_INT",
     [FORMAT_VALUE] = "FORMAT_VALUE",
     [BUILD_CONST_KEY_MAP] = "BUILD_CONST_KEY_MAP",
     [BUILD_STRING] = "BUILD_STRING",
-    [STORE_SUBSCR_LIST_INT] = "STORE_SUBSCR_LIST_INT",
     [UNPACK_SEQUENCE_LIST] = "UNPACK_SEQUENCE_LIST",
     [UNPACK_SEQUENCE_TUPLE] = "UNPACK_SEQUENCE_TUPLE",
     [UNPACK_SEQUENCE_TWO_TUPLE] = "UNPACK_SEQUENCE_TWO_TUPLE",
+    [SEND_GEN] = "SEND_GEN",
     [LIST_EXTEND] = "LIST_EXTEND",
     [SET_UPDATE] = "SET_UPDATE",
     [DICT_MERGE] = "DICT_MERGE",
     [DICT_UPDATE] = "DICT_UPDATE",
-    [SEND_GEN] = "SEND_GEN",
+    [166] = "<166>",
     [167] = "<167>",
     [168] = "<168>",
     [169] = "<169>",
@@ -405,7 +405,7 @@ static const char *const _PyOpcode_OpName[263] = {
     [CALL] = "CALL",
     [KW_NAMES] = "KW_NAMES",
     [CALL_INTRINSIC_1] = "CALL_INTRINSIC_1",
-    [174] = "<174>",
+    [CALL_INTRINSIC_2] = "CALL_INTRINSIC_2",
     [175] = "<175>",
     [176] = "<176>",
     [177] = "<177>",
@@ -498,11 +498,11 @@ static const char *const _PyOpcode_OpName[263] = {
 #endif
 
 #define EXTRA_CASES \
+    case 166: \
     case 167: \
     case 168: \
     case 169: \
     case 170: \
-    case 174: \
     case 175: \
     case 176: \
     case 177: \
diff --git a/Include/opcode.h b/Include/opcode.h
index d643741c3c3a..760ff945f31f 100644
--- a/Include/opcode.h
+++ b/Include/opcode.h
@@ -43,7 +43,6 @@ extern "C" {
 #define RETURN_GENERATOR                        75
 #define RETURN_VALUE                            83
 #define SETUP_ANNOTATIONS                       85
-#define PREP_RERAISE_STAR                       88
 #define POP_EXCEPT                              89
 #define HAVE_ARGUMENT                           90
 #define STORE_NAME                              90
@@ -117,6 +116,7 @@ extern "C" {
 #define CALL                                   171
 #define KW_NAMES                               172
 #define CALL_INTRINSIC_1                       173
+#define CALL_INTRINSIC_2                       174
 #define MIN_PSEUDO_OPCODE                      256
 #define SETUP_FINALLY                          256
 #define SETUP_CLEANUP                          257
@@ -179,15 +179,15 @@ extern "C" {
 #define LOAD_GLOBAL_MODULE                      84
 #define STORE_ATTR_INSTANCE_VALUE               86
 #define STORE_ATTR_SLOT                         87
-#define STORE_ATTR_WITH_HINT                   113
-#define STORE_FAST__LOAD_FAST                  143
-#define STORE_FAST__STORE_FAST                 153
-#define STORE_SUBSCR_DICT                      154
-#define STORE_SUBSCR_LIST_INT                  158
-#define UNPACK_SEQUENCE_LIST                   159
-#define UNPACK_SEQUENCE_TUPLE                  160
-#define UNPACK_SEQUENCE_TWO_TUPLE              161
-#define SEND_GEN                               166
+#define STORE_ATTR_WITH_HINT                    88
+#define STORE_FAST__LOAD_FAST                  113
+#define STORE_FAST__STORE_FAST                 143
+#define STORE_SUBSCR_DICT                      153
+#define STORE_SUBSCR_LIST_INT                  154
+#define UNPACK_SEQUENCE_LIST                   158
+#define UNPACK_SEQUENCE_TUPLE                  159
+#define UNPACK_SEQUENCE_TWO_TUPLE              160
+#define SEND_GEN                               161
 #define DO_TRACING                             255
 
 #define HAS_ARG(op) ((((op) >= HAVE_ARGUMENT) && (!IS_PSEUDO_OPCODE(op)))\
diff --git a/Lib/importlib/_bootstrap_external.py b/Lib/importlib/_bootstrap_external.py
index 38d4a384c2cc..954401cfa85e 100644
--- a/Lib/importlib/_bootstrap_external.py
+++ b/Lib/importlib/_bootstrap_external.py
@@ -433,6 +433,7 @@ def _write_atomic(path, data, mode=0o666):
 #     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.13 will start with 3550
 
@@ -445,7 +446,7 @@ def _write_atomic(path, data, mode=0o666):
 # Whenever MAGIC_NUMBER is changed, the ranges in the magic_values array
 # in PC/launcher.c must also be updated.
 
-MAGIC_NUMBER = (3519).to_bytes(2, 'little') + b'\r\n'
+MAGIC_NUMBER = (3520).to_bytes(2, 'little') + b'\r\n'
 
 _RAW_MAGIC_NUMBER = int.from_bytes(MAGIC_NUMBER, 'little')  # For import.c
 
diff --git a/Lib/opcode.py b/Lib/opcode.py
index b69cd1bbdd61..809d24e51676 100644
--- a/Lib/opcode.py
+++ b/Lib/opcode.py
@@ -127,7 +127,6 @@ def pseudo_op(name, op, real_ops):
 
 def_op('SETUP_ANNOTATIONS', 85)
 
-def_op('PREP_RERAISE_STAR', 88)
 def_op('POP_EXCEPT', 89)
 
 HAVE_ARGUMENT = 90             # real opcodes from here have an argument:
@@ -224,6 +223,7 @@ def pseudo_op(name, op, real_ops):
 def_op('KW_NAMES', 172)
 hasconst.append(172)
 def_op('CALL_INTRINSIC_1', 173)
+def_op('CALL_INTRINSIC_2', 174)
 
 hasarg.extend([op for op in opmap.values() if op >= HAVE_ARGUMENT])
 
diff --git a/Misc/NEWS.d/next/Core and Builtins/2023-02-13-18-21-14.gh-issue-101799.wpHbCn.rst b/Misc/NEWS.d/next/Core and Builtins/2023-02-13-18-21-14.gh-issue-101799.wpHbCn.rst
new file mode 100644
index 000000000000..3233a573be7a
--- /dev/null
+++ b/Misc/NEWS.d/next/Core and Builtins/2023-02-13-18-21-14.gh-issue-101799.wpHbCn.rst	
@@ -0,0 +1,2 @@
+Add :opcode:`CALL_INTRINSIC_2` and use it instead of
+:opcode:`PREP_RERAISE_STAR`.
diff --git a/Python/bytecodes.c b/Python/bytecodes.c
index 429cd7fdafa1..be54e5f6f589 100644
--- a/Python/bytecodes.c
+++ b/Python/bytecodes.c
@@ -501,7 +501,14 @@ dummy_func(
         inst(CALL_INTRINSIC_1, (value -- res)) {
             assert(oparg <= MAX_INTRINSIC_1);
             res = _PyIntrinsics_UnaryFunctions[oparg](tstate, value);
-            Py_DECREF(value);
+            DECREF_INPUTS();
+            ERROR_IF(res == NULL, error);
+        }
+
+        inst(CALL_INTRINSIC_2, (value2, value1 -- res)) {
+            assert(oparg <= MAX_INTRINSIC_2);
+            res = _PyIntrinsics_BinaryFunctions[oparg](tstate, value2, value1);
+            DECREF_INPUTS();
             ERROR_IF(res == NULL, error);
         }
 
@@ -788,15 +795,6 @@ dummy_func(
             goto exception_unwind;
         }
 
-        inst(PREP_RERAISE_STAR, (orig, excs -- val)) {
-            assert(PyList_Check(excs));
-
-            val = _PyExc_PrepReraiseStar(orig, excs);
-            DECREF_INPUTS();
-
-            ERROR_IF(val == NULL, error);
-        }
-
         inst(END_ASYNC_FOR, (awaitable, exc -- )) {
             assert(exc && PyExceptionInstance_Check(exc));
             if (PyErr_GivenExceptionMatches(exc, PyExc_StopAsyncIteration)) {
@@ -2383,7 +2381,7 @@ dummy_func(
         }
 
         // Cache layout: counter/1, func_version/2, min_args/1
-        // Neither CALL_INTRINSIC_1 nor CALL_FUNCTION_EX are members!
+        // Neither CALL_INTRINSIC_1/2 nor CALL_FUNCTION_EX are members!
         family(call, INLINE_CACHE_ENTRIES_CALL) = {
             CALL,
             CALL_BOUND_METHOD_EXACT_ARGS,
diff --git a/Python/compile.c b/Python/compile.c
index b49eda314eee..0534b536e3d1 100644
--- a/Python/compile.c
+++ b/Python/compile.c
@@ -3431,7 +3431,7 @@ compiler_try_except(struct compiler *c, stmt_ty s)
 
    [orig, res, rest]                Ln+1:     LIST_APPEND 1  ) add unhandled exc to res (could be None)
 
-   [orig, res]                                PREP_RERAISE_STAR
+   [orig, res]                                CALL_INTRINSIC_2 PREP_RERAISE_STAR
    [exc]                                      COPY 1
    [exc, exc]                                 POP_JUMP_IF_NOT_NONE  RER
    [exc]                                      POP_TOP
@@ -3580,7 +3580,7 @@ compiler_try_star_except(struct compiler *c, stmt_ty s)
     NEW_JUMP_TARGET_LABEL(c, reraise);
 
     USE_LABEL(c, reraise_star);
-    ADDOP(c, NO_LOCATION, PREP_RERAISE_STAR);
+    ADDOP_I(c, NO_LOCATION, CALL_INTRINSIC_2, INTRINSIC_PREP_RERAISE_STAR);
     ADDOP_I(c, NO_LOCATION, COPY, 1);
     ADDOP_JUMP(c, NO_LOCATION, POP_JUMP_IF_NOT_NONE, reraise);
 
diff --git a/Python/generated_cases.c.h b/Python/generated_cases.c.h
index 093ebff026b5..beb797cbd233 100644
--- a/Python/generated_cases.c.h
+++ b/Python/generated_cases.c.h
@@ -689,6 +689,20 @@
             DISPATCH();
         }
 
+        TARGET(CALL_INTRINSIC_2) {
+            PyObject *value1 = PEEK(1);
+            PyObject *value2 = PEEK(2);
+            PyObject *res;
+            assert(oparg <= MAX_INTRINSIC_2);
+            res = _PyIntrinsics_BinaryFunctions[oparg](tstate, value2, value1);
+            Py_DECREF(value2);
+            Py_DECREF(value1);
+            if (res == NULL) goto pop_2_error;
+            STACK_SHRINK(1);
+            POKE(1, res);
+            DISPATCH();
+        }
+
         TARGET(RAISE_VARARGS) {
             PyObject **args = &PEEK(oparg);
             PyObject *cause = NULL, *exc = NULL;
@@ -999,22 +1013,6 @@
             goto exception_unwind;
         }
 
-        TARGET(PREP_RERAISE_STAR) {
-            PyObject *excs = PEEK(1);
-            PyObject *orig = PEEK(2);
-            PyObject *val;
-            assert(PyList_Check(excs));
-
-            val = _PyExc_PrepReraiseStar(orig, excs);
-            Py_DECREF(orig);
-            Py_DECREF(excs);
-
-            if (val == NULL) goto pop_2_error;
-            STACK_SHRINK(1);
-            POKE(1, val);
-            DISPATCH();
-        }
-
         TARGET(END_ASYNC_FOR) {
             PyObject *exc = PEEK(1);
             PyObject *awaitable = PEEK(2);
diff --git a/Python/intrinsics.c b/Python/intrinsics.c
index ae1775862d94..9e90ef32130f 100644
--- a/Python/intrinsics.c
+++ b/Python/intrinsics.c
@@ -9,6 +9,7 @@
 #include "pycore_pyerrors.h"
 
 
+/******** Unary functions ********/
 
 static PyObject *
 no_intrinsic(PyThreadState* tstate, PyObject *unused)
@@ -208,3 +209,20 @@ _PyIntrinsics_UnaryFunctions[] = {
     [INTRINSIC_UNARY_POSITIVE] = unary_pos,
     [INTRINSIC_LIST_TO_TUPLE] = list_to_tuple,
 };
+
+
+/******** Binary functions ********/
+
+
+static PyObject *
+prep_reraise_star(PyThreadState* unused, PyObject *orig, PyObject *excs)
+{
+    assert(PyList_Check(excs));
+    return _PyExc_PrepReraiseStar(orig, excs);
+}
+
+instrinsic_func2
+_PyIntrinsics_BinaryFunctions[] = {
+    [INTRINSIC_PREP_RERAISE_STAR] = prep_reraise_star,
+};
+
diff --git a/Python/opcode_metadata.h b/Python/opcode_metadata.h
index d622eb12c8cb..f27906a3e349 100644
--- a/Python/opcode_metadata.h
+++ b/Python/opcode_metadata.h
@@ -88,6 +88,8 @@ _PyOpcode_num_popped(int opcode, int oparg, bool jump) {
             return 2;
         case CALL_INTRINSIC_1:
             return 1;
+        case CALL_INTRINSIC_2:
+            return 2;
         case RAISE_VARARGS:
             return oparg;
         case INTERPRETER_EXIT:
@@ -112,8 +114,6 @@ _PyOpcode_num_popped(int opcode, int oparg, bool jump) {
             return 1;
         case RERAISE:
             return oparg + 1;
-        case PREP_RERAISE_STAR:
-            return 2;
         case END_ASYNC_FOR:
             return 2;
         case CLEANUP_THROW:
@@ -440,6 +440,8 @@ _PyOpcode_num_pushed(int opcode, int oparg, bool jump) {
             return 0;
         case CALL_INTRINSIC_1:
             return 1;
+        case CALL_INTRINSIC_2:
+            return 1;
         case RAISE_VARARGS:
             return 0;
         case INTERPRETER_EXIT:
@@ -464,8 +466,6 @@ _PyOpcode_num_pushed(int opcode, int oparg, bool jump) {
             return 0;
         case RERAISE:
             return oparg;
-        case PREP_RERAISE_STAR:
-            return 1;
         case END_ASYNC_FOR:
             return 0;
         case CLEANUP_THROW:
@@ -760,6 +760,7 @@ const struct opcode_metadata _PyOpcode_opcode_metadata[256] = {
     [STORE_SUBSCR_DICT] = { DIR_NONE, DIR_NONE, DIR_NONE, true, INSTR_FMT_IXC },
     [DELETE_SUBSCR] = { DIR_NONE, DIR_NONE, DIR_NONE, true, INSTR_FMT_IX },
     [CALL_INTRINSIC_1] = { DIR_NONE, DIR_NONE, DIR_NONE, true, INSTR_FMT_IB },
+    [CALL_INTRINSIC_2] = { DIR_NONE, DIR_NONE, DIR_NONE, true, INSTR_FMT_IB },
     [RAISE_VARARGS] = { DIR_NONE, DIR_NONE, DIR_NONE, true, INSTR_FMT_IB },
     [INTERPRETER_EXIT] = { DIR_NONE, DIR_NONE, DIR_NONE, true, INSTR_FMT_IX },
     [RETURN_VALUE] = { DIR_NONE, DIR_NONE, DIR_NONE, true, INSTR_FMT_IX },
@@ -772,7 +773,6 @@ const struct opcode_metadata _PyOpcode_opcode_metadata[256] = {
     [YIELD_VALUE] = { DIR_NONE, DIR_NONE, DIR_NONE, true, INSTR_FMT_IX },
     [POP_EXCEPT] = { DIR_NONE, DIR_NONE, DIR_NONE, true, INSTR_FMT_IX },
     [RERAISE] = { DIR_NONE, DIR_NONE, DIR_NONE, true, INSTR_FMT_IB },
-    [PREP_RERAISE_STAR] = { DIR_NONE, DIR_NONE, DIR_NONE, true, INSTR_FMT_IX },
     [END_ASYNC_FOR] = { DIR_NONE, DIR_NONE, DIR_NONE, true, INSTR_FMT_IX },
     [CLEANUP_THROW] = { DIR_NONE, DIR_NONE, DIR_NONE, true, INSTR_FMT_IX },
     [LOAD_ASSERTION_ERROR] = { DIR_NONE, DIR_NONE, DIR_NONE, true, INSTR_FMT_IX },
diff --git a/Python/opcode_targets.h b/Python/opcode_targets.h
index 301ec6e005da..bc64bd582fd5 100644
--- a/Python/opcode_targets.h
+++ b/Python/opcode_targets.h
@@ -87,7 +87,7 @@ static void *opcode_targets[256] = {
     &&TARGET_SETUP_ANNOTATIONS,
     &&TARGET_STORE_ATTR_INSTANCE_VALUE,
     &&TARGET_STORE_ATTR_SLOT,
-    &&TARGET_PREP_RERAISE_STAR,
+    &&TARGET_STORE_ATTR_WITH_HINT,
     &&TARGET_POP_EXCEPT,
     &&TARGET_STORE_NAME,
     &&TARGET_DELETE_NAME,
@@ -112,7 +112,7 @@ static void *opcode_targets[256] = {
     &&TARGET_JUMP_FORWARD,
     &&TARGET_JUMP_IF_FALSE_OR_POP,
     &&TARGET_JUMP_IF_TRUE_OR_POP,
-    &&TARGET_STORE_ATTR_WITH_HINT,
+    &&TARGET_STORE_FAST__LOAD_FAST,
     &&TARGET_POP_JUMP_IF_FALSE,
     &&TARGET_POP_JUMP_IF_TRUE,
     &&TARGET_LOAD_GLOBAL,
@@ -142,7 +142,7 @@ static void *opcode_targets[256] = {
     &&TARGET_JUMP_BACKWARD,
     &&TARGET_COMPARE_AND_BRANCH,
     &&TARGET_CALL_FUNCTION_EX,
-    &&TARGET_STORE_FAST__LOAD_FAST,
+    &&TARGET_STORE_FAST__STORE_FAST,
     &&TARGET_EXTENDED_ARG,
     &&TARGET_LIST_APPEND,
     &&TARGET_SET_ADD,
@@ -152,20 +152,20 @@ static void *opcode_targets[256] = {
     &&TARGET_YIELD_VALUE,
     &&TARGET_RESUME,
     &&TARGET_MATCH_CLASS,
-    &&TARGET_STORE_FAST__STORE_FAST,
     &&TARGET_STORE_SUBSCR_DICT,
+    &&TARGET_STORE_SUBSCR_LIST_INT,
     &&TARGET_FORMAT_VALUE,
     &&TARGET_BUILD_CONST_KEY_MAP,
     &&TARGET_BUILD_STRING,
-    &&TARGET_STORE_SUBSCR_LIST_INT,
     &&TARGET_UNPACK_SEQUENCE_LIST,
     &&TARGET_UNPACK_SEQUENCE_TUPLE,
     &&TARGET_UNPACK_SEQUENCE_TWO_TUPLE,
+    &&TARGET_SEND_GEN,
     &&TARGET_LIST_EXTEND,
     &&TARGET_SET_UPDATE,
     &&TARGET_DICT_MERGE,
     &&TARGET_DICT_UPDATE,
-    &&TARGET_SEND_GEN,
+    &&_unknown_opcode,
     &&_unknown_opcode,
     &&_unknown_opcode,
     &&_unknown_opcode,
@@ -173,7 +173,7 @@ static void *opcode_targets[256] = {
     &&TARGET_CALL,
     &&TARGET_KW_NAMES,
     &&TARGET_CALL_INTRINSIC_1,
-    &&_unknown_opcode,
+    &&TARGET_CALL_INTRINSIC_2,
     &&_unknown_opcode,
     &&_unknown_opcode,
     &&_unknown_opcode,



More information about the Python-checkins mailing list