Lines Matching refs:dst

727 	sljit_s32 dst, sljit_sw dstw,
730 #define EMIT_MOV(compiler, dst, dstw, src, srcw) \ argument
731 FAIL_IF(emit_mov(compiler, dst, dstw, src, srcw));
734 sljit_s32 single, sljit_s32 dst, sljit_sw dstw, sljit_s32 src);
737 sljit_s32 single, sljit_s32 dst, sljit_s32 src, sljit_sw srcw);
898 sljit_s32 dst, sljit_sw dstw, in emit_mov() argument
904 inst = emit_x86_instruction(compiler, 1, src, 0, dst, dstw); in emit_mov()
910 if (FAST_IS_REG(dst)) { in emit_mov()
912 return emit_do_imm(compiler, MOV_r_i32 | reg_map[dst], srcw); in emit_mov()
916 return emit_load_imm64(compiler, dst, srcw); in emit_mov()
919 …return emit_do_imm32(compiler, (reg_map[dst] >= 8) ? REX_B : 0, U8(MOV_r_i32 | reg_lmap[dst]), src… in emit_mov()
927 inst = emit_x86_instruction(compiler, 1, TMP_REG1, 0, dst, dstw); in emit_mov()
933 inst = emit_x86_instruction(compiler, 1, SLJIT_IMM, srcw, dst, dstw); in emit_mov()
938 if (FAST_IS_REG(dst)) { in emit_mov()
939 inst = emit_x86_instruction(compiler, 1, dst, 0, src, srcw); in emit_mov()
950 inst = emit_x86_instruction(compiler, 1, TMP_REG1, 0, dst, dstw); in emit_mov()
1110 sljit_s32 dst, sljit_sw dstw, in emit_mov_byte() argument
1124 if (FAST_IS_REG(dst)) { in emit_mov_byte()
1126 return emit_do_imm(compiler, MOV_r_i32 | reg_map[dst], srcw); in emit_mov_byte()
1128 inst = emit_x86_instruction(compiler, 1, SLJIT_IMM, srcw, dst, 0); in emit_mov_byte()
1134 …inst = emit_x86_instruction(compiler, 1 | EX86_BYTE_ARG | EX86_NO_REXW, SLJIT_IMM, srcw, dst, dstw… in emit_mov_byte()
1140 dst_r = FAST_IS_REG(dst) ? dst : TMP_REG1; in emit_mov_byte()
1142 if ((dst & SLJIT_MEM) && FAST_IS_REG(src)) { in emit_mov_byte()
1156 SLJIT_ASSERT(FAST_IS_REG(dst)); in emit_mov_byte()
1157 if (reg_map[dst] < 4) { in emit_mov_byte()
1158 if (dst != src) in emit_mov_byte()
1159 EMIT_MOV(compiler, dst, 0, src, 0); in emit_mov_byte()
1160 inst = emit_x86_instruction(compiler, 2, dst, 0, dst, 0); in emit_mov_byte()
1166 if (dst != src) in emit_mov_byte()
1167 EMIT_MOV(compiler, dst, 0, src, 0); in emit_mov_byte()
1170 inst = emit_x86_instruction(compiler, 1 | EX86_SHIFT_INS, SLJIT_IMM, 24, dst, 0); in emit_mov_byte()
1174 inst = emit_x86_instruction(compiler, 1 | EX86_SHIFT_INS, SLJIT_IMM, 24, dst, 0); in emit_mov_byte()
1179 inst = emit_x86_instruction(compiler, 1 | EX86_BIN_INS, SLJIT_IMM, 0xff, dst, 0); in emit_mov_byte()
1195 if (dst & SLJIT_MEM) { in emit_mov_byte()
1199 if ((dst & REG_MASK) == SLJIT_R0) { in emit_mov_byte()
1200 if ((dst & OFFS_REG_MASK) == TO_OFFS_REG(SLJIT_R1)) in emit_mov_byte()
1206 if ((dst & OFFS_REG_MASK) != TO_OFFS_REG(SLJIT_R0)) in emit_mov_byte()
1208 else if ((dst & REG_MASK) == SLJIT_R1) in emit_mov_byte()
1223 inst = emit_x86_instruction(compiler, 1, work_r, 0, dst, dstw); in emit_mov_byte()
1237 inst = emit_x86_instruction(compiler, 1, dst_r, 0, dst, dstw); in emit_mov_byte()
1242 inst = emit_x86_instruction(compiler, 1 | EX86_REX | EX86_NO_REXW, dst_r, 0, dst, dstw); in emit_mov_byte()
1276 sljit_s32 dst, sljit_sw dstw, in emit_mov_half() argument
1287 if (FAST_IS_REG(dst)) { in emit_mov_half()
1289 return emit_do_imm(compiler, MOV_r_i32 | reg_map[dst], srcw); in emit_mov_half()
1291 inst = emit_x86_instruction(compiler, 1, SLJIT_IMM, srcw, dst, 0); in emit_mov_half()
1297 …instruction(compiler, 1 | EX86_HALF_ARG | EX86_NO_REXW | EX86_PREF_66, SLJIT_IMM, srcw, dst, dstw); in emit_mov_half()
1303 dst_r = FAST_IS_REG(dst) ? dst : TMP_REG1; in emit_mov_half()
1305 if ((dst & SLJIT_MEM) && FAST_IS_REG(src)) in emit_mov_half()
1314 if (dst & SLJIT_MEM) { in emit_mov_half()
1315 inst = emit_x86_instruction(compiler, 1 | EX86_NO_REXW | EX86_PREF_66, dst_r, 0, dst, dstw); in emit_mov_half()
1324 sljit_s32 dst, sljit_sw dstw, in emit_unary() argument
1329 if (dst == src && dstw == srcw) { in emit_unary()
1331 inst = emit_x86_instruction(compiler, 1, 0, 0, dst, dstw); in emit_unary()
1338 if (FAST_IS_REG(dst)) { in emit_unary()
1339 EMIT_MOV(compiler, dst, 0, src, srcw); in emit_unary()
1340 inst = emit_x86_instruction(compiler, 1, 0, 0, dst, 0); in emit_unary()
1352 EMIT_MOV(compiler, dst, dstw, TMP_REG1, 0); in emit_unary()
1357 sljit_s32 dst, sljit_sw dstw, in emit_not_with_flags() argument
1362 if (FAST_IS_REG(dst)) { in emit_not_with_flags()
1363 EMIT_MOV(compiler, dst, 0, src, srcw); in emit_not_with_flags()
1364 inst = emit_x86_instruction(compiler, 1, 0, 0, dst, 0); in emit_not_with_flags()
1368 inst = emit_x86_instruction(compiler, 1, dst, 0, dst, 0); in emit_not_with_flags()
1382 EMIT_MOV(compiler, dst, dstw, TMP_REG1, 0); in emit_not_with_flags()
1391 sljit_s32 dst, sljit_sw dstw, in emit_clz() argument
1402 dst_r = FAST_IS_REG(dst) ? dst : TMP_REG1; in emit_clz()
1444 if (dst & SLJIT_MEM) in emit_clz()
1445 EMIT_MOV(compiler, dst, dstw, TMP_REG1, 0); in emit_clz()
1450 sljit_s32 dst, sljit_sw dstw, in sljit_emit_op1() argument
1459 CHECK(check_sljit_emit_op1(compiler, op, dst, dstw, src, srcw)); in sljit_emit_op1()
1460 ADJUST_LOCAL_OFFSET(dst, dstw); in sljit_emit_op1()
1463 CHECK_EXTRA_REGS(dst, dstw, dst_is_ereg = 1); in sljit_emit_op1()
1476 if (FAST_IS_REG(src) && src == dst) { in sljit_emit_op1()
1519 return emit_mov(compiler, dst, dstw, src, srcw); in sljit_emit_op1()
1525 SLJIT_ASSERT(dst == SLJIT_MEM1(SLJIT_SP)); in sljit_emit_op1()
1526 dst = TMP_REG1; in sljit_emit_op1()
1538 EMIT_MOV(compiler, dst, dstw, src, srcw); in sljit_emit_op1()
1541 FAIL_IF(emit_mov_byte(compiler, 0, dst, dstw, src, srcw)); in sljit_emit_op1()
1544 FAIL_IF(emit_mov_byte(compiler, 1, dst, dstw, src, srcw)); in sljit_emit_op1()
1547 FAIL_IF(emit_mov_half(compiler, 0, dst, dstw, src, srcw)); in sljit_emit_op1()
1550 FAIL_IF(emit_mov_half(compiler, 1, dst, dstw, src, srcw)); in sljit_emit_op1()
1554 FAIL_IF(emit_mov_int(compiler, 0, dst, dstw, src, srcw)); in sljit_emit_op1()
1557 FAIL_IF(emit_mov_int(compiler, 1, dst, dstw, src, srcw)); in sljit_emit_op1()
1561 EMIT_MOV(compiler, dst, dstw, src, srcw); in sljit_emit_op1()
1568 if (SLJIT_UNLIKELY(dst_is_ereg) && dst == TMP_REG1) in sljit_emit_op1()
1577 return emit_not_with_flags(compiler, dst, dstw, src, srcw); in sljit_emit_op1()
1578 return emit_unary(compiler, NOT_rm, dst, dstw, src, srcw); in sljit_emit_op1()
1581 return emit_clz(compiler, op_flags, dst, dstw, src, srcw); in sljit_emit_op1()
1589 sljit_s32 dst, sljit_sw dstw, argument
1599 if (dst == src1 && dstw == src1w) {
1602 …if ((dst == SLJIT_R0) && (src2w > 127 || src2w < -128) && (compiler->mode32 || IS_HALFWORD(src2w))…
1604 if ((dst == SLJIT_R0) && (src2w > 127 || src2w < -128)) {
1609 BINARY_IMM(op_imm, op_mr, src2w, dst, dstw);
1612 else if (FAST_IS_REG(dst)) {
1613 inst = emit_x86_instruction(compiler, 1, dst, dstw, src2, src2w);
1619 inst = emit_x86_instruction(compiler, 1, src2, src2w, dst, dstw);
1625 inst = emit_x86_instruction(compiler, 1, TMP_REG1, 0, dst, dstw);
1633 if (dst == src2 && dstw == src2w) {
1636 …if ((dst == SLJIT_R0) && (src1w > 127 || src1w < -128) && (compiler->mode32 || IS_HALFWORD(src1w))…
1638 if ((dst == SLJIT_R0) && (src1w > 127 || src1w < -128)) {
1643 BINARY_IMM(op_imm, op_mr, src1w, dst, dstw);
1646 else if (FAST_IS_REG(dst)) {
1647 inst = emit_x86_instruction(compiler, 1, dst, dstw, src1, src1w);
1652 inst = emit_x86_instruction(compiler, 1, src1, src1w, dst, dstw);
1658 inst = emit_x86_instruction(compiler, 1, TMP_REG1, 0, dst, dstw);
1666 if (FAST_IS_REG(dst)) {
1667 EMIT_MOV(compiler, dst, 0, src1, src1w);
1669 BINARY_IMM(op_imm, op_mr, src2w, dst, 0);
1672 inst = emit_x86_instruction(compiler, 1, dst, 0, src2, src2w);
1688 EMIT_MOV(compiler, dst, dstw, TMP_REG1, 0);
1696 sljit_s32 dst, sljit_sw dstw, argument
1706 if (dst == src1 && dstw == src1w) {
1709 …if ((dst == SLJIT_R0) && (src2w > 127 || src2w < -128) && (compiler->mode32 || IS_HALFWORD(src2w))…
1711 if ((dst == SLJIT_R0) && (src2w > 127 || src2w < -128)) {
1716 BINARY_IMM(op_imm, op_mr, src2w, dst, dstw);
1719 else if (FAST_IS_REG(dst)) {
1720 inst = emit_x86_instruction(compiler, 1, dst, dstw, src2, src2w);
1725 inst = emit_x86_instruction(compiler, 1, src2, src2w, dst, dstw);
1731 inst = emit_x86_instruction(compiler, 1, TMP_REG1, 0, dst, dstw);
1739 if (FAST_IS_REG(dst) && dst != src2) {
1740 EMIT_MOV(compiler, dst, 0, src1, src1w);
1742 BINARY_IMM(op_imm, op_mr, src2w, dst, 0);
1745 inst = emit_x86_instruction(compiler, 1, dst, 0, src2, src2w);
1761 EMIT_MOV(compiler, dst, dstw, TMP_REG1, 0);
1768 sljit_s32 dst, sljit_sw dstw, argument
1773 sljit_s32 dst_r = FAST_IS_REG(dst) ? dst : TMP_REG1;
1889 if (dst & SLJIT_MEM)
1890 EMIT_MOV(compiler, dst, dstw, TMP_REG1, 0);
1896 sljit_s32 dst, sljit_sw dstw, argument
1904 if (dst == src1 && dstw == src1w)
1906 if (dst == src2 && dstw == src2w)
1909 dst_r = FAST_IS_REG(dst) ? dst : TMP_REG1;
1946 return emit_mov(compiler, dst, dstw, TMP_REG1, 0);
2115 sljit_s32 dst, sljit_sw dstw, argument
2122 if (dst == src1 && dstw == src1w) {
2123 inst = emit_x86_instruction(compiler, 1 | EX86_SHIFT_INS, src2, src2w, dst, dstw);
2128 if (dst == SLJIT_PREF_SHIFT_REG && src2 == SLJIT_PREF_SHIFT_REG) {
2136 if (FAST_IS_REG(dst)) {
2137 EMIT_MOV(compiler, dst, 0, src1, src1w);
2138 inst = emit_x86_instruction(compiler, 1 | EX86_SHIFT_INS, src2, src2w, dst, 0);
2148 EMIT_MOV(compiler, dst, dstw, TMP_REG1, 0);
2152 if (dst == SLJIT_PREF_SHIFT_REG) {
2160 else if (FAST_IS_REG(dst) && dst != src2 && dst != TMP_REG1 && !ADDRESSING_DEPENDS_ON(src2, dst)) {
2161 if (src1 != dst)
2162 EMIT_MOV(compiler, dst, 0, src1, src1w);
2165 inst = emit_x86_instruction(compiler, 1 | EX86_SHIFT_INS, SLJIT_PREF_SHIFT_REG, 0, dst, 0);
2189 if (dst != TMP_REG1)
2190 return emit_mov(compiler, dst, dstw, TMP_REG1, 0);
2198 sljit_s32 dst, sljit_sw dstw, argument
2206 return emit_shift(compiler, mode, dst, dstw, src1, src1w, src2, src2w);
2209 return emit_shift(compiler, mode, dst, dstw, src1, src1w, src2, src2w);
2212 return emit_mov(compiler, dst, dstw, src1, src1w);
2215 dst, dstw, src1, src1w, SLJIT_IMM, 0);
2219 return emit_shift(compiler, mode, dst, dstw, src1, src1w, src2, src2w);
2221 if (!FAST_IS_REG(dst))
2224 FAIL_IF(emit_shift(compiler, mode, dst, dstw, src1, src1w, src2, src2w));
2226 if (FAST_IS_REG(dst))
2227 return emit_cmp_binary(compiler, dst, dstw, SLJIT_IMM, 0);
2232 sljit_s32 dst, sljit_sw dstw, argument
2237 CHECK(check_sljit_emit_op2(compiler, op, 0, dst, dstw, src1, src1w, src2, src2w));
2238 ADJUST_LOCAL_OFFSET(dst, dstw);
2242 CHECK_EXTRA_REGS(dst, dstw, (void)0);
2249 SLJIT_ASSERT(dst != TMP_REG1 || HAS_FLAGS(op));
2254 if (emit_lea_binary(compiler, dst, dstw, src1, src1w, src2, src2w) != SLJIT_ERR_UNSUPPORTED)
2258 dst, dstw, src1, src1w, src2, src2w);
2261 dst, dstw, src1, src1w, src2, src2w);
2264 return emit_unary(compiler, NEG_rm, dst, dstw, src2, src2w);
2267 …if ((src2 & SLJIT_IMM) && emit_lea_binary(compiler, dst, dstw, src1, src1w, SLJIT_IMM, -src2w) != …
2269 if (FAST_IS_REG(dst) && src2 == dst) {
2270 FAIL_IF(emit_non_cum_binary(compiler, BINARY_OPCODE(SUB), dst, 0, dst, 0, src1, src1w));
2271 return emit_unary(compiler, NEG_rm, dst, 0, dst, 0);
2276 dst, dstw, src1, src1w, src2, src2w);
2279 dst, dstw, src1, src1w, src2, src2w);
2281 return emit_mul(compiler, dst, dstw, src1, src1w, src2, src2w);
2284 dst, dstw, src1, src1w, src2, src2w);
2287 dst, dstw, src1, src1w, src2, src2w);
2290 dst, dstw, src1, src1w, src2, src2w);
2293 dst, dstw, src1, src1w, src2, src2w);
2296 dst, dstw, src1, src1w, src2, src2w);
2299 dst, dstw, src1, src1w, src2, src2w);
2447 sljit_s32 single, sljit_s32 dst, sljit_s32 src, sljit_sw srcw) argument
2449 return emit_sse2(compiler, MOVSD_x_xm, single, dst, src, srcw);
2453 sljit_s32 single, sljit_s32 dst, sljit_sw dstw, sljit_s32 src) argument
2455 return emit_sse2(compiler, MOVSD_xm_x, single, src, dst, dstw);
2459 sljit_s32 dst, sljit_sw dstw, argument
2462 sljit_s32 dst_r = FAST_IS_REG(dst) ? dst : TMP_REG1;
2475 if (dst & SLJIT_MEM)
2476 return emit_mov(compiler, dst, dstw, TMP_REG1, 0);
2481 sljit_s32 dst, sljit_sw dstw, argument
2484 sljit_s32 dst_r = FAST_IS_REG(dst) ? dst : TMP_FREG;
2511 return emit_sse2_store(compiler, op & SLJIT_32, dst, dstw, TMP_FREG);
2528 sljit_s32 dst, sljit_sw dstw, argument
2538 SELECT_FOP1_OPERATION_WITH_CHECKS(compiler, op, dst, dstw, src, srcw);
2541 if (FAST_IS_REG(dst))
2542 return emit_sse2_load(compiler, op & SLJIT_32, dst, src, srcw);
2544 return emit_sse2_store(compiler, op & SLJIT_32, dst, dstw, src);
2546 return emit_sse2_store(compiler, op & SLJIT_32, dst, dstw, TMP_FREG);
2550 dst_r = FAST_IS_REG(dst) ? dst : TMP_FREG;
2564 return emit_sse2_store(compiler, op & SLJIT_32, dst, dstw, TMP_FREG);
2568 if (FAST_IS_REG(dst)) {
2569 dst_r = dst;
2570 if (dst != src)
2589 return emit_sse2_store(compiler, op & SLJIT_32, dst, dstw, TMP_FREG);
2594 sljit_s32 dst, sljit_sw dstw, argument
2601 CHECK(check_sljit_emit_fop2(compiler, op, dst, dstw, src1, src1w, src2, src2w));
2602 ADJUST_LOCAL_OFFSET(dst, dstw);
2610 if (FAST_IS_REG(dst)) {
2611 dst_r = dst;
2612 if (dst == src1)
2614 else if (dst == src2 && (op == SLJIT_ADD_F64 || op == SLJIT_MUL_F64)) {
2619 else if (dst != src2)
2650 return emit_sse2_store(compiler, op & SLJIT_32, dst, dstw, TMP_FREG);
2754 sljit_s32 dst, sljit_sw dstw, argument
2763 sljit_s32 dst_save = dst;
2767 CHECK(check_sljit_emit_op_flags(compiler, op, dst, dstw, type));
2769 ADJUST_LOCAL_OFFSET(dst, dstw);
2770 CHECK_EXTRA_REGS(dst, dstw, (void)0);
2777 if (GET_OPCODE(op) == SLJIT_OR && !GET_ALL_FLAGS(op) && FAST_IS_REG(dst)) {
2786 *inst++ = U8(REX | (reg_map[TMP_REG1] <= 7 ? 0 : REX_R) | (reg_map[dst] <= 7 ? 0 : REX_B));
2788 *inst++ = U8(MOD_REG | (reg_lmap[TMP_REG1] << 3) | reg_lmap[dst]);
2792 reg = (GET_OPCODE(op) < SLJIT_ADD && FAST_IS_REG(dst)) ? dst : TMP_REG1;
2813 return emit_mov(compiler, dst, dstw, TMP_REG1, 0);
2824 if (GET_OPCODE(op) < SLJIT_ADD && FAST_IS_REG(dst)) {
2825 if (reg_map[dst] <= 4) {
2833 *inst++ = U8(MOD_REG | reg_map[dst]);
2837 *inst = U8(MOD_REG | (reg_map[dst] << 3) | reg_map[dst]);
2848 EMIT_MOV(compiler, dst, 0, SLJIT_IMM, 0);
2857 *inst++ = U8(MOD_REG | (reg_map[dst] << 3) | reg_map[TMP_REG1]);
2872 *inst++ = U8(MOD_REG | (reg_map[dst] << 3) | 0 /* eax */);
2877 if (GET_OPCODE(op) == SLJIT_OR && !GET_ALL_FLAGS(op) && FAST_IS_REG(dst) && reg_map[dst] <= 4) {
2880 if (dst != SLJIT_R0) {
2890 *inst++ = MOD_REG | (0 /* eax */ << 3) | reg_map[dst];
2928 return emit_mov(compiler, dst, dstw, TMP_REG1, 0);
2978 … sljit_s32 sljit_get_local_base(struct sljit_compiler *compiler, sljit_s32 dst, sljit_sw dstw, slj… argument
2981 CHECK(check_sljit_get_local_base(compiler, dst, dstw, offset));
2982 ADJUST_LOCAL_OFFSET(dst, dstw);
2984 CHECK_EXTRA_REGS(dst, dstw, (void)0);
2996 …SLJIT_ASSERT(emit_lea_binary(compiler, dst, dstw, SLJIT_SP, 0, TMP_REG1, 0) != SLJIT_ERR_UNSUPPORT…
2999 return emit_lea_binary(compiler, dst, dstw, SLJIT_SP, 0, TMP_REG1, 0);
3005 return emit_lea_binary(compiler, dst, dstw, SLJIT_SP, 0, SLJIT_IMM, offset);
3006 return emit_mov(compiler, dst, dstw, SLJIT_SP, 0);
3009 …t sljit_const* sljit_emit_const(struct sljit_compiler *compiler, sljit_s32 dst, sljit_sw dstw, slj… argument
3018 CHECK_PTR(check_sljit_emit_const(compiler, dst, dstw, init_value));
3019 ADJUST_LOCAL_OFFSET(dst, dstw);
3021 CHECK_EXTRA_REGS(dst, dstw, (void)0);
3029 reg = FAST_IS_REG(dst) ? dst : TMP_REG1;
3034 if (emit_mov(compiler, dst, dstw, SLJIT_IMM, init_value))
3045 if (dst & SLJIT_MEM)
3046 if (emit_mov(compiler, dst, dstw, TMP_REG1, 0))
3053 …ljit_put_label* sljit_emit_put_label(struct sljit_compiler *compiler, sljit_s32 dst, sljit_sw dstw) argument
3063 CHECK_PTR(check_sljit_emit_put_label(compiler, dst, dstw));
3064 ADJUST_LOCAL_OFFSET(dst, dstw);
3066 CHECK_EXTRA_REGS(dst, dstw, (void)0);
3074 reg = FAST_IS_REG(dst) ? dst : TMP_REG1;
3079 if (emit_mov(compiler, dst, dstw, SLJIT_IMM, 0))
3084 if (dst & SLJIT_MEM) {
3086 if (emit_mov(compiler, dst, dstw, TMP_REG1, 0))