gh-100239: Propagate type info through _BINARY_OP_EXTEND in tier 2 (GH-148146)

This commit is contained in:
Pieter Eendebak 2026-04-06 14:52:42 +02:00 committed by GitHub
parent 476fadc9ae
commit efda60e2ec
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
6 changed files with 67 additions and 18 deletions

View file

@ -410,8 +410,16 @@ dummy_func(void) {
}
op(_BINARY_OP_EXTEND, (descr/4, left, right -- res, l, r)) {
(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;
}