Lines Matching refs:jump

903 static SLJIT_INLINE sljit_ins * detect_jump_type(struct sljit_jump *jump, sljit_ins *code_ptr, slji…  in detect_jump_type()  argument
909 if (jump->flags & SLJIT_REWRITABLE_JUMP) in detect_jump_type()
912 if (jump->flags & JUMP_ADDR) in detect_jump_type()
913 target_addr = jump->u.target; in detect_jump_type()
915 SLJIT_ASSERT(jump->flags & JUMP_LABEL); in detect_jump_type()
916 target_addr = (sljit_uw)(code + jump->u.label->size); in detect_jump_type()
919 inst = (sljit_ins *)jump->addr; in detect_jump_type()
920 if (jump->flags & IS_COND) in detect_jump_type()
925 jump->flags |= PATCH_B; in detect_jump_type()
927 if (!(jump->flags & IS_COND)) { in detect_jump_type()
928 if (jump->flags & IS_JAL) { in detect_jump_type()
929 jump->flags &= ~(PATCH_B); in detect_jump_type()
930 jump->flags |= PATCH_J; in detect_jump_type()
955 jump->addr -= sizeof(sljit_ins); in detect_jump_type()
959 if (jump->flags & IS_COND) { in detect_jump_type()
960 if ((target_addr & ~0x3FFFFFFFL) == ((jump->addr + sizeof(sljit_ins)) & ~0x3FFFFFFFL)) { in detect_jump_type()
961 jump->flags |= PATCH_J; in detect_jump_type()
970 if ((target_addr & ~0x3FFFFFFFL) == ((jump->addr + sizeof(sljit_ins)) & ~0x3FFFFFFFL)) { in detect_jump_type()
971 jump->flags |= PATCH_J; in detect_jump_type()
973 if (jump->flags & IS_JAL) { in detect_jump_type()
1007 struct sljit_jump *jump; in sljit_generate_code() local
1021 jump = compiler->jumps; in sljit_generate_code()
1029 SLJIT_ASSERT(!jump || jump->addr >= word_count); in sljit_generate_code()
1039 if (jump && jump->addr == word_count) { in sljit_generate_code()
1040 if (jump->flags & IS_JAL) in sljit_generate_code()
1041 jump->addr = (sljit_uw)(code_ptr - 4); in sljit_generate_code()
1043 jump->addr = (sljit_uw)(code_ptr - 3); in sljit_generate_code()
1045 code_ptr = detect_jump_type(jump, code_ptr, code); in sljit_generate_code()
1046 jump = jump->next; in sljit_generate_code()
1069 SLJIT_ASSERT(!jump); in sljit_generate_code()
1073 jump = compiler->jumps; in sljit_generate_code()
1074 while (jump) { in sljit_generate_code()
1076 addr = (jump->flags & JUMP_LABEL) ? jump->u.label->addr : jump->u.target; in sljit_generate_code()
1077 buf_ptr = (sljit_ins *)jump->addr; in sljit_generate_code()
1079 if (jump->flags & PATCH_B) { in sljit_generate_code()
1080 addr = (sljit_sw)(addr - (jump->addr)) >> 3; in sljit_generate_code()
1091 if (jump->flags & PATCH_J) { in sljit_generate_code()
1092 SLJIT_ASSERT((addr & ~0x3FFFFFFFL) == ((jump->addr + sizeof(sljit_ins)) & ~0x3FFFFFFFL)); in sljit_generate_code()
1093 addr = (sljit_sw)(addr - (jump->addr)) >> 3; in sljit_generate_code()
1103 SLJIT_ASSERT(!(jump->flags & IS_JAL)); in sljit_generate_code()
1111 jump = jump->next; in sljit_generate_code()
2318 struct sljit_jump *jump = NULL; in sljit_emit_ijump() local
2366 jump = (struct sljit_jump *)ensure_abuf(compiler, sizeof(struct sljit_jump)); in sljit_emit_ijump()
2367 FAIL_IF(!jump); in sljit_emit_ijump()
2368 set_jump(jump, compiler, JUMP_ADDR | ((type >= SLJIT_FAST_CALL) ? IS_JAL : 0)); in sljit_emit_ijump()
2369 jump->u.target = srcw; in sljit_emit_ijump()
2374 jump->addr = compiler->size; in sljit_emit_ijump()
2377 jump->addr = compiler->size; in sljit_emit_ijump()
2390 if (jump) in sljit_emit_ijump()
2391 jump->addr = compiler->size; in sljit_emit_ijump()
2406 struct sljit_jump *jump; in sljit_emit_jump() local
2415 jump = (struct sljit_jump *)ensure_abuf(compiler, sizeof(struct sljit_jump)); in sljit_emit_jump()
2416 PTR_FAIL_IF(!jump); in sljit_emit_jump()
2417 set_jump(jump, compiler, type & SLJIT_REWRITABLE_JUMP); in sljit_emit_jump()
2465 jump->flags |= flags; in sljit_emit_jump()
2474 jump->addr = compiler->size; in sljit_emit_jump()
2479 jump->flags |= IS_JAL | (type >= SLJIT_CALL0 ? SLJIT_REWRITABLE_JUMP : 0); in sljit_emit_jump()
2481 jump->addr = compiler->size; in sljit_emit_jump()
2485 return jump; in sljit_emit_jump()