Lines Matching refs:op
827 SLJIT_API_FUNC_ATTRIBUTE sljit_s32 sljit_emit_return(struct sljit_compiler *compiler, sljit_s32 op,… in sljit_emit_return() argument
833 CHECK(check_sljit_emit_return(compiler, op, src, srcw)); in sljit_emit_return()
835 FAIL_IF(emit_mov_before_return(compiler, op, src, srcw)); in sljit_emit_return()
1087 static sljit_s32 emit_op(struct sljit_compiler *compiler, sljit_s32 op, sljit_s32 flags, in emit_op() argument
1107 SLJIT_ASSERT(HAS_FLAGS(op)); in emit_op()
1113 if (op >= SLJIT_MOV && op <= SLJIT_MOV_P) in emit_op()
1167 if (!(flags & REG_DEST) && op >= SLJIT_MOV && op <= SLJIT_MOV_P) in emit_op()
1178 if ((op >= SLJIT_MOV && op <= SLJIT_MOV_P) && (dst & SLJIT_MEM)) in emit_op()
1207 FAIL_IF(emit_single_op(compiler, op, flags, dst_r, src1_r, src2_r)); in emit_op()
1220 SLJIT_API_FUNC_ATTRIBUTE sljit_s32 sljit_emit_op0(struct sljit_compiler *compiler, sljit_s32 op) in sljit_emit_op0() argument
1223 sljit_s32 int_op = op & SLJIT_I32_OP; in sljit_emit_op0()
1227 CHECK(check_sljit_emit_op0(compiler, op)); in sljit_emit_op0()
1229 op = GET_OPCODE(op); in sljit_emit_op0()
1230 switch (op) { in sljit_emit_op0()
1239 …FAIL_IF(push_inst(compiler, (op == SLJIT_LMUL_UW ? DMULU : DMUL) | S(SLJIT_R0) | T(SLJIT_R1) | D(T… in sljit_emit_op0()
1240 …FAIL_IF(push_inst(compiler, (op == SLJIT_LMUL_UW ? DMUHU : DMUH) | S(SLJIT_R0) | T(SLJIT_R1) | D(T… in sljit_emit_op0()
1242 …FAIL_IF(push_inst(compiler, (op == SLJIT_LMUL_UW ? MULU : MUL) | S(SLJIT_R0) | T(SLJIT_R1) | D(TMP… in sljit_emit_op0()
1243 …FAIL_IF(push_inst(compiler, (op == SLJIT_LMUL_UW ? MUHU : MUH) | S(SLJIT_R0) | T(SLJIT_R1) | D(TMP… in sljit_emit_op0()
1249 …FAIL_IF(push_inst(compiler, (op == SLJIT_LMUL_UW ? DMULTU : DMULT) | S(SLJIT_R0) | T(SLJIT_R1), MO… in sljit_emit_op0()
1251 …FAIL_IF(push_inst(compiler, (op == SLJIT_LMUL_UW ? MULTU : MULT) | S(SLJIT_R0) | T(SLJIT_R1), MOVA… in sljit_emit_op0()
1264 …FAIL_IF(push_inst(compiler, ((op | 0x2) == SLJIT_DIV_UW ? DIVU : DIV) | S(SLJIT_R0) | T(SLJIT_R1) … in sljit_emit_op0()
1265 …FAIL_IF(push_inst(compiler, ((op | 0x2) == SLJIT_DIV_UW ? MODU : MOD) | S(SLJIT_R0) | T(SLJIT_R1) … in sljit_emit_op0()
1268 …FAIL_IF(push_inst(compiler, ((op | 0x2) == SLJIT_DIV_UW ? DDIVU : DDIV) | S(SLJIT_R0) | T(SLJIT_R1… in sljit_emit_op0()
1269 …FAIL_IF(push_inst(compiler, ((op | 0x2) == SLJIT_DIV_UW ? DMODU : DMOD) | S(SLJIT_R0) | T(SLJIT_R1… in sljit_emit_op0()
1272 …FAIL_IF(push_inst(compiler, ((op | 0x2) == SLJIT_DIV_UW ? DIVU : DIV) | S(SLJIT_R0) | T(SLJIT_R1) … in sljit_emit_op0()
1273 …FAIL_IF(push_inst(compiler, ((op | 0x2) == SLJIT_DIV_UW ? MODU : MOD) | S(SLJIT_R0) | T(SLJIT_R1) … in sljit_emit_op0()
1276 …return (op >= SLJIT_DIV_UW) ? SLJIT_SUCCESS : push_inst(compiler, ADDU_W | S(TMP_REG1) | TA(0) | D… in sljit_emit_op0()
1284 …FAIL_IF(push_inst(compiler, ((op | 0x2) == SLJIT_DIV_UW ? DIVU : DIV) | S(SLJIT_R0) | T(SLJIT_R1),… in sljit_emit_op0()
1286 …FAIL_IF(push_inst(compiler, ((op | 0x2) == SLJIT_DIV_UW ? DDIVU : DDIV) | S(SLJIT_R0) | T(SLJIT_R1… in sljit_emit_op0()
1288 …FAIL_IF(push_inst(compiler, ((op | 0x2) == SLJIT_DIV_UW ? DIVU : DIV) | S(SLJIT_R0) | T(SLJIT_R1),… in sljit_emit_op0()
1291 …return (op >= SLJIT_DIV_UW) ? SLJIT_SUCCESS : push_inst(compiler, MFHI | D(SLJIT_R1), DR(SLJIT_R1)… in sljit_emit_op0()
1324 SLJIT_API_FUNC_ATTRIBUTE sljit_s32 sljit_emit_op1(struct sljit_compiler *compiler, sljit_s32 op, in sljit_emit_op1() argument
1335 CHECK(check_sljit_emit_op1(compiler, op, dst, dstw, src, srcw)); in sljit_emit_op1()
1340 if ((op & SLJIT_I32_OP) && GET_OPCODE(op) >= SLJIT_NOT) in sljit_emit_op1()
1344 switch (GET_OPCODE(op)) { in sljit_emit_op1()
1376 return emit_op(compiler, op, flags, dst, dstw, TMP_REG1, 0, src, srcw); in sljit_emit_op1()
1379 …return emit_op(compiler, SLJIT_SUB | GET_ALL_FLAGS(op), flags | IMM_OP, dst, dstw, SLJIT_IMM, 0, s… in sljit_emit_op1()
1382 return emit_op(compiler, op, flags, dst, dstw, TMP_REG1, 0, src, srcw); in sljit_emit_op1()
1393 SLJIT_API_FUNC_ATTRIBUTE sljit_s32 sljit_emit_op2(struct sljit_compiler *compiler, sljit_s32 op, in sljit_emit_op2() argument
1405 CHECK(check_sljit_emit_op2(compiler, op, dst, dstw, src1, src1w, src2, src2w)); in sljit_emit_op2()
1410 if (dst == SLJIT_UNUSED && !HAS_FLAGS(op)) in sljit_emit_op2()
1414 if (op & SLJIT_I32_OP) { in sljit_emit_op2()
1423 switch (GET_OPCODE(op)) { in sljit_emit_op2()
1426 return emit_op(compiler, op, flags | CUMULATIVE_OP | IMM_OP, dst, dstw, src1, src1w, src2, src2w); in sljit_emit_op2()
1430 return emit_op(compiler, op, flags | IMM_OP, dst, dstw, src1, src1w, src2, src2w); in sljit_emit_op2()
1433 return emit_op(compiler, op, flags | CUMULATIVE_OP, dst, dstw, src1, src1w, src2, src2w); in sljit_emit_op2()
1438 …return emit_op(compiler, op, flags | CUMULATIVE_OP | LOGICAL_OP | IMM_OP, dst, dstw, src1, src1w, … in sljit_emit_op2()
1448 if (op & SLJIT_I32_OP) in sljit_emit_op2()
1454 return emit_op(compiler, op, flags | IMM_OP, dst, dstw, src1, src1w, src2, src2w); in sljit_emit_op2()
1465 SLJIT_API_FUNC_ATTRIBUTE sljit_s32 sljit_emit_op_src(struct sljit_compiler *compiler, sljit_s32 op, in sljit_emit_op_src() argument
1469 CHECK(check_sljit_emit_op_src(compiler, op, src, srcw)); in sljit_emit_op_src()
1472 switch (op) { in sljit_emit_op_src()
1522 #define FLOAT_DATA(op) (DOUBLE_DATA | ((op & SLJIT_F32_OP) >> 7)) argument
1523 #define FMT(op) (((op & SLJIT_F32_OP) ^ SLJIT_F32_OP) << (21 - 8)) argument
1525 …IT_INLINE sljit_s32 sljit_emit_fop1_conv_sw_from_f64(struct sljit_compiler *compiler, sljit_s32 op, in sljit_emit_fop1_conv_sw_from_f64() argument
1532 sljit_s32 flags = (GET_OPCODE(op) == SLJIT_CONV_SW_FROM_F64) << 21; in sljit_emit_fop1_conv_sw_from_f64()
1536 FAIL_IF(emit_op_mem2(compiler, FLOAT_DATA(op) | LOAD_DATA, FR(TMP_FREG1), src, srcw, dst, dstw)); in sljit_emit_fop1_conv_sw_from_f64()
1540 …FAIL_IF(push_inst(compiler, (TRUNC_W_S ^ (flags >> 19)) | FMT(op) | FS(src) | FD(TMP_FREG1), MOVAB… in sljit_emit_fop1_conv_sw_from_f64()
1553 …IT_INLINE sljit_s32 sljit_emit_fop1_conv_f64_from_sw(struct sljit_compiler *compiler, sljit_s32 op, in sljit_emit_fop1_conv_f64_from_sw() argument
1560 sljit_s32 flags = (GET_OPCODE(op) == SLJIT_CONV_F64_FROM_SW) << 21; in sljit_emit_fop1_conv_f64_from_sw()
1573 if (GET_OPCODE(op) == SLJIT_CONV_F64_FROM_S32) in sljit_emit_fop1_conv_f64_from_sw()
1580 …FAIL_IF(push_inst(compiler, CVT_S_S | flags | (4 << 21) | (((op & SLJIT_F32_OP) ^ SLJIT_F32_OP) >>… in sljit_emit_fop1_conv_f64_from_sw()
1583 return emit_op_mem2(compiler, FLOAT_DATA(op), FR(TMP_FREG1), dst, dstw, 0, 0); in sljit_emit_fop1_conv_f64_from_sw()
1591 static SLJIT_INLINE sljit_s32 sljit_emit_fop1_cmp(struct sljit_compiler *compiler, sljit_s32 op, in sljit_emit_fop1_cmp() argument
1598 …FAIL_IF(emit_op_mem2(compiler, FLOAT_DATA(op) | LOAD_DATA, FR(TMP_FREG1), src1, src1w, src2, src2w… in sljit_emit_fop1_cmp()
1603 FAIL_IF(emit_op_mem2(compiler, FLOAT_DATA(op) | LOAD_DATA, FR(TMP_FREG2), src2, src2w, 0, 0)); in sljit_emit_fop1_cmp()
1607 switch (GET_FLAG_TYPE(op)) { in sljit_emit_fop1_cmp()
1621 SLJIT_ASSERT(GET_FLAG_TYPE(op) == SLJIT_UNORDERED_F64 || GET_FLAG_TYPE(op) == SLJIT_ORDERED_F64); in sljit_emit_fop1_cmp()
1625 return push_inst(compiler, inst | FMT(op) | FT(src2) | FS(src1) | C_FD, UNMOVABLE_INS); in sljit_emit_fop1_cmp()
1628 SLJIT_API_FUNC_ATTRIBUTE sljit_s32 sljit_emit_fop1(struct sljit_compiler *compiler, sljit_s32 op, in sljit_emit_fop1() argument
1639 SELECT_FOP1_OPERATION_WITH_CHECKS(compiler, op, dst, dstw, src, srcw); in sljit_emit_fop1()
1641 if (GET_OPCODE(op) == SLJIT_CONV_F64_FROM_F32) in sljit_emit_fop1()
1642 op ^= SLJIT_F32_OP; in sljit_emit_fop1()
1647 FAIL_IF(emit_op_mem2(compiler, FLOAT_DATA(op) | LOAD_DATA, FR(dst_r), src, srcw, dst, dstw)); in sljit_emit_fop1()
1651 switch (GET_OPCODE(op)) { in sljit_emit_fop1()
1655 FAIL_IF(push_inst(compiler, MOV_S | FMT(op) | FS(src) | FD(dst_r), MOVABLE_INS)); in sljit_emit_fop1()
1661 FAIL_IF(push_inst(compiler, NEG_S | FMT(op) | FS(src) | FD(dst_r), MOVABLE_INS)); in sljit_emit_fop1()
1664 FAIL_IF(push_inst(compiler, ABS_S | FMT(op) | FS(src) | FD(dst_r), MOVABLE_INS)); in sljit_emit_fop1()
1667 …FAIL_IF(push_inst(compiler, CVT_S_S | ((op & SLJIT_F32_OP) ? 1 : (1 << 21)) | FS(src) | FD(dst_r),… in sljit_emit_fop1()
1668 op ^= SLJIT_F32_OP; in sljit_emit_fop1()
1673 return emit_op_mem2(compiler, FLOAT_DATA(op), FR(dst_r), dst, dstw, 0, 0); in sljit_emit_fop1()
1677 SLJIT_API_FUNC_ATTRIBUTE sljit_s32 sljit_emit_fop2(struct sljit_compiler *compiler, sljit_s32 op, in sljit_emit_fop2() argument
1685 CHECK(check_sljit_emit_fop2(compiler, op, dst, dstw, src1, src1w, src2, src2w)); in sljit_emit_fop2()
1696 if (getput_arg_fast(compiler, FLOAT_DATA(op) | LOAD_DATA, FR(TMP_FREG1), src1, src1w)) { in sljit_emit_fop2()
1704 if (getput_arg_fast(compiler, FLOAT_DATA(op) | LOAD_DATA, FR(TMP_FREG2), src2, src2w)) { in sljit_emit_fop2()
1713 …FAIL_IF(getput_arg(compiler, FLOAT_DATA(op) | LOAD_DATA, FR(TMP_FREG2), src2, src2w, src1, src1w)); in sljit_emit_fop2()
1714 FAIL_IF(getput_arg(compiler, FLOAT_DATA(op) | LOAD_DATA, FR(TMP_FREG1), src1, src1w, dst, dstw)); in sljit_emit_fop2()
1717 …FAIL_IF(getput_arg(compiler, FLOAT_DATA(op) | LOAD_DATA, FR(TMP_FREG1), src1, src1w, src2, src2w)); in sljit_emit_fop2()
1718 FAIL_IF(getput_arg(compiler, FLOAT_DATA(op) | LOAD_DATA, FR(TMP_FREG2), src2, src2w, dst, dstw)); in sljit_emit_fop2()
1722 FAIL_IF(getput_arg(compiler, FLOAT_DATA(op) | LOAD_DATA, FR(TMP_FREG1), src1, src1w, dst, dstw)); in sljit_emit_fop2()
1724 FAIL_IF(getput_arg(compiler, FLOAT_DATA(op) | LOAD_DATA, FR(TMP_FREG2), src2, src2w, dst, dstw)); in sljit_emit_fop2()
1731 switch (GET_OPCODE(op)) { in sljit_emit_fop2()
1733 FAIL_IF(push_inst(compiler, ADD_S | FMT(op) | FT(src2) | FS(src1) | FD(dst_r), MOVABLE_INS)); in sljit_emit_fop2()
1737 FAIL_IF(push_inst(compiler, SUB_S | FMT(op) | FT(src2) | FS(src1) | FD(dst_r), MOVABLE_INS)); in sljit_emit_fop2()
1741 FAIL_IF(push_inst(compiler, MUL_S | FMT(op) | FT(src2) | FS(src1) | FD(dst_r), MOVABLE_INS)); in sljit_emit_fop2()
1745 FAIL_IF(push_inst(compiler, DIV_S | FMT(op) | FT(src2) | FS(src1) | FD(dst_r), MOVABLE_INS)); in sljit_emit_fop2()
1750 FAIL_IF(emit_op_mem2(compiler, FLOAT_DATA(op), FR(TMP_FREG2), dst, dstw, 0, 0)); in sljit_emit_fop2()
2094 …JIT_API_FUNC_ATTRIBUTE sljit_s32 sljit_emit_op_flags(struct sljit_compiler *compiler, sljit_s32 op, in sljit_emit_op_flags() argument
2099 sljit_s32 saved_op = op; in sljit_emit_op_flags()
2103 sljit_s32 mem_type = (op & SLJIT_I32_OP) ? (INT_DATA | SIGNED_DATA) : WORD_DATA; in sljit_emit_op_flags()
2107 CHECK(check_sljit_emit_op_flags(compiler, op, dst, dstw, type)); in sljit_emit_op_flags()
2110 op = GET_OPCODE(op); in sljit_emit_op_flags()
2112 if (op == SLJIT_MOV_S32) in sljit_emit_op_flags()
2115 dst_ar = DR((op < SLJIT_ADD && FAST_IS_REG(dst)) ? dst : TMP_REG2); in sljit_emit_op_flags()
2120 if (op >= SLJIT_ADD && (dst & SLJIT_MEM)) in sljit_emit_op_flags()
2164 if (op < SLJIT_ADD) { in sljit_emit_op_flags()