Lines Matching refs:dst

192 void emit_mov_i(struct jit_context *ctx, u8 dst, s32 imm)  in emit_mov_i()  argument
195 emit(ctx, addiu, dst, MIPS_R_ZERO, imm); in emit_mov_i()
197 emit(ctx, lui, dst, (s16)((u32)imm >> 16)); in emit_mov_i()
198 emit(ctx, ori, dst, dst, (u16)(imm & 0xffff)); in emit_mov_i()
200 clobber_reg(ctx, dst); in emit_mov_i()
204 void emit_mov_r(struct jit_context *ctx, u8 dst, u8 src) in emit_mov_r() argument
206 emit(ctx, ori, dst, src, 0); in emit_mov_r()
207 clobber_reg(ctx, dst); in emit_mov_r()
298 void emit_alu_i(struct jit_context *ctx, u8 dst, s32 imm, u8 op) in emit_alu_i() argument
303 emit(ctx, subu, dst, MIPS_R_ZERO, dst); in emit_alu_i()
307 emit(ctx, andi, dst, dst, (u16)imm); in emit_alu_i()
311 emit(ctx, ori, dst, dst, (u16)imm); in emit_alu_i()
315 emit(ctx, xori, dst, dst, (u16)imm); in emit_alu_i()
319 emit(ctx, sll, dst, dst, imm); in emit_alu_i()
323 emit(ctx, srl, dst, dst, imm); in emit_alu_i()
327 emit(ctx, sra, dst, dst, imm); in emit_alu_i()
331 emit(ctx, addiu, dst, dst, imm); in emit_alu_i()
335 emit(ctx, addiu, dst, dst, -imm); in emit_alu_i()
338 clobber_reg(ctx, dst); in emit_alu_i()
342 void emit_alu_r(struct jit_context *ctx, u8 dst, u8 src, u8 op) in emit_alu_r() argument
347 emit(ctx, and, dst, dst, src); in emit_alu_r()
351 emit(ctx, or, dst, dst, src); in emit_alu_r()
355 emit(ctx, xor, dst, dst, src); in emit_alu_r()
359 emit(ctx, sllv, dst, dst, src); in emit_alu_r()
363 emit(ctx, srlv, dst, dst, src); in emit_alu_r()
367 emit(ctx, srav, dst, dst, src); in emit_alu_r()
371 emit(ctx, addu, dst, dst, src); in emit_alu_r()
375 emit(ctx, subu, dst, dst, src); in emit_alu_r()
380 emit(ctx, mul, dst, dst, src); in emit_alu_r()
382 emit(ctx, multu, dst, src); in emit_alu_r()
383 emit(ctx, mflo, dst); in emit_alu_r()
389 emit(ctx, divu_r6, dst, dst, src); in emit_alu_r()
391 emit(ctx, divu, dst, src); in emit_alu_r()
392 emit(ctx, mflo, dst); in emit_alu_r()
398 emit(ctx, modu, dst, dst, src); in emit_alu_r()
400 emit(ctx, divu, dst, src); in emit_alu_r()
401 emit(ctx, mfhi, dst); in emit_alu_r()
405 clobber_reg(ctx, dst); in emit_alu_r()
409 void emit_atomic_r(struct jit_context *ctx, u8 dst, u8 src, s16 off, u8 code) in emit_atomic_r() argument
412 emit(ctx, ll, MIPS_R_T9, off, dst); in emit_atomic_r()
434 emit(ctx, sc, MIPS_R_T8, off, dst); in emit_atomic_r()
445 void emit_cmpxchg_r(struct jit_context *ctx, u8 dst, u8 src, u8 res, s16 off) in emit_cmpxchg_r() argument
448 emit(ctx, ll, MIPS_R_T9, off, dst); in emit_cmpxchg_r()
451 emit(ctx, sc, MIPS_R_T8, off, dst); in emit_cmpxchg_r()
458 void emit_bswap_r(struct jit_context *ctx, u8 dst, u32 width) in emit_bswap_r() argument
467 emit(ctx, wsbh, dst, dst); in emit_bswap_r()
468 emit(ctx, rotr, dst, dst, 16); in emit_bswap_r()
470 emit(ctx, sll, tmp, dst, 16); /* tmp = dst << 16 */ in emit_bswap_r()
471 emit(ctx, srl, dst, dst, 16); /* dst = dst >> 16 */ in emit_bswap_r()
472 emit(ctx, or, dst, dst, tmp); /* dst = dst | tmp */ in emit_bswap_r()
477 emit(ctx, and, tmp, dst, msk); /* tmp = dst & msk */ in emit_bswap_r()
479 emit(ctx, srl, dst, dst, 8); /* dst = dst >> 8 */ in emit_bswap_r()
480 emit(ctx, and, dst, dst, msk); /* dst = dst & msk */ in emit_bswap_r()
481 emit(ctx, or, dst, dst, tmp); /* reg = dst | tmp */ in emit_bswap_r()
487 emit(ctx, wsbh, dst, dst); in emit_bswap_r()
488 emit(ctx, andi, dst, dst, 0xffff); in emit_bswap_r()
490 emit(ctx, andi, tmp, dst, 0xff00); /* t = d & 0xff00 */ in emit_bswap_r()
492 emit(ctx, andi, dst, dst, 0x00ff); /* d = d & 0x00ff */ in emit_bswap_r()
493 emit(ctx, sll, dst, dst, 8); /* d = d << 8 */ in emit_bswap_r()
494 emit(ctx, or, dst, dst, tmp); /* d = d | t */ in emit_bswap_r()
498 clobber_reg(ctx, dst); in emit_bswap_r()
698 void emit_jmp_i(struct jit_context *ctx, u8 dst, s32 imm, s32 off, u8 op) in emit_jmp_i() argument
706 emit(ctx, andi, MIPS_R_T9, dst, (u16)imm); in emit_jmp_i()
711 emit(ctx, andi, MIPS_R_T9, dst, (u16)imm); in emit_jmp_i()
716 emit(ctx, sltiu, MIPS_R_T9, dst, imm + 1); in emit_jmp_i()
721 emit(ctx, sltiu, MIPS_R_T9, dst, imm); in emit_jmp_i()
726 emit(ctx, sltiu, MIPS_R_T9, dst, imm); in emit_jmp_i()
731 emit(ctx, sltiu, MIPS_R_T9, dst, imm + 1); in emit_jmp_i()
736 emit(ctx, slti, MIPS_R_T9, dst, imm + 1); in emit_jmp_i()
741 emit(ctx, slti, MIPS_R_T9, dst, imm); in emit_jmp_i()
746 emit(ctx, slti, MIPS_R_T9, dst, imm); in emit_jmp_i()
751 emit(ctx, slti, MIPS_R_T9, dst, imm + 1); in emit_jmp_i()
758 void emit_jmp_r(struct jit_context *ctx, u8 dst, u8 src, s32 off, u8 op) in emit_jmp_r() argument
766 emit(ctx, beq, dst, src, off); in emit_jmp_r()
770 emit(ctx, bne, dst, src, off); in emit_jmp_r()
774 emit(ctx, and, MIPS_R_T9, dst, src); in emit_jmp_r()
779 emit(ctx, and, MIPS_R_T9, dst, src); in emit_jmp_r()
784 emit(ctx, sltu, MIPS_R_T9, src, dst); in emit_jmp_r()
789 emit(ctx, sltu, MIPS_R_T9, dst, src); in emit_jmp_r()
794 emit(ctx, sltu, MIPS_R_T9, dst, src); in emit_jmp_r()
799 emit(ctx, sltu, MIPS_R_T9, src, dst); in emit_jmp_r()
804 emit(ctx, slt, MIPS_R_T9, src, dst); in emit_jmp_r()
809 emit(ctx, slt, MIPS_R_T9, dst, src); in emit_jmp_r()
814 emit(ctx, slt, MIPS_R_T9, dst, src); in emit_jmp_r()
819 emit(ctx, slt, MIPS_R_T9, src, dst); in emit_jmp_r()