Lines Matching refs:imm
158 static void emit_alu_i64(struct jit_context *ctx, u8 dst, s32 imm, u8 op) in emit_alu_i64() argument
163 emit(ctx, ori, dst, dst, (u16)imm); in emit_alu_i64()
167 emit(ctx, xori, dst, dst, (u16)imm); in emit_alu_i64()
175 emit(ctx, dsll_safe, dst, dst, imm); in emit_alu_i64()
179 emit(ctx, dsrl_safe, dst, dst, imm); in emit_alu_i64()
183 emit(ctx, dsra_safe, dst, dst, imm); in emit_alu_i64()
187 emit(ctx, daddiu, dst, dst, imm); in emit_alu_i64()
191 emit(ctx, daddiu, dst, dst, -imm); in emit_alu_i64()
195 emit_alu_i(ctx, dst, imm, op); in emit_alu_i64()
631 s32 imm = insn->imm; in build_insn() local
639 emit_mov_i(ctx, dst, imm); in build_insn()
644 if (imm == 1) { in build_insn()
666 if (!valid_alu_i(BPF_OP(code), imm)) { in build_insn()
667 emit_mov_i(ctx, MIPS_R_T4, imm); in build_insn()
669 } else if (rewrite_alu_i(BPF_OP(code), imm, &alu, &val)) { in build_insn()
688 if (!valid_alu_i(BPF_OP(code), imm)) { in build_insn()
690 emit_mov_i(ctx, MIPS_R_T4, imm); in build_insn()
692 } else if (rewrite_alu_i(BPF_OP(code), imm, &alu, &val)) { in build_insn()
730 emit_mov_i(ctx, dst, imm); in build_insn()
762 if (!valid_alu_i(BPF_OP(code), imm)) { in build_insn()
763 emit_mov_i(ctx, MIPS_R_T4, imm); in build_insn()
765 } else if (rewrite_alu_i(BPF_OP(code), imm, &alu, &val)) { in build_insn()
804 emit_bswap_r64(ctx, dst, imm); in build_insn()
806 emit_trunc_r64(ctx, dst, imm); in build_insn()
810 emit_mov_i64(ctx, dst, (u32)imm | ((u64)insn[1].imm << 32)); in build_insn()
824 emit_mov_i(ctx, MIPS_R_T4, imm); in build_insn()
840 switch (imm) { in build_insn()
851 emit_atomic_r64(ctx, dst, src, off, imm); in build_insn()
852 } else if (imm & BPF_FETCH) { in build_insn()
860 emit_atomic_r(ctx, tmp, src, off, imm); in build_insn()
864 emit_atomic_r(ctx, dst, MIPS_R_T4, off, imm); in build_insn()
942 setup_jmp_i(ctx, imm, 32, BPF_OP(code), off, &jmp, &rel); in build_insn()
944 if (valid_jmp_i(jmp, imm)) { in build_insn()
945 emit_jmp_i(ctx, MIPS_R_T4, imm, rel, jmp); in build_insn()
948 emit_mov_i(ctx, MIPS_R_T5, imm); in build_insn()
1007 setup_jmp_i(ctx, imm, 64, BPF_OP(code), off, &jmp, &rel); in build_insn()
1008 if (valid_jmp_i(jmp, imm)) { in build_insn()
1009 emit_jmp_i(ctx, dst, imm, rel, jmp); in build_insn()
1012 emit_mov_i(ctx, MIPS_R_T4, imm); in build_insn()