Lines Matching refs:op
430 #define SLJIT_S390X_INSTRUCTION(op, ...) \ argument
431 static SLJIT_INLINE sljit_ins op(__VA_ARGS__)
831 static sljit_s32 update_zero_overflow(struct sljit_compiler *compiler, sljit_s32 op, sljit_gpr dst_… in update_zero_overflow() argument
839 FAIL_IF(push_inst(compiler, brc(0xc, 2 + 2 + ((op & SLJIT_32) ? 1 : 2) + 2 + 3 + 1))); in update_zero_overflow()
841 FAIL_IF(push_inst(compiler, (op & SLJIT_32) ? or(dst_r, dst_r) : ogr(dst_r, dst_r))); in update_zero_overflow()
952 #define EVAL(op, r, addr) op(r, addr.offset, addr.index, addr.base) argument
1267 sljit_ins op; member
1284 ins12 = forms->op; in emit_commutative()
1367 ins12 = forms->op; in emit_non_commutative()
1882 SLJIT_API_FUNC_ATTRIBUTE sljit_s32 sljit_emit_op0(struct sljit_compiler *compiler, sljit_s32 op) in sljit_emit_op0() argument
1888 CHECK(check_sljit_emit_op0(compiler, op)); in sljit_emit_op0()
1890 op = GET_OPCODE(op) | (op & SLJIT_32); in sljit_emit_op0()
1891 switch (op) { in sljit_emit_op0()
1920 if (op == SLJIT_DIVMOD_U32) in sljit_emit_op0()
1930 if (op == SLJIT_DIVMOD_S32) in sljit_emit_op0()
1940 if (op == SLJIT_DIVMOD_UW) in sljit_emit_op0()
1949 if (op == SLJIT_DIVMOD_SW) in sljit_emit_op0()
1966 static sljit_s32 sljit_emit_clz_ctz(struct sljit_compiler *compiler, sljit_s32 op, sljit_gpr dst_r,… in sljit_emit_clz_ctz() argument
1968 sljit_s32 is_ctz = (GET_OPCODE(op) == SLJIT_CTZ); in sljit_emit_clz_ctz()
1970 if ((op & SLJIT_32) && src_r != tmp0) { in sljit_emit_clz_ctz()
1976 …FAIL_IF(push_inst(compiler, ((op & SLJIT_32) ? 0x1300 /* lcr */ : 0xb9030000 /* lcgr */) | R4A(tmp… in sljit_emit_clz_ctz()
1979 …FAIL_IF(push_inst(compiler, ((op & SLJIT_32) ? 0x1400 /* nr */ : 0xb9800000 /* ngr */) | R4A(tmp0)… in sljit_emit_clz_ctz()
1991 if (op & SLJIT_32) { in sljit_emit_clz_ctz()
1999 …/ | R36A(tmp0) | R32A(tmp1) | ((sljit_ins)((op & SLJIT_32) ? 59 : 58) << 24) | (63 << 16) | ((slji… in sljit_emit_clz_ctz()
2004 …return push_inst(compiler, ((op & SLJIT_32) ? 0x1800 /* lr */ : 0xb9040000 /* lgr */) | R4A(dst_r)… in sljit_emit_clz_ctz()
2007 static sljit_s32 sljit_emit_rev(struct sljit_compiler *compiler, sljit_s32 op, in sljit_emit_rev() argument
2014 sljit_s32 opcode = GET_OPCODE(op); in sljit_emit_rev()
2019 …FAIL_IF(load_store_op(compiler, tmp0, src, srcw, op & SLJIT_32, is_16bit ? load_halfword_forms : l… in sljit_emit_rev()
2029 ins = (op & SLJIT_32) ? 0xe3000000003e /* strv */ : 0xe3000000002f /* strvg */; in sljit_emit_rev()
2042 ins = (op & SLJIT_32) ? 0xe3000000001e /* lrv */ : 0xe3000000000f /* lrvg */; in sljit_emit_rev()
2050 if (op & SLJIT_32) in sljit_emit_rev()
2060 ins = (op & SLJIT_32) ? 0xb91f0000 /* lrvr */ : 0xb90f0000 /* lrvgr */; in sljit_emit_rev()
2071 if (op & SLJIT_32) { in sljit_emit_rev()
2083 SLJIT_API_FUNC_ATTRIBUTE sljit_s32 sljit_emit_op1(struct sljit_compiler *compiler, sljit_s32 op, in sljit_emit_op1() argument
2091 sljit_s32 opcode = GET_OPCODE(op); in sljit_emit_op1()
2094 CHECK(check_sljit_emit_op1(compiler, op, dst, dstw, src, srcw)); in sljit_emit_op1()
2103 switch (opcode | (op & SLJIT_32)) { in sljit_emit_op1()
2188 switch (opcode | (op & SLJIT_32)) { in sljit_emit_op1()
2314 compiler->status_flags_state = op & (VARIABLE_FLAG_MASK | SLJIT_SET_Z); in sljit_emit_op1()
2321 FAIL_IF(load_unsigned_word(compiler, src_r, src, srcw, op & SLJIT_32)); in sljit_emit_op1()
2323 FAIL_IF(sljit_emit_clz_ctz(compiler, op, dst_r, src_r)); in sljit_emit_op1()
2327 op |= SLJIT_32; in sljit_emit_op1()
2332 return sljit_emit_rev(compiler, op, dst, dstw, src, srcw); in sljit_emit_op1()
2338 return store_word(compiler, dst_r, dst, dstw, op & SLJIT_32); in sljit_emit_op1()
2343 static SLJIT_INLINE int is_commutative(sljit_s32 op) in is_commutative() argument
2345 switch (GET_OPCODE(op)) { in is_commutative()
2377 static sljit_s32 sljit_emit_add(struct sljit_compiler *compiler, sljit_s32 op, in sljit_emit_add() argument
2382 int sets_overflow = (op & VARIABLE_FLAG_MASK) == SLJIT_SET_OVERFLOW; in sljit_emit_add()
2383 …int sets_zero_overflow = (op & (SLJIT_SET_Z | VARIABLE_FLAG_MASK)) == (SLJIT_SET_Z | SLJIT_SET_OVE… in sljit_emit_add()
2390 ins = (op & SLJIT_32) ? 0xeb000000006a /* asi */ : 0xeb000000007a /* agsi */; in sljit_emit_add()
2392 ins = (op & SLJIT_32) ? 0xeb000000006e /* alsi */ : 0xeb000000007e /* algsi */; in sljit_emit_add()
2398 ins = (op & SLJIT_32) ? 0xec00000000d8 /* ahik */ : 0xec00000000d9 /* aghik */; in sljit_emit_add()
2400 ins = (op & SLJIT_32) ? 0xec00000000da /* alhsik */ : 0xec00000000db /* alghsik */; in sljit_emit_add()
2406 if ((op & SLJIT_32) || is_u32(src2w)) { in sljit_emit_add()
2407 ins = (op & SLJIT_32) ? 0xc20b00000000 /* alfi */ : 0xc20a00000000 /* algfi */; in sljit_emit_add()
2416 else if ((op & SLJIT_32) || is_s32(src2w)) { in sljit_emit_add()
2417 ins = (op & SLJIT_32) ? 0xc20900000000 /* afi */ : 0xc20800000000 /* agfi */; in sljit_emit_add()
2428 FAIL_IF(update_zero_overflow(compiler, op, FAST_IS_REG(dst) ? gpr(dst & REG_MASK) : tmp0)); in sljit_emit_add()
2431 return store_word(compiler, tmp0, dst, dstw, op & SLJIT_32); in sljit_emit_add()
2456 static sljit_s32 sljit_emit_sub(struct sljit_compiler *compiler, sljit_s32 op, in sljit_emit_sub() argument
2461 sljit_s32 flag_type = GET_FLAG_TYPE(op); in sljit_emit_sub()
2463 …int sets_zero_overflow = (op & (SLJIT_SET_Z | VARIABLE_FLAG_MASK)) == (SLJIT_SET_Z | SLJIT_SET_OVE… in sljit_emit_sub()
2473 if (compare_signed || ((op & VARIABLE_FLAG_MASK) == 0 && is_s32(src2w))) { in sljit_emit_sub()
2474 if ((op & SLJIT_32) || is_s32(src2w)) { in sljit_emit_sub()
2475 ins = (op & SLJIT_32) ? 0xc20d00000000 /* cfi */ : 0xc20c00000000 /* cgfi */; in sljit_emit_sub()
2480 if ((op & SLJIT_32) || is_u32(src2w)) { in sljit_emit_sub()
2481 ins = (op & SLJIT_32) ? 0xc20f00000000 /* clfi */ : 0xc20e00000000 /* clgfi */; in sljit_emit_sub()
2489 if ((op & SLJIT_32) && ((src2 & OFFS_REG_MASK) || is_u12(src2w))) { in sljit_emit_sub()
2495 ins = (op & SLJIT_32) ? 0xe30000000059 /* cy */ : 0xe30000000020 /* cg */; in sljit_emit_sub()
2497 ins = (op & SLJIT_32) ? 0xe30000000055 /* cly */ : 0xe30000000021 /* clg */; in sljit_emit_sub()
2502 ins = (op & SLJIT_32) ? 0x1900 /* cr */ : 0xb9200000 /* cgr */; in sljit_emit_sub()
2504 ins = (op & SLJIT_32) ? 0x1500 /* clr */ : 0xb9210000 /* clgr */; in sljit_emit_sub()
2509 ins = (op & SLJIT_32) ? 0x1300 /* lcr */ : 0xb9030000 /* lcgr */; in sljit_emit_sub()
2517 if (sets_signed || neg_src2w != 0 || (op & (SLJIT_SET_Z | VARIABLE_FLAG_MASK)) == 0) { in sljit_emit_sub()
2520 ins = (op & SLJIT_32) ? 0xeb000000006a /* asi */ : 0xeb000000007a /* agsi */; in sljit_emit_sub()
2522 ins = (op & SLJIT_32) ? 0xeb000000006e /* alsi */ : 0xeb000000007e /* algsi */; in sljit_emit_sub()
2528 ins = (op & SLJIT_32) ? 0xec00000000d8 /* ahik */ : 0xec00000000d9 /* aghik */; in sljit_emit_sub()
2530 ins = (op & SLJIT_32) ? 0xec00000000da /* alhsik */ : 0xec00000000db /* alghsik */; in sljit_emit_sub()
2537 if ((op & SLJIT_32) || is_u32(src2w)) { in sljit_emit_sub()
2538 ins = (op & SLJIT_32) ? 0xc20500000000 /* slfi */ : 0xc20400000000 /* slgfi */; in sljit_emit_sub()
2547 else if ((op & SLJIT_32) || is_s32(neg_src2w)) { in sljit_emit_sub()
2548 ins = (op & SLJIT_32) ? 0xc20900000000 /* afi */ : 0xc20800000000 /* agfi */; in sljit_emit_sub()
2561 if ((op & VARIABLE_FLAG_MASK) != SLJIT_SET_OVERFLOW) { in sljit_emit_sub()
2567 FAIL_IF(push_inst(compiler, brc(0xe, (op & SLJIT_32) ? (2 + 1) : (2 + 2)))); in sljit_emit_sub()
2568 FAIL_IF(push_inst(compiler, (op & SLJIT_32) ? lcr(tmp1, dst_r) : lcgr(tmp1, dst_r))); in sljit_emit_sub()
2570 else if (op & SLJIT_SET_Z) in sljit_emit_sub()
2571 FAIL_IF(update_zero_overflow(compiler, op, dst_r)); in sljit_emit_sub()
2575 return store_word(compiler, tmp0, dst, dstw, op & SLJIT_32); in sljit_emit_sub()
2600 static sljit_s32 sljit_emit_multiply(struct sljit_compiler *compiler, sljit_s32 op, in sljit_emit_multiply() argument
2607 if (HAS_FLAGS(op)) { in sljit_emit_multiply()
2624 ins = (op & SLJIT_32) ? 0xa70c0000 /* mhi */ : 0xa70d0000 /* mghi */; in sljit_emit_multiply()
2629 ins = (op & SLJIT_32) ? 0xc20100000000 /* msfi */ : 0xc20000000000 /* msgfi */; in sljit_emit_multiply()
2721 static sljit_s32 sljit_emit_bitwise(struct sljit_compiler *compiler, sljit_s32 op, in sljit_emit_bitwise() argument
2726 sljit_s32 type = GET_OPCODE(op); in sljit_emit_bitwise()
2729 if (src2 == SLJIT_IMM && (!(op & SLJIT_SET_Z) || (type == SLJIT_AND && dst == TMP_REG2))) { in sljit_emit_bitwise()
2733 if (op & SLJIT_32) in sljit_emit_bitwise()
2762 if (!(op & SLJIT_SET_Z)) in sljit_emit_bitwise()
2776 static sljit_s32 sljit_emit_shift(struct sljit_compiler *compiler, sljit_s32 op, in sljit_emit_shift() argument
2781 sljit_s32 type = GET_OPCODE(op); in sljit_emit_shift()
2801 if ((op & SLJIT_32) && (type == SLJIT_MSHL || type == SLJIT_MLSHR || type == SLJIT_MASHR)) { in sljit_emit_shift()
2809 imm = (sljit_ins)(src2w & ((op & SLJIT_32) ? 0x1f : 0x3f)); in sljit_emit_shift()
2811 if ((op & SLJIT_32) && dst_r == src_r) { in sljit_emit_shift()
2822 ins = (op & SLJIT_32) ? 0xeb00000000df /* sllk */ : 0xeb000000000d /* sllg */; in sljit_emit_shift()
2824 ins = (op & SLJIT_32) ? 0xeb00000000de /* srlk */ : 0xeb000000000c /* srlg */; in sljit_emit_shift()
2826 ins = (op & SLJIT_32) ? 0xeb00000000dc /* srak */ : 0xeb000000000a /* srag */; in sljit_emit_shift()
2831 if ((op & SLJIT_SET_Z) && type != SLJIT_ASHR) in sljit_emit_shift()
2832 return push_inst(compiler, (op & SLJIT_32) ? or(dst_r, dst_r) : ogr(dst_r, dst_r)); in sljit_emit_shift()
2837 static sljit_s32 sljit_emit_rotate(struct sljit_compiler *compiler, sljit_s32 op, in sljit_emit_rotate() argument
2862 if (GET_OPCODE(op) == SLJIT_ROTR) { in sljit_emit_rotate()
2864 ins = (op & SLJIT_32) ? 0x1300 /* lcr */ : 0xb9030000 /* lcgr */; in sljit_emit_rotate()
2872 imm = (sljit_ins)(src2w & ((op & SLJIT_32) ? 0x1f : 0x3f)); in sljit_emit_rotate()
2874 ins = (op & SLJIT_32) ? 0xeb000000001d /* rll */ : 0xeb000000001c /* rllg */; in sljit_emit_rotate()
2898 SLJIT_API_FUNC_ATTRIBUTE sljit_s32 sljit_emit_op2(struct sljit_compiler *compiler, sljit_s32 op, in sljit_emit_op2() argument
2904 CHECK(check_sljit_emit_op2(compiler, op, 0, dst, dstw, src1, src1w, src2, src2w)); in sljit_emit_op2()
2909 compiler->mode = op & SLJIT_32; in sljit_emit_op2()
2910 compiler->status_flags_state = op & (VARIABLE_FLAG_MASK | SLJIT_SET_Z); in sljit_emit_op2()
2912 if (is_commutative(op) && src1 == SLJIT_IMM && src2 != SLJIT_IMM) { in sljit_emit_op2()
2922 switch (GET_OPCODE(op)) { in sljit_emit_op2()
2925 return sljit_emit_add(compiler, op, dst, dstw, src1, src1w, src2, src2w); in sljit_emit_op2()
2930 return store_word(compiler, tmp0, dst, dstw, op & SLJIT_32); in sljit_emit_op2()
2934 return sljit_emit_sub(compiler, op, dst, dstw, src1, src1w, src2, src2w); in sljit_emit_op2()
2939 return store_word(compiler, tmp0, dst, dstw, op & SLJIT_32); in sljit_emit_op2()
2942 FAIL_IF(sljit_emit_multiply(compiler, op, dst, src1, src1w, src2, src2w)); in sljit_emit_op2()
2947 FAIL_IF(sljit_emit_bitwise(compiler, op, dst, src1, src1w, src2, src2w)); in sljit_emit_op2()
2955 FAIL_IF(sljit_emit_shift(compiler, op, dst, src1, src1w, src2, src2w)); in sljit_emit_op2()
2959 FAIL_IF(sljit_emit_rotate(compiler, op, dst, src1, src1w, src2, src2w)); in sljit_emit_op2()
2964 return store_word(compiler, tmp0, dst, dstw, op & SLJIT_32); in sljit_emit_op2()
2968 SLJIT_API_FUNC_ATTRIBUTE sljit_s32 sljit_emit_op2u(struct sljit_compiler *compiler, sljit_s32 op, in sljit_emit_op2u() argument
2972 …sljit_s32 dst_reg = (GET_OPCODE(op) == SLJIT_SUB || GET_OPCODE(op) == SLJIT_AND) ? TMP_REG2 : TMP_… in sljit_emit_op2u()
2975 CHECK(check_sljit_emit_op2(compiler, op, 1, 0, 0, src1, src1w, src2, src2w)); in sljit_emit_op2u()
2978 return sljit_emit_op2(compiler, op, dst_reg, 0, src1, src1w, src2, src2w); in sljit_emit_op2u()
2981 SLJIT_API_FUNC_ATTRIBUTE sljit_s32 sljit_emit_op2r(struct sljit_compiler *compiler, sljit_s32 op, in sljit_emit_op2r() argument
2987 CHECK(check_sljit_emit_op2r(compiler, op, dst_reg, src1, src1w, src2, src2w)); in sljit_emit_op2r()
2989 switch (GET_OPCODE(op)) { in sljit_emit_op2r()
2992 …FAIL_IF(sljit_emit_op2(compiler, SLJIT_MUL | (op & SLJIT_32), 0 /* tmp0 */, 0, src1, src1w, src2, … in sljit_emit_op2r()
2993 …return push_inst(compiler, ((op & SLJIT_32) ? 0x1a00 /* ar */ : 0xb9080000 /* agr */) | R4A(gpr(ds… in sljit_emit_op2r()
2999 …T_API_FUNC_ATTRIBUTE sljit_s32 sljit_emit_shift_into(struct sljit_compiler *compiler, sljit_s32 op, in sljit_emit_shift_into() argument
3006 sljit_sw bit_length = (op & SLJIT_32) ? 32 : 64; in sljit_emit_shift_into()
3014 CHECK(check_sljit_emit_shift_into(compiler, op, dst_reg, src1_reg, src2_reg, src3, src3w)); in sljit_emit_shift_into()
3016 is_right = (GET_OPCODE(op) == SLJIT_LSHR || GET_OPCODE(op) == SLJIT_MLSHR); in sljit_emit_shift_into()
3020 …return sljit_emit_op2(compiler, (is_right ? SLJIT_ROTR : SLJIT_ROTL) | (op & SLJIT_32), dst_reg, 0… in sljit_emit_shift_into()
3031 if (op & SLJIT_32) { in sljit_emit_shift_into()
3063 FAIL_IF(load_word(compiler, tmp1, src3, src3w, op & SLJIT_32)); in sljit_emit_shift_into()
3065 if (op & SLJIT_32) { in sljit_emit_shift_into()
3066 if (GET_OPCODE(op) == SLJIT_MSHL || GET_OPCODE(op) == SLJIT_MLSHR) { in sljit_emit_shift_into()
3099 if (!(op & SLJIT_SHIFT_INTO_NON_ZERO)) { in sljit_emit_shift_into()
3117 SLJIT_API_FUNC_ATTRIBUTE sljit_s32 sljit_emit_op_src(struct sljit_compiler *compiler, sljit_s32 op, in sljit_emit_op_src() argument
3124 CHECK(check_sljit_emit_op_src(compiler, op, src, srcw)); in sljit_emit_op_src()
3127 switch (op) { in sljit_emit_op_src()
3149 SLJIT_API_FUNC_ATTRIBUTE sljit_s32 sljit_emit_op_dst(struct sljit_compiler *compiler, sljit_s32 op, in sljit_emit_op_dst() argument
3156 CHECK(check_sljit_emit_op_dst(compiler, op, dst, dstw)); in sljit_emit_op_dst()
3159 switch (op) { in sljit_emit_op_dst()
3210 static sljit_s32 float_mem(struct sljit_compiler *compiler, sljit_s32 op, in float_mem() argument
3222 if (op & FLOAT_STORE) in float_mem()
3223 ins = (op & SLJIT_32) ? 0x70000000 /* ste */ : 0x60000000 /* std */; in float_mem()
3225 ins = (op & SLJIT_32) ? 0x78000000 /* le */ : 0x68000000 /* ld */; in float_mem()
3232 if (op & FLOAT_STORE) in float_mem()
3233 ins = (op & SLJIT_32) ? 0xed0000000066 /* stey */ : 0xed0000000067 /* stdy */; in float_mem()
3235 ins = (op & SLJIT_32) ? 0xed0000000064 /* ley */ : 0xed0000000065 /* ldy */; in float_mem()
3253 …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
3261 FAIL_IF(float_mem(compiler, FLOAT_LOAD | (op & SLJIT_32), TMP_FREG1, src, srcw)); in sljit_emit_fop1_conv_sw_from_f64()
3266 if (GET_OPCODE(op) == SLJIT_CONV_SW_FROM_F64) in sljit_emit_fop1_conv_sw_from_f64()
3267 ins = (op & SLJIT_32) ? 0xb3a85000 /* cgebr */ : 0xb3a95000 /* cgdbr */; in sljit_emit_fop1_conv_sw_from_f64()
3269 ins = (op & SLJIT_32) ? 0xb3985000 /* cfebr */ : 0xb3995000 /* cfdbr */; in sljit_emit_fop1_conv_sw_from_f64()
3274 return store_word(compiler, dst_r, dst, dstw, GET_OPCODE(op) >= SLJIT_CONV_S32_FROM_F64); in sljit_emit_fop1_conv_sw_from_f64()
3302 …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
3308 if (src == SLJIT_IMM && GET_OPCODE(op) == SLJIT_CONV_F64_FROM_S32) in sljit_emit_fop1_conv_f64_from_sw()
3311 if (GET_OPCODE(op) == SLJIT_CONV_F64_FROM_SW) in sljit_emit_fop1_conv_f64_from_sw()
3312 ins = (op & SLJIT_32) ? 0xb3a40000 /* cegbr */ : 0xb3a50000 /* cdgbr */; in sljit_emit_fop1_conv_f64_from_sw()
3314 ins = (op & SLJIT_32) ? 0xb3940000 /* cefbr */ : 0xb3950000 /* cdfbr */; in sljit_emit_fop1_conv_f64_from_sw()
3319 …IT_INLINE sljit_s32 sljit_emit_fop1_conv_f64_from_uw(struct sljit_compiler *compiler, sljit_s32 op, in sljit_emit_fop1_conv_f64_from_uw() argument
3325 if (src == SLJIT_IMM && GET_OPCODE(op) == SLJIT_CONV_F64_FROM_U32) in sljit_emit_fop1_conv_f64_from_uw()
3328 if (GET_OPCODE(op) == SLJIT_CONV_F64_FROM_UW) in sljit_emit_fop1_conv_f64_from_uw()
3329 ins = (op & SLJIT_32) ? 0xb3a00000 /* celgbr */ : 0xb3a10000 /* cdlgbr */; in sljit_emit_fop1_conv_f64_from_uw()
3331 ins = (op & SLJIT_32) ? 0xb3900000 /* celfbr */ : 0xb3910000 /* cdlfbr */; in sljit_emit_fop1_conv_f64_from_uw()
3336 static SLJIT_INLINE sljit_s32 sljit_emit_fop1_cmp(struct sljit_compiler *compiler, sljit_s32 op, in sljit_emit_fop1_cmp() argument
3343 FAIL_IF(float_mem(compiler, FLOAT_LOAD | (op & SLJIT_32), TMP_FREG1, src1, src1w)); in sljit_emit_fop1_cmp()
3347 if (op & SLJIT_32) { in sljit_emit_fop1_cmp()
3358 SLJIT_API_FUNC_ATTRIBUTE sljit_s32 sljit_emit_fop1(struct sljit_compiler *compiler, sljit_s32 op, in sljit_emit_fop1() argument
3367 SELECT_FOP1_OPERATION_WITH_CHECKS(compiler, op, dst, dstw, src, srcw); in sljit_emit_fop1()
3371 if (op == SLJIT_CONV_F64_FROM_F32) in sljit_emit_fop1()
3375 …FAIL_IF(float_mem(compiler, FLOAT_LOAD | (op == SLJIT_CONV_F32_FROM_F64 ? 0 : (op & SLJIT_32)), ds… in sljit_emit_fop1()
3379 switch (GET_OPCODE(op)) { in sljit_emit_fop1()
3385 ins = (op & SLJIT_32) ? 0x3800 /* ler */ : 0x2800 /* ldr */; in sljit_emit_fop1()
3388 return float_mem(compiler, FLOAT_STORE | (op & SLJIT_32), src, dst, dstw); in sljit_emit_fop1()
3394 ins = (op & SLJIT_32) ? 0xb3030000 /* lcebr */ : 0xb3130000 /* lcdbr */; in sljit_emit_fop1()
3397 SLJIT_ASSERT(GET_OPCODE(op) == SLJIT_ABS_F64); in sljit_emit_fop1()
3398 ins = (op & SLJIT_32) ? 0xb3000000 /* lpebr */ : 0xb3100000 /* lpdbr */; in sljit_emit_fop1()
3406 return float_mem(compiler, FLOAT_STORE | (op & SLJIT_32), TMP_FREG1, dst, dstw); in sljit_emit_fop1()
3411 #define FLOAT_MOV(op, dst_r, src_r) \ argument
3412 (((op & SLJIT_32) ? 0x3800 /* ler */ : 0x2800 /* ldr */) | F4(dst_r) | F0(src_r))
3414 SLJIT_API_FUNC_ATTRIBUTE sljit_s32 sljit_emit_fop2(struct sljit_compiler *compiler, sljit_s32 op, in sljit_emit_fop2() argument
3423 CHECK(check_sljit_emit_fop2(compiler, op, dst, dstw, src1, src1w, src2, src2w)); in sljit_emit_fop2()
3436 if (GET_OPCODE(op) == SLJIT_ADD_F64 || GET_OPCODE(op) == SLJIT_MUL_F64) { in sljit_emit_fop2()
3443 FAIL_IF(push_inst(compiler, FLOAT_MOV(op, TMP_FREG1, src2))); in sljit_emit_fop2()
3449 FAIL_IF(float_mem(compiler, FLOAT_LOAD | (op & SLJIT_32), dst_r, src1, src1w)); in sljit_emit_fop2()
3451 FAIL_IF(push_inst(compiler, FLOAT_MOV(op, dst_r, src1))); in sljit_emit_fop2()
3454 switch (GET_OPCODE(op)) { in sljit_emit_fop2()
3456 ins_r = (op & SLJIT_32) ? 0xb30a0000 /* aebr */ : 0xb31a0000 /* adbr */; in sljit_emit_fop2()
3457 ins = (op & SLJIT_32) ? 0xed000000000a /* aeb */ : 0xed000000001a /* adb */; in sljit_emit_fop2()
3460 ins_r = (op & SLJIT_32) ? 0xb30b0000 /* sebr */ : 0xb31b0000 /* sdbr */; in sljit_emit_fop2()
3461 ins = (op & SLJIT_32) ? 0xed000000000b /* seb */ : 0xed000000001b /* sdb */; in sljit_emit_fop2()
3464 ins_r = (op & SLJIT_32) ? 0xb3170000 /* meebr */ : 0xb31c0000 /* mdbr */; in sljit_emit_fop2()
3465 ins = (op & SLJIT_32) ? 0xed0000000017 /* meeb */ : 0xed000000001c /* mdb */; in sljit_emit_fop2()
3468 SLJIT_ASSERT(GET_OPCODE(op) == SLJIT_DIV_F64); in sljit_emit_fop2()
3469 ins_r = (op & SLJIT_32) ? 0xb30d0000 /* debr */ : 0xb31d0000 /* ddbr */; in sljit_emit_fop2()
3470 ins = (op & SLJIT_32) ? 0xed000000000d /* deb */ : 0xed000000001d /* ddb */; in sljit_emit_fop2()
3477 return float_mem(compiler, FLOAT_STORE | (op & SLJIT_32), TMP_FREG1, dst, dstw); in sljit_emit_fop2()
3482 SLJIT_API_FUNC_ATTRIBUTE sljit_s32 sljit_emit_fop2r(struct sljit_compiler *compiler, sljit_s32 op, in sljit_emit_fop2r() argument
3490 CHECK(check_sljit_emit_fop2r(compiler, op, dst_freg, src1, src1w, src2, src2w)); in sljit_emit_fop2r()
3495 FAIL_IF(float_mem(compiler, FLOAT_LOAD | (op & SLJIT_32), TMP_FREG1, src2, src2w)); in sljit_emit_fop2r()
3501 FAIL_IF(float_mem(compiler, FLOAT_LOAD | (op & SLJIT_32), reg, src1, src1w)); in sljit_emit_fop2r()
3542 SLJIT_API_FUNC_ATTRIBUTE sljit_s32 sljit_emit_fcopy(struct sljit_compiler *compiler, sljit_s32 op, in sljit_emit_fcopy() argument
3548 CHECK(check_sljit_emit_fcopy(compiler, op, freg, reg)); in sljit_emit_fcopy()
3552 if (GET_OPCODE(op) == SLJIT_COPY_TO_F64) { in sljit_emit_fcopy()
3553 if (op & SLJIT_32) { in sljit_emit_fcopy()
3563 if (!(op & SLJIT_32)) in sljit_emit_fcopy()
3685 …JIT_API_FUNC_ATTRIBUTE sljit_s32 sljit_emit_op_flags(struct sljit_compiler *compiler, sljit_s32 op, in sljit_emit_op_flags() argument
3694 CHECK(check_sljit_emit_op_flags(compiler, op, dst, dstw, type)); in sljit_emit_op_flags()
3696 switch (GET_OPCODE(op)) { in sljit_emit_op_flags()
3700 compiler->status_flags_state = op & SLJIT_SET_Z; in sljit_emit_op_flags()
3704 FAIL_IF(load_word(compiler, dst_r, dst, dstw, op & SLJIT_32)); in sljit_emit_op_flags()
3708 op |= SLJIT_32; in sljit_emit_op_flags()
3723 WHEN2(op & SLJIT_32, lochi, locghi))); in sljit_emit_op_flags()
3732 switch (GET_OPCODE(op)) { in sljit_emit_op_flags()
3736 WHEN2(op & SLJIT_32, nr, ngr))); in sljit_emit_op_flags()
3740 WHEN2(op & SLJIT_32, or, ogr))); in sljit_emit_op_flags()
3744 WHEN2(op & SLJIT_32, xr, xgr))); in sljit_emit_op_flags()
3751 return store_word(compiler, dst_r, dst, dstw, (op & SLJIT_32)); in sljit_emit_op_flags()
4376 …_API_FUNC_ATTRIBUTE sljit_s32 sljit_emit_atomic_load(struct sljit_compiler *compiler, sljit_s32 op, in sljit_emit_atomic_load() argument
4381 CHECK(check_sljit_emit_atomic_load(compiler, op, dst_reg, mem_reg)); in sljit_emit_atomic_load()
4384 return sljit_emit_op1(compiler, op, dst_reg, 0, SLJIT_MEM1(mem_reg), 0); in sljit_emit_atomic_load()
4387 …API_FUNC_ATTRIBUTE sljit_s32 sljit_emit_atomic_store(struct sljit_compiler *compiler, sljit_s32 op, in sljit_emit_atomic_store() argument
4397 CHECK(check_sljit_emit_atomic_store(compiler, op, src_reg, mem_reg, temp_reg)); in sljit_emit_atomic_store()
4399 switch (GET_OPCODE(op)) { in sljit_emit_atomic_store()