Lines Matching refs:ip

41     const byte *ip = bytecode;  in mp_prof_extract_prelude()  local
43 MP_BC_PRELUDE_SIG_DECODE(ip); in mp_prof_extract_prelude()
51 MP_BC_PRELUDE_SIZE_DECODE(ip); in mp_prof_extract_prelude()
53 prelude->line_info = ip + 4; in mp_prof_extract_prelude()
54 prelude->opcodes = ip + n_info + n_cell; in mp_prof_extract_prelude()
56 qstr block_name = ip[0] | (ip[1] << 8); in mp_prof_extract_prelude()
57 qstr source_file = ip[2] | (ip[3] << 8); in mp_prof_extract_prelude()
272 o->lasti = code_state->ip - prelude->opcodes; in mp_obj_new_frame()
371 o->lasti = code_state->ip - prelude->opcodes; in mp_prof_frame_update()
407 size_t current_line_no = mp_prof_bytecode_lineno(rc, code_state->ip - prelude->opcodes); in mp_prof_instr_tick()
415 const byte *ip = code_state->ip; in mp_prof_instr_tick() local
416 if (*ip == MP_BC_RETURN_VALUE || *ip == MP_BC_YIELD_VALUE) { in mp_prof_instr_tick()
419 if (code_state->prev_state && *ip == MP_BC_RETURN_VALUE) { in mp_prof_instr_tick()
447 unum = (unum << 7) + (*ip & 0x7f); \
448 } while ((*ip++ & 0x80) != 0); \
450 #define DECODE_ULABEL do { unum = (ip[0] | (ip[1] << 8)); ip += 2; } while (0)
451 #define DECODE_SLABEL do { unum = (ip[0] | (ip[1] << 8)) - 0x8000; ip += 2; } while (0)
454 qst = ip[0] | ip[1] << 8; \
455 ip += 2;
470 STATIC const byte *mp_prof_opcode_decode(const byte *ip, const mp_uint_t *const_table, mp_dis_instr… in mp_prof_opcode_decode() argument
481 switch (*ip++) { in mp_prof_opcode_decode()
496 if ((ip[0] & 0x40) != 0) { in mp_prof_opcode_decode()
501 num = (num << 7) | (*ip & 0x7f); in mp_prof_opcode_decode()
502 } while ((*ip++ & 0x80) != 0); in mp_prof_opcode_decode()
544 instruction->argobjex_cache = MP_OBJ_NEW_SMALL_INT(*ip++); in mp_prof_opcode_decode()
554 instruction->argobjex_cache = MP_OBJ_NEW_SMALL_INT(*ip++); in mp_prof_opcode_decode()
564 instruction->argobjex_cache = MP_OBJ_NEW_SMALL_INT(*ip++); in mp_prof_opcode_decode()
622 instruction->argobjex_cache = MP_OBJ_NEW_SMALL_INT(*ip++); in mp_prof_opcode_decode()
826 mp_uint_t n_closed_over = *ip++; in mp_prof_opcode_decode()
836 mp_uint_t n_closed_over = *ip++; in mp_prof_opcode_decode()
915 if (ip[-1] < MP_BC_LOAD_CONST_SMALL_INT_MULTI + 64) { in mp_prof_opcode_decode()
917 instruction->arg = (mp_int_t)ip[-1] - MP_BC_LOAD_CONST_SMALL_INT_MULTI - 16; in mp_prof_opcode_decode()
918 } else if (ip[-1] < MP_BC_LOAD_FAST_MULTI + 16) { in mp_prof_opcode_decode()
920 instruction->arg = (mp_uint_t)ip[-1] - MP_BC_LOAD_FAST_MULTI; in mp_prof_opcode_decode()
921 } else if (ip[-1] < MP_BC_STORE_FAST_MULTI + 16) { in mp_prof_opcode_decode()
923 instruction->arg = (mp_uint_t)ip[-1] - MP_BC_STORE_FAST_MULTI; in mp_prof_opcode_decode()
924 } else if (ip[-1] < MP_BC_UNARY_OP_MULTI + MP_UNARY_OP_NUM_BYTECODE) { in mp_prof_opcode_decode()
926 instruction->arg = (mp_uint_t)ip[-1] - MP_BC_UNARY_OP_MULTI; in mp_prof_opcode_decode()
927 } else if (ip[-1] < MP_BC_BINARY_OP_MULTI + MP_BINARY_OP_NUM_BYTECODE) { in mp_prof_opcode_decode()
928 mp_uint_t op = ip[-1] - MP_BC_BINARY_OP_MULTI; in mp_prof_opcode_decode()
932 … mp_printf(&mp_plat_print, "code %p, opcode 0x%02x not implemented\n", ip - 1, ip[-1]); in mp_prof_opcode_decode()
934 return ip; in mp_prof_opcode_decode()
939 return ip; in mp_prof_opcode_decode()
942 void mp_prof_print_instr(const byte *ip, mp_code_state_t *code_state) { in mp_prof_print_instr() argument
944 mp_prof_opcode_decode(ip, code_state->fun_bc->rc->const_table, instruction); in mp_prof_print_instr()
948 mp_uint_t offset = ip - prelude->opcodes; in mp_prof_print_instr()
954 ip, in mp_prof_print_instr()
963 mp_printf(&mp_plat_print, " %02x %02x %02x %02x", ip[0], ip[1], ip[2], ip[3]); in mp_prof_print_instr()
966 mp_printf(&mp_plat_print, " 0x%02x %q [%d]", *ip, instruction->qstr_opname, instruction->arg); in mp_prof_print_instr()