mirror of
https://github.com/python/cpython.git
synced 2025-11-01 06:01:29 +00:00
gh-136183: Deal with escapes in JIT optimizer's constant evaluator (GH-136184)
This commit is contained in:
parent
f41e9c750e
commit
b3308973e3
6 changed files with 77 additions and 7 deletions
6
Python/optimizer_cases.c.h
generated
6
Python/optimizer_cases.c.h
generated
|
|
@ -2723,9 +2723,6 @@
|
|||
PyObject *lhs_o = PyStackRef_AsPyObjectBorrow(lhs);
|
||||
PyObject *rhs_o = PyStackRef_AsPyObjectBorrow(rhs);
|
||||
assert(_PyEval_BinaryOps[oparg]);
|
||||
stack_pointer[-2] = res;
|
||||
stack_pointer += -1;
|
||||
assert(WITHIN_STACK_BOUNDS());
|
||||
PyObject *res_o = _PyEval_BinaryOps[oparg](lhs_o, rhs_o);
|
||||
if (res_o == NULL) {
|
||||
JUMP_TO_LABEL(error);
|
||||
|
|
@ -2733,6 +2730,9 @@
|
|||
res_stackref = PyStackRef_FromPyObjectSteal(res_o);
|
||||
/* End of uop copied from bytecodes for constant evaluation */
|
||||
res = sym_new_const_steal(ctx, PyStackRef_AsPyObjectSteal(res_stackref));
|
||||
stack_pointer[-2] = res;
|
||||
stack_pointer += -1;
|
||||
assert(WITHIN_STACK_BOUNDS());
|
||||
break;
|
||||
}
|
||||
bool lhs_int = sym_matches_type(lhs, &PyLong_Type);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue