GH-128914: Remove conditional stack effects from bytecodes.c and the code generators (GH-128918)

This commit is contained in:
Mark Shannon 2025-01-20 17:09:23 +00:00 committed by GitHub
parent 0a6412f9cc
commit ab61d3f430
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
44 changed files with 1460 additions and 1679 deletions

View file

@ -1274,10 +1274,7 @@ uop_optimize(
for (int pc = 0; pc < length; pc++) {
int opcode = buffer[pc].opcode;
int oparg = buffer[pc].oparg;
if (_PyUop_Flags[opcode] & HAS_OPARG_AND_1_FLAG) {
buffer[pc].opcode = opcode + 1 + (oparg & 1);
}
else if (oparg < _PyUop_Replication[opcode]) {
if (oparg < _PyUop_Replication[opcode]) {
buffer[pc].opcode = opcode + oparg + 1;
}
else if (is_terminator(&buffer[pc])) {