diff options
author | Mark Shannon <mark@hotpy.org> | 2023-12-20 14:27:25 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-12-20 14:27:25 (GMT) |
commit | e96f26083bff31e86c068aa22542e91f38293ea3 (patch) | |
tree | 3b351f4fc54eff3c08caf811edbcd7c9fcb40c5d /Python/assemble.c | |
parent | a545a86ec64fbab325db101bdd8964f524a89790 (diff) | |
download | cpython-e96f26083bff31e86c068aa22542e91f38293ea3.zip cpython-e96f26083bff31e86c068aa22542e91f38293ea3.tar.gz cpython-e96f26083bff31e86c068aa22542e91f38293ea3.tar.bz2 |
GH-111485: Generate instruction and uop metadata (GH-113287)
Diffstat (limited to 'Python/assemble.c')
-rw-r--r-- | Python/assemble.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/Python/assemble.c b/Python/assemble.c index b6fb432..569454e 100644 --- a/Python/assemble.c +++ b/Python/assemble.c @@ -4,7 +4,7 @@ #include "pycore_code.h" // write_location_entry_start() #include "pycore_compile.h" #include "pycore_opcode_utils.h" // IS_BACKWARDS_JUMP_OPCODE -#include "pycore_opcode_metadata.h" // IS_PSEUDO_INSTR, _PyOpcode_Caches +#include "pycore_opcode_metadata.h" // is_pseudo_target, _PyOpcode_Caches #define DEFAULT_CODE_SIZE 128 @@ -710,13 +710,13 @@ resolve_unconditional_jumps(instr_sequence *instrs) bool is_forward = (instr->i_oparg > i); switch(instr->i_opcode) { case JUMP: - assert(SAME_OPCODE_METADATA(JUMP, JUMP_FORWARD)); - assert(SAME_OPCODE_METADATA(JUMP, JUMP_BACKWARD)); + assert(is_pseudo_target(JUMP, JUMP_FORWARD)); + assert(is_pseudo_target(JUMP, JUMP_BACKWARD)); instr->i_opcode = is_forward ? JUMP_FORWARD : JUMP_BACKWARD; break; case JUMP_NO_INTERRUPT: - assert(SAME_OPCODE_METADATA(JUMP_NO_INTERRUPT, JUMP_FORWARD)); - assert(SAME_OPCODE_METADATA(JUMP_NO_INTERRUPT, JUMP_BACKWARD_NO_INTERRUPT)); + assert(is_pseudo_target(JUMP_NO_INTERRUPT, JUMP_FORWARD)); + assert(is_pseudo_target(JUMP_NO_INTERRUPT, JUMP_BACKWARD_NO_INTERRUPT)); instr->i_opcode = is_forward ? JUMP_FORWARD : JUMP_BACKWARD_NO_INTERRUPT; break; |