mirror of
https://github.com/python/cpython.git
synced 2025-08-03 16:39:00 +00:00
gh-106529: Make FOR_ITER a viable uop (#112134)
This uses the new mechanism whereby certain uops are replaced by others during translation, using the `_PyUop_Replacements` table. We further special-case the `_FOR_ITER_TIER_TWO` uop to update the deoptimization target to point just past the corresponding `END_FOR` opcode. Two tiny code cleanups are also part of this PR.
This commit is contained in:
parent
d59feb5dbe
commit
1995955173
8 changed files with 138 additions and 43 deletions
6
Python/abstract_interp_cases.c.h
generated
6
Python/abstract_interp_cases.c.h
generated
|
@ -624,6 +624,12 @@
|
|||
break;
|
||||
}
|
||||
|
||||
case _FOR_ITER_TIER_TWO: {
|
||||
STACK_GROW(1);
|
||||
PARTITIONNODE_OVERWRITE((_Py_PARTITIONNODE_t *)PARTITIONNODE_NULLROOT, PEEK(-(-1)), true);
|
||||
break;
|
||||
}
|
||||
|
||||
case _ITER_CHECK_LIST: {
|
||||
break;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue