Lines Matching refs:op

720 SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op0(struct sljit_compiler *compiler, sljit_si op)  in sljit_emit_op0()  argument
728 CHECK(check_sljit_emit_op0(compiler, op)); in sljit_emit_op0()
730 switch (GET_OPCODE(op)) { in sljit_emit_op0()
762 compiler->mode32 = op & SLJIT_INT_OP; in sljit_emit_op0()
765 op = GET_OPCODE(op); in sljit_emit_op0()
766 if (op == SLJIT_LUDIV) { in sljit_emit_op0()
777 if (op == SLJIT_LSDIV) { in sljit_emit_op0()
808 *inst = MOD_REG | ((op >= SLJIT_LUDIV) ? reg_map[TMP_REG1] : reg_map[SLJIT_R1]); in sljit_emit_op0()
811 size = (!compiler->mode32 || op >= SLJIT_LUDIV) ? 3 : 2; in sljit_emit_op0()
820 *inst++ = REX_W | ((op >= SLJIT_LUDIV) ? REX_B : 0); in sljit_emit_op0()
821 else if (op >= SLJIT_LUDIV) in sljit_emit_op0()
824 *inst = MOD_REG | ((op >= SLJIT_LUDIV) ? reg_lmap[TMP_REG1] : reg_lmap[SLJIT_R1]); in sljit_emit_op0()
832 switch (op) { in sljit_emit_op0()
1247 SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op1(struct sljit_compiler *compiler, sljit_si op, in sljit_emit_op1() argument
1253 sljit_si op_flags = GET_ALL_FLAGS(op); in sljit_emit_op1()
1262 CHECK(check_sljit_emit_op1(compiler, op, dst, dstw, src, srcw)); in sljit_emit_op1()
1272 op = GET_OPCODE(op); in sljit_emit_op1()
1273 if (op >= SLJIT_MOV && op <= SLJIT_MOVU_P) { in sljit_emit_op1()
1280 if (!TYPE_CAST_NEEDED(op)) in sljit_emit_op1()
1284 if (op == SLJIT_MOV_SI && (src & SLJIT_MEM)) in sljit_emit_op1()
1285 op = SLJIT_MOV_UI; in sljit_emit_op1()
1286 if (op == SLJIT_MOVU_SI && (src & SLJIT_MEM)) in sljit_emit_op1()
1287 op = SLJIT_MOVU_UI; in sljit_emit_op1()
1288 if (op == SLJIT_MOV_UI && (src & SLJIT_IMM)) in sljit_emit_op1()
1289 op = SLJIT_MOV_SI; in sljit_emit_op1()
1290 if (op == SLJIT_MOVU_UI && (src & SLJIT_IMM)) in sljit_emit_op1()
1291 op = SLJIT_MOVU_SI; in sljit_emit_op1()
1296 if (op >= SLJIT_MOVU) { in sljit_emit_op1()
1298 op -= 8; in sljit_emit_op1()
1302 switch (op) { in sljit_emit_op1()
1339 …if (SLJIT_UNLIKELY(dst_is_ereg) && (!(op == SLJIT_MOV || op == SLJIT_MOV_UI || op == SLJIT_MOV_SI … in sljit_emit_op1()
1345 switch (op) { in sljit_emit_op1()
1392 switch (op) { in sljit_emit_op1()
2116 SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op2(struct sljit_compiler *compiler, sljit_si op, argument
2122 CHECK(check_sljit_emit_op2(compiler, op, dst, dstw, src1, src1w, src2, src2w));
2131 compiler->mode32 = op & SLJIT_INT_OP;
2134 if (GET_OPCODE(op) >= SLJIT_MUL) {
2135 if (SLJIT_UNLIKELY(GET_FLAGS(op)))
2137 else if (SLJIT_UNLIKELY(op & SLJIT_KEEP_FLAGS) && !compiler->flags_saved)
2141 switch (GET_OPCODE(op)) {
2143 if (!GET_FLAGS(op)) {
2144 …if (emit_lea_binary(compiler, op & SLJIT_KEEP_FLAGS, dst, dstw, src1, src1w, src2, src2w) != SLJIT…
2149 if (SLJIT_UNLIKELY(op & SLJIT_KEEP_FLAGS) && !compiler->flags_saved)
2156 else if (SLJIT_UNLIKELY(op & SLJIT_KEEP_FLAGS))
2158 if (SLJIT_UNLIKELY(GET_FLAGS(op)))
2163 if (!GET_FLAGS(op)) {
2164 …if ((src2 & SLJIT_IMM) && emit_lea_binary(compiler, op & SLJIT_KEEP_FLAGS, dst, dstw, src1, src1w,…
2169 if (SLJIT_UNLIKELY(op & SLJIT_KEEP_FLAGS) && !compiler->flags_saved)
2178 else if (SLJIT_UNLIKELY(op & SLJIT_KEEP_FLAGS))
2180 if (SLJIT_UNLIKELY(GET_FLAGS(op)))
2198 return emit_shift_with_flags(compiler, SHL, GET_FLAGS(op),
2201 return emit_shift_with_flags(compiler, SHR, GET_FLAGS(op),
2204 return emit_shift_with_flags(compiler, SAR, GET_FLAGS(op),
2312 …tic SLJIT_INLINE sljit_si sljit_emit_fop1_convw_fromd(struct sljit_compiler *compiler, sljit_si op, argument
2320 if (GET_OPCODE(op) == SLJIT_CONVW_FROMD)
2324 …inst = emit_x86_instruction(compiler, 2 | ((op & SLJIT_SINGLE_OP) ? EX86_PREF_F3 : EX86_PREF_F2) |…
2334 …tic SLJIT_INLINE sljit_si sljit_emit_fop1_convd_fromw(struct sljit_compiler *compiler, sljit_si op, argument
2342 if (GET_OPCODE(op) == SLJIT_CONVD_FROMW)
2348 if (GET_OPCODE(op) == SLJIT_CONVD_FROMI)
2356 …inst = emit_x86_instruction(compiler, 2 | ((op & SLJIT_SINGLE_OP) ? EX86_PREF_F3 : EX86_PREF_F2) |…
2365 return emit_sse2_store(compiler, op & SLJIT_SINGLE_OP, dst, dstw, TMP_FREG);
2369 static SLJIT_INLINE sljit_si sljit_emit_fop1_cmp(struct sljit_compiler *compiler, sljit_si op, argument
2375 FAIL_IF(emit_sse2_load(compiler, op & SLJIT_SINGLE_OP, TMP_FREG, src1, src1w));
2378 return emit_sse2_logic(compiler, UCOMISD_x_xm, !(op & SLJIT_SINGLE_OP), src1, src2, src2w);
2381 SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_fop1(struct sljit_compiler *compiler, sljit_si op, argument
2392 SELECT_FOP1_OPERATION_WITH_CHECKS(compiler, op, dst, dstw, src, srcw);
2394 if (GET_OPCODE(op) == SLJIT_DMOV) {
2396 return emit_sse2_load(compiler, op & SLJIT_SINGLE_OP, dst, src, srcw);
2398 return emit_sse2_store(compiler, op & SLJIT_SINGLE_OP, dst, dstw, src);
2399 FAIL_IF(emit_sse2_load(compiler, op & SLJIT_SINGLE_OP, TMP_FREG, src, srcw));
2400 return emit_sse2_store(compiler, op & SLJIT_SINGLE_OP, dst, dstw, TMP_FREG);
2403 if (GET_OPCODE(op) == SLJIT_CONVD_FROMS) {
2409 FAIL_IF(emit_sse2_logic(compiler, UNPCKLPD_x_xm, op & SLJIT_SINGLE_OP, src, src, 0));
2412 FAIL_IF(emit_sse2_load(compiler, !(op & SLJIT_SINGLE_OP), TMP_FREG, src, srcw));
2416 FAIL_IF(emit_sse2_logic(compiler, CVTPD2PS_x_xm, op & SLJIT_SINGLE_OP, dst_r, src, 0));
2418 return emit_sse2_store(compiler, op & SLJIT_SINGLE_OP, dst, dstw, TMP_FREG);
2425 FAIL_IF(emit_sse2_load(compiler, op & SLJIT_SINGLE_OP, dst_r, src, srcw));
2429 FAIL_IF(emit_sse2_load(compiler, op & SLJIT_SINGLE_OP, dst_r, src, srcw));
2432 switch (GET_OPCODE(op)) {
2434 …FAIL_IF(emit_sse2_logic(compiler, XORPD_x_xm, 1, dst_r, SLJIT_MEM0(), (sljit_sw)(op & SLJIT_SINGLE…
2438 …FAIL_IF(emit_sse2_logic(compiler, ANDPD_x_xm, 1, dst_r, SLJIT_MEM0(), (sljit_sw)(op & SLJIT_SINGLE…
2443 return emit_sse2_store(compiler, op & SLJIT_SINGLE_OP, dst, dstw, TMP_FREG);
2447 SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_fop2(struct sljit_compiler *compiler, sljit_si op, argument
2455 CHECK(check_sljit_emit_fop2(compiler, op, dst, dstw, src1, src1w, src2, src2w));
2468 else if (dst == src2 && (op == SLJIT_DADD || op == SLJIT_DMUL)) {
2474 FAIL_IF(emit_sse2_load(compiler, op & SLJIT_SINGLE_OP, dst_r, src1, src1w));
2477 FAIL_IF(emit_sse2_load(compiler, op & SLJIT_SINGLE_OP, TMP_FREG, src1, src1w));
2482 FAIL_IF(emit_sse2_load(compiler, op & SLJIT_SINGLE_OP, TMP_FREG, src1, src1w));
2485 switch (GET_OPCODE(op)) {
2487 FAIL_IF(emit_sse2(compiler, ADDSD_x_xm, op & SLJIT_SINGLE_OP, dst_r, src2, src2w));
2491 FAIL_IF(emit_sse2(compiler, SUBSD_x_xm, op & SLJIT_SINGLE_OP, dst_r, src2, src2w));
2495 FAIL_IF(emit_sse2(compiler, MULSD_x_xm, op & SLJIT_SINGLE_OP, dst_r, src2, src2w));
2499 FAIL_IF(emit_sse2(compiler, DIVSD_x_xm, op & SLJIT_SINGLE_OP, dst_r, src2, src2w));
2504 return emit_sse2_store(compiler, op & SLJIT_SINGLE_OP, dst, dstw, TMP_FREG);
2647 SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op_flags(struct sljit_compiler *compiler, sljit_si op, argument
2663 CHECK(check_sljit_emit_op_flags(compiler, op, dst, dstw, src, srcw, type));
2672 FAIL_IF(emit_restore_flags(compiler, op & SLJIT_KEEP_FLAGS));
2679 if (GET_OPCODE(op) == SLJIT_OR && !GET_ALL_FLAGS(op) && FAST_IS_REG(dst) && dst == src) {
2694 reg = (op == SLJIT_MOV && FAST_IS_REG(dst)) ? dst : TMP_REG1;
2712 if (GET_OPCODE(op) < SLJIT_ADD) {
2713 compiler->mode32 = GET_OPCODE(op) != SLJIT_MOV;
2720 return sljit_emit_op2(compiler, op, dst, dstw, dst, dstw, TMP_REG1, 0);
2722 if (GET_OPCODE(op) < SLJIT_ADD && FAST_IS_REG(dst)) {
2775 …if (GET_OPCODE(op) == SLJIT_OR && !GET_ALL_FLAGS(op) && FAST_IS_REG(dst) && dst == src && reg_map[…
2824 if (GET_OPCODE(op) < SLJIT_ADD)
2831 return sljit_emit_op2(compiler, op, dst_save, dstw_save, dst_save, dstw_save, TMP_REG1, 0);