diff options
Diffstat (limited to 'byterun/fix_code.c')
-rw-r--r-- | byterun/fix_code.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/byterun/fix_code.c b/byterun/fix_code.c index 5da63c62a..42df6333e 100644 --- a/byterun/fix_code.c +++ b/byterun/fix_code.c @@ -147,3 +147,11 @@ void set_instruction(code_t pos, opcode_t instr) #endif } +int is_instruction(opcode_t instr1, opcode_t instr2) +{ +#ifdef THREADED_CODE + return instr1 == (opcode_t)(instr_table[instr2] - instr_base); +#else + return instr1 == instr2; +#endif +} |