mirror of
https://github.com/python/cpython.git
synced 2025-07-07 19:35:27 +00:00
Revert "GH-128914: Remove conditional stack effects from bytecodes.c
and the code generators (GH-128918)" (GH-129202)
The commit introduced a ~2.5-3% regression in the free threading build.
This reverts commit ab61d3f430
.
This commit is contained in:
parent
d7d066c3ab
commit
a10f99375e
44 changed files with 1679 additions and 1460 deletions
|
@ -1274,7 +1274,10 @@ uop_optimize(
|
|||
for (int pc = 0; pc < length; pc++) {
|
||||
int opcode = buffer[pc].opcode;
|
||||
int oparg = buffer[pc].oparg;
|
||||
if (oparg < _PyUop_Replication[opcode]) {
|
||||
if (_PyUop_Flags[opcode] & HAS_OPARG_AND_1_FLAG) {
|
||||
buffer[pc].opcode = opcode + 1 + (oparg & 1);
|
||||
}
|
||||
else if (oparg < _PyUop_Replication[opcode]) {
|
||||
buffer[pc].opcode = opcode + oparg + 1;
|
||||
}
|
||||
else if (is_terminator(&buffer[pc])) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue