Lines Matching refs:inst

262 #define INC_SIZE(s)			(*inst++ = (s), compiler->size += (s))
264 #define PUSH_REG(r) (*inst++ = (PUSH_r + (r)))
265 #define POP_REG(r) (*inst++ = (POP_r + (r)))
266 #define RET() (*inst++ = (RET_near))
267 #define RET_I16(n) (*inst++ = (RET_i16), *inst++ = n, *inst++ = 0)
269 #define MOV_RM(mod, reg, rm) (*inst++ = (MOV_r_rm), *inst++ = (mod) << 6 | (reg) << 3 | (rm))
683 sljit_u8* inst; in emit_mov() local
688 inst = emit_x86_instruction(compiler, 1, src, 0, dst, dstw); in emit_mov()
689 FAIL_IF(!inst); in emit_mov()
690 *inst = MOV_rm_r; in emit_mov()
711 inst = emit_x86_instruction(compiler, 1, TMP_REG1, 0, dst, dstw); in emit_mov()
712 FAIL_IF(!inst); in emit_mov()
713 *inst = MOV_rm_r; in emit_mov()
717 inst = emit_x86_instruction(compiler, 1, SLJIT_IMM, srcw, dst, dstw); in emit_mov()
718 FAIL_IF(!inst); in emit_mov()
719 *inst = MOV_rm_i32; in emit_mov()
723 inst = emit_x86_instruction(compiler, 1, dst, 0, src, srcw); in emit_mov()
724 FAIL_IF(!inst); in emit_mov()
725 *inst = MOV_r_rm; in emit_mov()
731 inst = emit_x86_instruction(compiler, 1, TMP_REG1, 0, src, srcw); in emit_mov()
732 FAIL_IF(!inst); in emit_mov()
733 *inst = MOV_r_rm; in emit_mov()
734 inst = emit_x86_instruction(compiler, 1, TMP_REG1, 0, dst, dstw); in emit_mov()
735 FAIL_IF(!inst); in emit_mov()
736 *inst = MOV_rm_r; in emit_mov()
742 sljit_u8 *inst; in sljit_emit_op0() local
752 inst = (sljit_u8*)ensure_buf(compiler, 1 + 1); in sljit_emit_op0()
753 FAIL_IF(!inst); in sljit_emit_op0()
755 *inst = INT3; in sljit_emit_op0()
758 inst = (sljit_u8*)ensure_buf(compiler, 1 + 1); in sljit_emit_op0()
759 FAIL_IF(!inst); in sljit_emit_op0()
761 *inst = NOP; in sljit_emit_op0()
789 inst = emit_x86_instruction(compiler, 1, SLJIT_R1, 0, SLJIT_R1, 0); in sljit_emit_op0()
791 inst = emit_x86_instruction(compiler, 1, TMP_REG1, 0, TMP_REG1, 0); in sljit_emit_op0()
793 FAIL_IF(!inst); in sljit_emit_op0()
794 *inst = XOR_r_rm; in sljit_emit_op0()
803 inst = (sljit_u8*)ensure_buf(compiler, 1 + 1); in sljit_emit_op0()
804 FAIL_IF(!inst); in sljit_emit_op0()
806 *inst = CDQ; in sljit_emit_op0()
809 inst = (sljit_u8*)ensure_buf(compiler, 1 + 1); in sljit_emit_op0()
810 FAIL_IF(!inst); in sljit_emit_op0()
812 *inst = CDQ; in sljit_emit_op0()
814 inst = (sljit_u8*)ensure_buf(compiler, 1 + 2); in sljit_emit_op0()
815 FAIL_IF(!inst); in sljit_emit_op0()
817 *inst++ = REX_W; in sljit_emit_op0()
818 *inst = CDQ; in sljit_emit_op0()
824 inst = (sljit_u8*)ensure_buf(compiler, 1 + 2); in sljit_emit_op0()
825 FAIL_IF(!inst); in sljit_emit_op0()
827 *inst++ = GROUP_F7; in sljit_emit_op0()
828 *inst = MOD_REG | ((op >= SLJIT_DIVMOD_UW) ? reg_map[TMP_REG1] : reg_map[SLJIT_R1]); in sljit_emit_op0()
835 inst = (sljit_u8*)ensure_buf(compiler, 1 + size); in sljit_emit_op0()
836 FAIL_IF(!inst); in sljit_emit_op0()
840 *inst++ = REX_W | ((op >= SLJIT_DIVMOD_UW) ? REX_B : 0); in sljit_emit_op0()
842 *inst++ = REX_B; in sljit_emit_op0()
843 *inst++ = GROUP_F7; in sljit_emit_op0()
844 *inst = MOD_REG | ((op >= SLJIT_DIVMOD_UW) ? reg_lmap[TMP_REG1] : reg_lmap[SLJIT_R1]); in sljit_emit_op0()
847 *inst++ = REX_W; in sljit_emit_op0()
848 *inst++ = GROUP_F7; in sljit_emit_op0()
849 *inst = MOD_REG | reg_map[SLJIT_R1]; in sljit_emit_op0()
854 *inst |= MUL; in sljit_emit_op0()
857 *inst |= IMUL; in sljit_emit_op0()
861 *inst |= DIV; in sljit_emit_op0()
865 *inst |= IDIV; in sljit_emit_op0()
883 inst = (sljit_u8*)ensure_buf(compiler, 1 + 1); \
884 FAIL_IF(!inst); \
886 *inst = (prefix); \
893 sljit_u8* inst; in emit_mov_byte() local
908 inst = emit_x86_instruction(compiler, 1, SLJIT_IMM, srcw, dst, 0); in emit_mov_byte()
909 FAIL_IF(!inst); in emit_mov_byte()
910 *inst = MOV_rm_i32; in emit_mov_byte()
914inst = emit_x86_instruction(compiler, 1 | EX86_BYTE_ARG | EX86_NO_REXW, SLJIT_IMM, srcw, dst, dstw… in emit_mov_byte()
915 FAIL_IF(!inst); in emit_mov_byte()
916 *inst = MOV_rm8_i8; in emit_mov_byte()
940 inst = emit_x86_instruction(compiler, 2, dst, 0, dst, 0); in emit_mov_byte()
941 FAIL_IF(!inst); in emit_mov_byte()
942 *inst++ = GROUP_0F; in emit_mov_byte()
943 *inst = sign ? MOVSX_r_rm8 : MOVZX_r_rm8; in emit_mov_byte()
950 inst = emit_x86_instruction(compiler, 1 | EX86_SHIFT_INS, SLJIT_IMM, 24, dst, 0); in emit_mov_byte()
951 FAIL_IF(!inst); in emit_mov_byte()
952 *inst |= SHL; in emit_mov_byte()
954 inst = emit_x86_instruction(compiler, 1 | EX86_SHIFT_INS, SLJIT_IMM, 24, dst, 0); in emit_mov_byte()
955 FAIL_IF(!inst); in emit_mov_byte()
956 *inst |= SAR; in emit_mov_byte()
959 inst = emit_x86_instruction(compiler, 1 | EX86_BIN_INS, SLJIT_IMM, 0xff, dst, 0); in emit_mov_byte()
960 FAIL_IF(!inst); in emit_mov_byte()
961 *(inst + 1) |= AND; in emit_mov_byte()
969 inst = emit_x86_instruction(compiler, 2, dst_r, 0, src, srcw); in emit_mov_byte()
970 FAIL_IF(!inst); in emit_mov_byte()
971 *inst++ = GROUP_0F; in emit_mov_byte()
972 *inst = sign ? MOVSX_r_rm8 : MOVZX_r_rm8; in emit_mov_byte()
998 inst = emit_x86_instruction(compiler, 1, work_r, 0, dst_r, 0); in emit_mov_byte()
999 FAIL_IF(!inst); in emit_mov_byte()
1000 *inst = XCHG_r_rm; in emit_mov_byte()
1003 inst = emit_x86_instruction(compiler, 1, work_r, 0, dst, dstw); in emit_mov_byte()
1004 FAIL_IF(!inst); in emit_mov_byte()
1005 *inst = MOV_rm8_r8; in emit_mov_byte()
1011 inst = emit_x86_instruction(compiler, 1, work_r, 0, dst_r, 0); in emit_mov_byte()
1012 FAIL_IF(!inst); in emit_mov_byte()
1013 *inst = XCHG_r_rm; in emit_mov_byte()
1017 inst = emit_x86_instruction(compiler, 1, dst_r, 0, dst, dstw); in emit_mov_byte()
1018 FAIL_IF(!inst); in emit_mov_byte()
1019 *inst = MOV_rm8_r8; in emit_mov_byte()
1022 inst = emit_x86_instruction(compiler, 1 | EX86_REX | EX86_NO_REXW, dst_r, 0, dst, dstw); in emit_mov_byte()
1023 FAIL_IF(!inst); in emit_mov_byte()
1024 *inst = MOV_rm8_r8; in emit_mov_byte()
1034 sljit_u8* inst; in emit_prefetch() local
1040 inst = emit_x86_instruction(compiler, 2, 0, 0, src, srcw); in emit_prefetch()
1041 FAIL_IF(!inst); in emit_prefetch()
1042 *inst++ = GROUP_0F; in emit_prefetch()
1043 *inst++ = PREFETCH; in emit_prefetch()
1046 *inst |= (3 << 3); in emit_prefetch()
1048 *inst |= (2 << 3); in emit_prefetch()
1050 *inst |= (1 << 3); in emit_prefetch()
1059 sljit_u8* inst; in emit_mov_half() local
1071 inst = emit_x86_instruction(compiler, 1, SLJIT_IMM, srcw, dst, 0); in emit_mov_half()
1072 FAIL_IF(!inst); in emit_mov_half()
1073 *inst = MOV_rm_i32; in emit_mov_half()
1077inst = emit_x86_instruction(compiler, 1 | EX86_HALF_ARG | EX86_NO_REXW | EX86_PREF_66, SLJIT_IMM, … in emit_mov_half()
1078 FAIL_IF(!inst); in emit_mov_half()
1079 *inst = MOV_rm_i32; in emit_mov_half()
1088 inst = emit_x86_instruction(compiler, 2, dst_r, 0, src, srcw); in emit_mov_half()
1089 FAIL_IF(!inst); in emit_mov_half()
1090 *inst++ = GROUP_0F; in emit_mov_half()
1091 *inst = sign ? MOVSX_r_rm16 : MOVZX_r_rm16; in emit_mov_half()
1095 inst = emit_x86_instruction(compiler, 1 | EX86_NO_REXW | EX86_PREF_66, dst_r, 0, dst, dstw); in emit_mov_half()
1096 FAIL_IF(!inst); in emit_mov_half()
1097 *inst = MOV_rm_r; in emit_mov_half()
1107 sljit_u8* inst; in emit_unary() local
1111 inst = emit_x86_instruction(compiler, 1, 0, 0, dst, dstw); in emit_unary()
1112 FAIL_IF(!inst); in emit_unary()
1113 *inst++ = GROUP_F7; in emit_unary()
1114 *inst |= opcode; in emit_unary()
1123 inst = emit_x86_instruction(compiler, 1, 0, 0, dst, 0); in emit_unary()
1124 FAIL_IF(!inst); in emit_unary()
1125 *inst++ = GROUP_F7; in emit_unary()
1126 *inst |= opcode; in emit_unary()
1131 inst = emit_x86_instruction(compiler, 1, 0, 0, TMP_REG1, 0); in emit_unary()
1132 FAIL_IF(!inst); in emit_unary()
1133 *inst++ = GROUP_F7; in emit_unary()
1134 *inst |= opcode; in emit_unary()
1143 sljit_u8* inst; in emit_not_with_flags() local
1150 inst = emit_x86_instruction(compiler, 1, 0, 0, dst, 0); in emit_not_with_flags()
1151 FAIL_IF(!inst); in emit_not_with_flags()
1152 *inst++ = GROUP_F7; in emit_not_with_flags()
1153 *inst |= NOT_rm; in emit_not_with_flags()
1154 inst = emit_x86_instruction(compiler, 1, dst, 0, dst, 0); in emit_not_with_flags()
1155 FAIL_IF(!inst); in emit_not_with_flags()
1156 *inst = OR_r_rm; in emit_not_with_flags()
1161 inst = emit_x86_instruction(compiler, 1, 0, 0, TMP_REG1, 0); in emit_not_with_flags()
1162 FAIL_IF(!inst); in emit_not_with_flags()
1163 *inst++ = GROUP_F7; in emit_not_with_flags()
1164 *inst |= NOT_rm; in emit_not_with_flags()
1165 inst = emit_x86_instruction(compiler, 1, TMP_REG1, 0, TMP_REG1, 0); in emit_not_with_flags()
1166 FAIL_IF(!inst); in emit_not_with_flags()
1167 *inst = OR_r_rm; in emit_not_with_flags()
1180 sljit_u8* inst; in emit_clz() local
1196 inst = emit_x86_instruction(compiler, 2, dst_r, 0, src, srcw); in emit_clz()
1197 FAIL_IF(!inst); in emit_clz()
1198 *inst++ = GROUP_0F; in emit_clz()
1199 *inst = BSR_r_rm; in emit_clz()
1205 inst = emit_x86_instruction(compiler, 2, dst_r, 0, TMP_REG1, 0); in emit_clz()
1208 inst = emit_x86_instruction(compiler, 2, dst_r, 0, SLJIT_MEM0(), (sljit_sw)&emit_clz_arg); in emit_clz()
1210 FAIL_IF(!inst); in emit_clz()
1211 *inst++ = GROUP_0F; in emit_clz()
1212 *inst = CMOVE_r_rm; in emit_clz()
1217 inst = emit_x86_instruction(compiler, 1 | EX86_BIN_INS, SLJIT_IMM, 31, dst_r, 0); in emit_clz()
1222 inst = emit_x86_instruction(compiler, 2, dst_r, 0, TMP_REG2, 0); in emit_clz()
1223 FAIL_IF(!inst); in emit_clz()
1224 *inst++ = GROUP_0F; in emit_clz()
1225 *inst = CMOVE_r_rm; in emit_clz()
1230inst = emit_x86_instruction(compiler, 1 | EX86_BIN_INS, SLJIT_IMM, !(op_flags & SLJIT_I32_OP) ? 63… in emit_clz()
1233 FAIL_IF(!inst); in emit_clz()
1234 *(inst + 1) |= XOR; in emit_clz()
1421 inst = emit_x86_instruction(compiler, 1 | EX86_BIN_INS, SLJIT_IMM, immw, arg, argw); \
1422 FAIL_IF(!inst); \
1423 *(inst + 1) |= (op_imm); \
1427 inst = emit_x86_instruction(compiler, 1, (arg == TMP_REG1) ? TMP_REG2 : TMP_REG1, 0, arg, argw); \
1428 FAIL_IF(!inst); \
1429 *inst = (op_mr); \
1438 inst = emit_x86_instruction(compiler, 1 | EX86_BIN_INS, SLJIT_IMM, immw, arg, argw); \
1439 FAIL_IF(!inst); \
1440 *(inst + 1) |= (op_imm);
1453 sljit_u8* inst; local
1461 inst = emit_x86_instruction(compiler, 1, TMP_REG1, 0, src2, src2w);
1462 FAIL_IF(!inst);
1463 *inst = op_rm;
1482 inst = emit_x86_instruction(compiler, 1, dst, dstw, src2, src2w);
1483 FAIL_IF(!inst);
1484 *inst = op_rm;
1488 inst = emit_x86_instruction(compiler, 1, src2, src2w, dst, dstw);
1489 FAIL_IF(!inst);
1490 *inst = op_mr;
1494 inst = emit_x86_instruction(compiler, 1, TMP_REG1, 0, dst, dstw);
1495 FAIL_IF(!inst);
1496 *inst = op_mr;
1516 inst = emit_x86_instruction(compiler, 1, dst, dstw, src1, src1w);
1517 FAIL_IF(!inst);
1518 *inst = op_rm;
1521 inst = emit_x86_instruction(compiler, 1, src1, src1w, dst, dstw);
1522 FAIL_IF(!inst);
1523 *inst = op_mr;
1527 inst = emit_x86_instruction(compiler, 1, TMP_REG1, 0, dst, dstw);
1528 FAIL_IF(!inst);
1529 *inst = op_mr;
1541 inst = emit_x86_instruction(compiler, 1, dst, 0, src2, src2w);
1542 FAIL_IF(!inst);
1543 *inst = op_rm;
1553 inst = emit_x86_instruction(compiler, 1, TMP_REG1, 0, src2, src2w);
1554 FAIL_IF(!inst);
1555 *inst = op_rm;
1569 sljit_u8* inst; local
1577 inst = emit_x86_instruction(compiler, 1, TMP_REG1, 0, src2, src2w);
1578 FAIL_IF(!inst);
1579 *inst = op_rm;
1598 inst = emit_x86_instruction(compiler, 1, dst, dstw, src2, src2w);
1599 FAIL_IF(!inst);
1600 *inst = op_rm;
1603 inst = emit_x86_instruction(compiler, 1, src2, src2w, dst, dstw);
1604 FAIL_IF(!inst);
1605 *inst = op_mr;
1609 inst = emit_x86_instruction(compiler, 1, TMP_REG1, 0, dst, dstw);
1610 FAIL_IF(!inst);
1611 *inst = op_mr;
1623 inst = emit_x86_instruction(compiler, 1, dst, 0, src2, src2w);
1624 FAIL_IF(!inst);
1625 *inst = op_rm;
1635 inst = emit_x86_instruction(compiler, 1, TMP_REG1, 0, src2, src2w);
1636 FAIL_IF(!inst);
1637 *inst = op_rm;
1650 sljit_u8* inst; local
1657 inst = emit_x86_instruction(compiler, 2, dst_r, 0, src2, src2w);
1658 FAIL_IF(!inst);
1659 *inst++ = GROUP_0F;
1660 *inst = IMUL_r_rm;
1663 inst = emit_x86_instruction(compiler, 2, dst_r, 0, src1, src1w);
1664 FAIL_IF(!inst);
1665 *inst++ = GROUP_0F;
1666 *inst = IMUL_r_rm;
1676 inst = emit_x86_instruction(compiler, 1, dst_r, 0, src2, src2w);
1677 FAIL_IF(!inst);
1678 *inst = IMUL_r_rm_i8;
1679 inst = (sljit_u8*)ensure_buf(compiler, 1 + 1);
1680 FAIL_IF(!inst);
1682 *inst = (sljit_s8)src1w;
1686 inst = emit_x86_instruction(compiler, 1, dst_r, 0, src2, src2w);
1687 FAIL_IF(!inst);
1688 *inst = IMUL_r_rm_i32;
1689 inst = (sljit_u8*)ensure_buf(compiler, 1 + 4);
1690 FAIL_IF(!inst);
1692 sljit_unaligned_store_sw(inst, src1w);
1696 inst = emit_x86_instruction(compiler, 1, dst_r, 0, src2, src2w);
1697 FAIL_IF(!inst);
1698 *inst = IMUL_r_rm_i32;
1699 inst = (sljit_u8*)ensure_buf(compiler, 1 + 4);
1700 FAIL_IF(!inst);
1702 sljit_unaligned_store_s32(inst, (sljit_s32)src1w);
1708 inst = emit_x86_instruction(compiler, 2, dst_r, 0, TMP_REG2, 0);
1709 FAIL_IF(!inst);
1710 *inst++ = GROUP_0F;
1711 *inst = IMUL_r_rm;
1719 inst = emit_x86_instruction(compiler, 1, dst_r, 0, src1, src1w);
1720 FAIL_IF(!inst);
1721 *inst = IMUL_r_rm_i8;
1722 inst = (sljit_u8*)ensure_buf(compiler, 1 + 1);
1723 FAIL_IF(!inst);
1725 *inst = (sljit_s8)src2w;
1729 inst = emit_x86_instruction(compiler, 1, dst_r, 0, src1, src1w);
1730 FAIL_IF(!inst);
1731 *inst = IMUL_r_rm_i32;
1732 inst = (sljit_u8*)ensure_buf(compiler, 1 + 4);
1733 FAIL_IF(!inst);
1735 sljit_unaligned_store_sw(inst, src2w);
1739 inst = emit_x86_instruction(compiler, 1, dst_r, 0, src1, src1w);
1740 FAIL_IF(!inst);
1741 *inst = IMUL_r_rm_i32;
1742 inst = (sljit_u8*)ensure_buf(compiler, 1 + 4);
1743 FAIL_IF(!inst);
1745 sljit_unaligned_store_s32(inst, (sljit_s32)src2w);
1751 inst = emit_x86_instruction(compiler, 2, dst_r, 0, TMP_REG2, 0);
1752 FAIL_IF(!inst);
1753 *inst++ = GROUP_0F;
1754 *inst = IMUL_r_rm;
1763 inst = emit_x86_instruction(compiler, 2, dst_r, 0, src2, src2w);
1764 FAIL_IF(!inst);
1765 *inst++ = GROUP_0F;
1766 *inst = IMUL_r_rm;
1780 sljit_u8* inst; local
1793 inst = emit_x86_instruction(compiler, 1, dst_r, 0, SLJIT_MEM2(src1, src2), 0);
1794 FAIL_IF(!inst);
1795 *inst = LEA_r_m;
1800 inst = emit_x86_instruction(compiler, 1, dst_r, 0, SLJIT_MEM1(src1), (sljit_s32)src2w);
1803 inst = emit_x86_instruction(compiler, 1, dst_r, 0, SLJIT_MEM1(src1), src2w);
1805 FAIL_IF(!inst);
1806 *inst = LEA_r_m;
1813 inst = emit_x86_instruction(compiler, 1, dst_r, 0, SLJIT_MEM1(src2), (sljit_s32)src1w);
1816 inst = emit_x86_instruction(compiler, 1, dst_r, 0, SLJIT_MEM1(src2), src1w);
1818 FAIL_IF(!inst);
1819 *inst = LEA_r_m;
1836 sljit_u8* inst; local
1852 inst = emit_x86_instruction(compiler, 1, src1, 0, src2, src2w);
1853 FAIL_IF(!inst);
1854 *inst = CMP_r_rm;
1860 inst = emit_x86_instruction(compiler, 1, src2, 0, src1, src1w);
1861 FAIL_IF(!inst);
1862 *inst = CMP_rm_r;
1876 inst = emit_x86_instruction(compiler, 1, TMP_REG1, 0, src2, src2w);
1877 FAIL_IF(!inst);
1878 *inst = CMP_r_rm;
1887 sljit_u8* inst; local
1911 inst = emit_x86_instruction(compiler, 1, SLJIT_IMM, src2w, src1, src1w);
1912 FAIL_IF(!inst);
1913 *inst = GROUP_F7;
1917 inst = emit_x86_instruction(compiler, 1, TMP_REG1, 0, src1, src1w);
1918 FAIL_IF(!inst);
1919 *inst = TEST_rm_r;
1922 inst = emit_x86_instruction(compiler, 1, SLJIT_IMM, src2w, src1, src1w);
1923 FAIL_IF(!inst);
1924 *inst = GROUP_F7;
1929 inst = emit_x86_instruction(compiler, 1, src1, 0, src2, src2w);
1930 FAIL_IF(!inst);
1931 *inst = TEST_rm_r;
1940 inst = emit_x86_instruction(compiler, 1, SLJIT_IMM, src1w, src2, src2w);
1941 FAIL_IF(!inst);
1942 *inst = GROUP_F7;
1946 inst = emit_x86_instruction(compiler, 1, TMP_REG1, 0, src2, src2w);
1947 FAIL_IF(!inst);
1948 *inst = TEST_rm_r;
1951 inst = emit_x86_instruction(compiler, 1, src1, src1w, src2, src2w);
1952 FAIL_IF(!inst);
1953 *inst = GROUP_F7;
1958 inst = emit_x86_instruction(compiler, 1, src2, 0, src1, src1w);
1959 FAIL_IF(!inst);
1960 *inst = TEST_rm_r;
1969 inst = emit_x86_instruction(compiler, 1, SLJIT_IMM, src2w, TMP_REG1, 0);
1970 FAIL_IF(!inst);
1971 *inst = GROUP_F7;
1975 inst = emit_x86_instruction(compiler, 1, TMP_REG2, 0, TMP_REG1, 0);
1976 FAIL_IF(!inst);
1977 *inst = TEST_rm_r;
1980 inst = emit_x86_instruction(compiler, 1, SLJIT_IMM, src2w, TMP_REG1, 0);
1981 FAIL_IF(!inst);
1982 *inst = GROUP_F7;
1986 inst = emit_x86_instruction(compiler, 1, TMP_REG1, 0, src2, src2w);
1987 FAIL_IF(!inst);
1988 *inst = TEST_rm_r;
1999 sljit_u8* inst; local
2003 inst = emit_x86_instruction(compiler, 1 | EX86_SHIFT_INS, src2, src2w, dst, dstw);
2004 FAIL_IF(!inst);
2005 *inst |= mode;
2010 inst = emit_x86_instruction(compiler, 1 | EX86_SHIFT_INS, src2, src2w, TMP_REG1, 0);
2011 FAIL_IF(!inst);
2012 *inst |= mode;
2017 inst = emit_x86_instruction(compiler, 1 | EX86_SHIFT_INS, SLJIT_PREF_SHIFT_REG, 0, TMP_REG1, 0);
2018 FAIL_IF(!inst);
2019 *inst |= mode;
2025 inst = emit_x86_instruction(compiler, 1 | EX86_SHIFT_INS, src2, src2w, dst, 0);
2026 FAIL_IF(!inst);
2027 *inst |= mode;
2032 inst = emit_x86_instruction(compiler, 1 | EX86_SHIFT_INS, src2, src2w, TMP_REG1, 0);
2033 FAIL_IF(!inst);
2034 *inst |= mode;
2042 inst = emit_x86_instruction(compiler, 1 | EX86_SHIFT_INS, SLJIT_PREF_SHIFT_REG, 0, TMP_REG1, 0);
2043 FAIL_IF(!inst);
2044 *inst |= mode;
2052 inst = emit_x86_instruction(compiler, 1 | EX86_SHIFT_INS, SLJIT_PREF_SHIFT_REG, 0, dst, 0);
2053 FAIL_IF(!inst);
2054 *inst |= mode;
2064 inst = emit_x86_instruction(compiler, 1 | EX86_SHIFT_INS, SLJIT_PREF_SHIFT_REG, 0, TMP_REG1, 0);
2065 FAIL_IF(!inst);
2066 *inst |= mode;
2072 inst = emit_x86_instruction(compiler, 1, TMP_REG2, 0, SLJIT_PREF_SHIFT_REG, 0);
2073 FAIL_IF(!inst);
2074 *inst = XCHG_r_rm;
2075 inst = emit_x86_instruction(compiler, 1 | EX86_SHIFT_INS, SLJIT_PREF_SHIFT_REG, 0, TMP_REG1, 0);
2076 FAIL_IF(!inst);
2077 *inst |= mode;
2212 sljit_u8 *inst; local
2217 inst = (sljit_u8*)ensure_buf(compiler, 1 + size);
2218 FAIL_IF(!inst);
2220 SLJIT_MEMCPY(inst, instruction, size);
2250 sljit_u8 *inst; local
2252inst = emit_x86_instruction(compiler, 2 | (single ? EX86_PREF_F3 : EX86_PREF_F2) | EX86_SSE2, xmm1…
2253 FAIL_IF(!inst);
2254 *inst++ = GROUP_0F;
2255 *inst = opcode;
2262 sljit_u8 *inst; local
2264inst = emit_x86_instruction(compiler, 2 | (pref66 ? EX86_PREF_66 : 0) | EX86_SSE2, xmm1, 0, xmm2, …
2265 FAIL_IF(!inst);
2266 *inst++ = GROUP_0F;
2267 *inst = opcode;
2288 sljit_u8 *inst; local
2295inst = emit_x86_instruction(compiler, 2 | ((op & SLJIT_F32_OP) ? EX86_PREF_F3 : EX86_PREF_F2) | EX…
2296 FAIL_IF(!inst);
2297 *inst++ = GROUP_0F;
2298 *inst = CVTTSD2SI_r_xm;
2310 sljit_u8 *inst; local
2327inst = emit_x86_instruction(compiler, 2 | ((op & SLJIT_F32_OP) ? EX86_PREF_F3 : EX86_PREF_F2) | EX…
2328 FAIL_IF(!inst);
2329 *inst++ = GROUP_0F;
2330 *inst = CVTSI2SD_x_rm;
2484 sljit_u8 *inst; local
2497 inst = (sljit_u8*)ensure_buf(compiler, 2);
2498 PTR_FAIL_IF(!inst);
2500 *inst++ = 0;
2501 *inst++ = 0;
2508 sljit_u8 *inst; local
2529 inst = (sljit_u8*)ensure_buf(compiler, 2);
2530 PTR_FAIL_IF_NULL(inst);
2532 *inst++ = 0;
2533 *inst++ = type + 2;
2547 sljit_u8 *inst; local
2588 inst = (sljit_u8*)ensure_buf(compiler, 2);
2589 FAIL_IF_NULL(inst);
2591 *inst++ = 0;
2592 *inst++ = type + 2;
2599 inst = emit_x86_instruction(compiler, 1, 0, 0, src, srcw);
2600 FAIL_IF(!inst);
2601 *inst++ = GROUP_FF;
2602 *inst |= (type >= SLJIT_FAST_CALL) ? CALL_rm : JMP_rm;
2611 sljit_u8 *inst; local
2632 inst = (sljit_u8*)ensure_buf(compiler, 1 + 4 + 3);
2633 FAIL_IF(!inst);
2636 *inst++ = (reg_map[TMP_REG1] <= 7) ? REX : REX_B;
2637 *inst++ = GROUP_0F;
2638 *inst++ = cond_set;
2639 *inst++ = MOD_REG | reg_lmap[TMP_REG1];
2640 *inst++ = REX | (reg_map[TMP_REG1] <= 7 ? 0 : REX_R) | (reg_map[dst] <= 7 ? 0 : REX_B);
2641 *inst++ = OR_rm8_r8;
2642 *inst++ = MOD_REG | (reg_lmap[TMP_REG1] << 3) | reg_lmap[dst];
2648 inst = (sljit_u8*)ensure_buf(compiler, 1 + 4 + 4);
2649 FAIL_IF(!inst);
2652 *inst++ = (reg_map[reg] <= 7) ? REX : REX_B;
2653 *inst++ = GROUP_0F;
2654 *inst++ = cond_set;
2655 *inst++ = MOD_REG | reg_lmap[reg];
2656 *inst++ = REX_W | (reg_map[reg] <= 7 ? 0 : (REX_B | REX_R));
2658 *inst++ = GROUP_0F;
2659 *inst++ = MOVZX_r_rm8;
2660 *inst = MOD_REG | (reg_lmap[reg] << 3) | reg_lmap[reg];
2681 inst = (sljit_u8*)ensure_buf(compiler, 1 + 3 + 3);
2682 FAIL_IF(!inst);
2685 *inst++ = GROUP_0F;
2686 *inst++ = cond_set;
2687 *inst++ = MOD_REG | reg_map[dst];
2689 *inst++ = GROUP_0F;
2690 *inst++ = MOVZX_r_rm8;
2691 *inst = MOD_REG | (reg_map[dst] << 3) | reg_map[dst];
2704 inst = (sljit_u8*)ensure_buf(compiler, 1 + 3);
2705 FAIL_IF(!inst);
2708 *inst++ = GROUP_0F;
2710 *inst++ = cond_set - 0x50;
2711 *inst++ = MOD_REG | (reg_map[dst] << 3) | reg_map[TMP_REG1];
2715 inst = (sljit_u8*)ensure_buf(compiler, 1 + 1 + 3 + 3 + 1);
2716 FAIL_IF(!inst);
2718 *inst++ = XCHG_EAX_r + reg_map[TMP_REG1];
2720 *inst++ = GROUP_0F;
2721 *inst++ = cond_set;
2722 *inst++ = MOD_REG | 0 /* eax */;
2724 *inst++ = GROUP_0F;
2725 *inst++ = MOVZX_r_rm8;
2726 *inst++ = MOD_REG | (reg_map[dst] << 3) | 0 /* eax */;
2727 *inst++ = XCHG_EAX_r + reg_map[TMP_REG1];
2735 inst = (sljit_u8*)ensure_buf(compiler, 1 + 1 + 3 + 2 + 1);
2736 FAIL_IF(!inst);
2739 *inst++ = XCHG_EAX_r + reg_map[TMP_REG1];
2740 *inst++ = GROUP_0F;
2741 *inst++ = cond_set;
2742 *inst++ = MOD_REG | 0 /* eax */;
2743 *inst++ = OR_rm8_r8;
2744 *inst++ = MOD_REG | (0 /* eax */ << 3) | reg_map[dst];
2745 *inst++ = XCHG_EAX_r + reg_map[TMP_REG1];
2748 inst = (sljit_u8*)ensure_buf(compiler, 1 + 2 + 3 + 2 + 2);
2749 FAIL_IF(!inst);
2752 *inst++ = XCHG_r_rm;
2753 *inst++ = MOD_REG | (1 /* ecx */ << 3) | reg_map[TMP_REG1];
2754 *inst++ = GROUP_0F;
2755 *inst++ = cond_set;
2756 *inst++ = MOD_REG | 1 /* ecx */;
2757 *inst++ = OR_rm8_r8;
2758 *inst++ = MOD_REG | (1 /* ecx */ << 3) | 0 /* eax */;
2759 *inst++ = XCHG_r_rm;
2760 *inst++ = MOD_REG | (1 /* ecx */ << 3) | reg_map[TMP_REG1];
2766 inst = (sljit_u8*)ensure_buf(compiler, 1 + 1 + 3 + 3 + 1);
2767 FAIL_IF(!inst);
2769 *inst++ = XCHG_EAX_r + reg_map[TMP_REG1];
2771 *inst++ = GROUP_0F;
2772 *inst++ = cond_set;
2773 *inst++ = MOD_REG | 0 /* eax */;
2775 *inst++ = GROUP_0F;
2776 *inst++ = MOVZX_r_rm8;
2777 *inst++ = MOD_REG | (0 << 3) /* eax */ | 0 /* eax */;
2779 *inst++ = XCHG_EAX_r + reg_map[TMP_REG1];
2796 sljit_u8* inst; local
2825 inst = emit_x86_instruction(compiler, 2, dst_reg, 0, src, srcw);
2826 FAIL_IF(!inst);
2827 *inst++ = GROUP_0F;
2828 *inst = get_jump_code(type & 0xff) - 0x40;
2865 sljit_u8 *inst; local
2892 inst = (sljit_u8*)ensure_buf(compiler, 2);
2893 PTR_FAIL_IF(!inst);
2895 *inst++ = 0;
2896 *inst++ = 1;