diff options
author | Brandt Bucher <brandtbucher@microsoft.com> | 2023-08-09 11:19:39 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-08-09 18:19:39 +0000 |
commit | a9caf9cf9041d6d0b69f8be0fd778dd1f9b50e74 (patch) | |
tree | 5e325bac9eda1b264d3e5fd32991eed91d243f16 /Python/flowgraph.c | |
parent | 0a7f48b9a8d54809f1e9272337aefe2444158e64 (diff) | |
download | cpython-a9caf9cf9041d6d0b69f8be0fd778dd1f9b50e74.tar.gz cpython-a9caf9cf9041d6d0b69f8be0fd778dd1f9b50e74.zip |
GH-105848: Simplify the arrangement of CALL's stack (GH-107788)
Diffstat (limited to 'Python/flowgraph.c')
-rw-r--r-- | Python/flowgraph.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/Python/flowgraph.c b/Python/flowgraph.c index a72b85d45aa..5b6b3f3cfef 100644 --- a/Python/flowgraph.c +++ b/Python/flowgraph.c @@ -1536,10 +1536,10 @@ optimize_basic_block(PyObject *const_cache, basicblock *bb, PyObject *consts) break; case KW_NAMES: break; - case PUSH_NULL: - if (nextop == LOAD_GLOBAL && (inst[1].i_opcode & 1) == 0) { - INSTR_SET_OP0(inst, NOP); - inst[1].i_oparg |= 1; + case LOAD_GLOBAL: + if (nextop == PUSH_NULL && (oparg & 1) == 0) { + INSTR_SET_OP1(inst, LOAD_GLOBAL, oparg | 1); + INSTR_SET_OP0(&bb->b_instr[i + 1], NOP); } break; case COMPARE_OP: |