mirror of
https://github.com/python/cpython.git
synced 2026-04-15 08:11:10 +00:00
gh-100239: Propagate type info through _BINARY_OP_EXTEND in tier 2 (GH-148146)
This commit is contained in:
parent
476fadc9ae
commit
efda60e2ec
6 changed files with 67 additions and 18 deletions
12
Python/optimizer_cases.c.h
generated
12
Python/optimizer_cases.c.h
generated
|
|
@ -1168,8 +1168,16 @@
|
|||
right = stack_pointer[-1];
|
||||
left = stack_pointer[-2];
|
||||
PyObject *descr = (PyObject *)this_instr->operand0;
|
||||
(void)descr;
|
||||
res = sym_new_not_null(ctx);
|
||||
_PyBinaryOpSpecializationDescr *d = (_PyBinaryOpSpecializationDescr *)descr;
|
||||
if (d != NULL && d->result_type != NULL) {
|
||||
res = sym_new_type(ctx, d->result_type);
|
||||
if (d->result_unique) {
|
||||
res = PyJitRef_MakeUnique(res);
|
||||
}
|
||||
}
|
||||
else {
|
||||
res = sym_new_not_null(ctx);
|
||||
}
|
||||
l = left;
|
||||
r = right;
|
||||
CHECK_STACK_BOUNDS(1);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue