diff options
author | Mark Shannon <mark@hotpy.org> | 2022-12-14 11:12:53 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-12-14 11:12:53 +0000 |
commit | 6997e77bdf2297375962aaf82876da4e7ecdd61a (patch) | |
tree | 7f6540eecbb66fd373b22e944163bdcb436f245b /Python/ceval.c | |
parent | 985a71032bf055240e61259285a0b4925c925383 (diff) | |
download | cpython-git-6997e77bdf2297375962aaf82876da4e7ecdd61a.tar.gz |
GH-100222: Redefine _Py_CODEUNIT as a union to clarify structure of code unit. (GH-100223)
Diffstat (limited to 'Python/ceval.c')
-rw-r--r-- | Python/ceval.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Python/ceval.c b/Python/ceval.c index 9e4179e560..45f42800d7 100644 --- a/Python/ceval.c +++ b/Python/ceval.c @@ -864,7 +864,7 @@ GETITEM(PyObject *v, Py_ssize_t i) { STAT_INC(opcode, miss); \ STAT_INC((INSTNAME), miss); \ /* The counter is always the first cache entry: */ \ - if (ADAPTIVE_COUNTER_IS_ZERO(*next_instr)) { \ + if (ADAPTIVE_COUNTER_IS_ZERO(next_instr->cache)) { \ STAT_INC((INSTNAME), deopt); \ } \ else { \ @@ -1289,7 +1289,7 @@ handle_eval_breaker: } opcode = _PyOpcode_Deopt[opcode]; if (_PyOpcode_Caches[opcode]) { - _Py_CODEUNIT *counter = &next_instr[1]; + uint16_t *counter = &next_instr[1].cache; // The instruction is going to decrement the counter, so we need to // increment it here to make sure it doesn't try to specialize: if (!ADAPTIVE_COUNTER_IS_MAX(*counter)) { |