mirror of https://github.com/python/cpython
GH-107265: Add missing deoptimizations for ENTER_EXECUTOR's original opcode (GH-109420)
This commit is contained in:
parent
8ded34a1ff
commit
d5611f2804
|
@ -0,0 +1 @@
|
|||
Deopt opcodes hidden by the executor when base opcode is needed
|
|
@ -1505,7 +1505,7 @@ deopt_code(PyCodeObject *code, _Py_CODEUNIT *instructions)
|
|||
int opcode = _Py_GetBaseOpcode(code, i);
|
||||
if (opcode == ENTER_EXECUTOR) {
|
||||
_PyExecutorObject *exec = code->co_executors->executors[instructions[i].op.arg];
|
||||
opcode = exec->vm_data.opcode;
|
||||
opcode = _PyOpcode_Deopt[exec->vm_data.opcode];
|
||||
instructions[i].op.arg = exec->vm_data.oparg;
|
||||
}
|
||||
assert(opcode != ENTER_EXECUTOR);
|
||||
|
|
|
@ -306,7 +306,7 @@ _PyInstruction_GetLength(PyCodeObject *code, int offset)
|
|||
if (opcode == ENTER_EXECUTOR) {
|
||||
int exec_index = _PyCode_CODE(code)[offset].op.arg;
|
||||
_PyExecutorObject *exec = code->co_executors->executors[exec_index];
|
||||
opcode = exec->vm_data.opcode;
|
||||
opcode = _PyOpcode_Deopt[exec->vm_data.opcode];
|
||||
|
||||
}
|
||||
assert(opcode != ENTER_EXECUTOR);
|
||||
|
|
Loading…
Reference in New Issue