diff options
author | Mark Shannon <mark@hotpy.org> | 2024-08-01 23:19:05 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-08-01 23:19:05 (GMT) |
commit | df13a1821a90fcfb75eca59aad6af1f0893b1e77 (patch) | |
tree | e917574fea945573980717b4823202049568893e /Python/optimizer_analysis.c | |
parent | fda6bd842a2b93a501526f1b830eb900d935ac73 (diff) | |
download | cpython-df13a1821a90fcfb75eca59aad6af1f0893b1e77.zip cpython-df13a1821a90fcfb75eca59aad6af1f0893b1e77.tar.gz cpython-df13a1821a90fcfb75eca59aad6af1f0893b1e77.tar.bz2 |
GH-118095: Add tier two support for BINARY_SUBSCR_GETITEM (GH-120793)
Diffstat (limited to 'Python/optimizer_analysis.c')
-rw-r--r-- | Python/optimizer_analysis.c | 11 |
1 files changed, 2 insertions, 9 deletions
diff --git a/Python/optimizer_analysis.c b/Python/optimizer_analysis.c index 8c86641..f7adb44 100644 --- a/Python/optimizer_analysis.c +++ b/Python/optimizer_analysis.c @@ -52,14 +52,6 @@ #define DPRINTF(level, ...) #endif - - -static inline bool -op_is_end(uint32_t opcode) -{ - return opcode == _EXIT_TRACE || opcode == _JUMP_TO_TOP; -} - static int get_mutations(PyObject* dict) { assert(PyDict_CheckExact(dict)); @@ -288,7 +280,7 @@ remove_globals(_PyInterpreterFrame *frame, _PyUOpInstruction *buffer, prechecked_function_version = (uint32_t)buffer[pc].operand; break; default: - if (op_is_end(opcode)) { + if (is_terminator(inst)) { return 1; } break; @@ -552,6 +544,7 @@ remove_unneeded_uops(_PyUOpInstruction *buffer, int buffer_size) } case _JUMP_TO_TOP: case _EXIT_TRACE: + case _DYNAMIC_EXIT: return pc + 1; default: { |