Home
last modified time | relevance | path

Searched refs:EMIT (Results 1 – 5 of 5) sorted by relevance

/linux-6.12.1/arch/powerpc/net/
Dbpf_jit_comp32.c36 #define PPC_EX32(r, i) EMIT(PPC_RAW_LI((r), (i) < 0 ? -1 : 0))
132 EMIT(PPC_RAW_LI(_R4, 0)); in bpf_jit_build_prologue()
134 EMIT(PPC_RAW_NOP()); in bpf_jit_build_prologue()
139 EMIT(PPC_RAW_STWU(_R1, _R1, -BPF_PPC_STACKFRAME(ctx))); in bpf_jit_build_prologue()
142 EMIT(PPC_RAW_STW(_R4, _R1, bpf_jit_stack_offsetof(ctx, BPF_PPC_TC))); in bpf_jit_build_prologue()
145 EMIT(PPC_RAW_MR(bpf_to_ppc(BPF_REG_1), _R3)); in bpf_jit_build_prologue()
146 EMIT(PPC_RAW_LI(bpf_to_ppc(BPF_REG_1) - 1, 0)); in bpf_jit_build_prologue()
153 EMIT(PPC_RAW_MFLR(_R0)); in bpf_jit_build_prologue()
160 EMIT(PPC_RAW_STW(i, _R1, bpf_jit_stack_offsetof(ctx, i))); in bpf_jit_build_prologue()
164 EMIT(PPC_RAW_LI(bpf_to_ppc(BPF_REG_FP) - 1, 0)); in bpf_jit_build_prologue()
[all …]
Dbpf_jit_comp64.c131 EMIT(PPC_RAW_LD(_R2, _R13, offsetof(struct paca_struct, kernel_toc))); in bpf_jit_build_prologue()
140 EMIT(PPC_RAW_LI(bpf_to_ppc(TMP_REG_1), 0)); in bpf_jit_build_prologue()
142 EMIT(PPC_RAW_STD(bpf_to_ppc(TMP_REG_1), _R1, -(BPF_PPC_STACK_SAVE + 8))); in bpf_jit_build_prologue()
144 EMIT(PPC_RAW_NOP()); in bpf_jit_build_prologue()
145 EMIT(PPC_RAW_NOP()); in bpf_jit_build_prologue()
154 EMIT(PPC_RAW_MFLR(_R0)); in bpf_jit_build_prologue()
155 EMIT(PPC_RAW_STD(_R0, _R1, PPC_LR_STKOFF)); in bpf_jit_build_prologue()
158 EMIT(PPC_RAW_STDU(_R1, _R1, -(BPF_PPC_STACKFRAME + ctx->stack_size))); in bpf_jit_build_prologue()
168 EMIT(PPC_RAW_STD(bpf_to_ppc(i), _R1, bpf_jit_stack_offsetof(ctx, bpf_to_ppc(i)))); in bpf_jit_build_prologue()
172 EMIT(PPC_RAW_ADDI(bpf_to_ppc(BPF_REG_FP), _R1, in bpf_jit_build_prologue()
[all …]
Dbpf_jit.h26 #define EMIT(instr) PLANT_INSTR(image, ctx->idx, instr) macro
36 EMIT(PPC_RAW_BRANCH(offset)); \
47 EMIT(PPC_INST_BRANCH_COND | (((cond) & 0x3ff) << 16) | (offset & 0xfffc)); \
54 EMIT(PPC_RAW_LI(d, i)); \
56 EMIT(PPC_RAW_LIS(d, IMM_H(i))); \
58 EMIT(PPC_RAW_ORI(d, d, IMM_L(i))); \
68 EMIT(PPC_RAW_LI(d, ((uintptr_t)(i) >> 32) & \
71 EMIT(PPC_RAW_LIS(d, ((uintptr_t)(i) >> 48))); \
73 EMIT(PPC_RAW_ORI(d, d, \
76 EMIT(PPC_RAW_SLDI(d, d, 32)); \
[all …]
/linux-6.12.1/arch/x86/net/
Dbpf_jit_comp32.c64 #define EMIT(bytes, len) \ macro
67 #define EMIT1(b1) EMIT(b1, 1)
68 #define EMIT2(b1, b2) EMIT((b1) + ((b2) << 8), 2)
69 #define EMIT3(b1, b2, b3) EMIT((b1) + ((b2) << 8) + ((b3) << 16), 3)
71 EMIT((b1) + ((b2) << 8) + ((b3) << 16) + ((b4) << 24), 4)
74 do { EMIT1(b1); EMIT(off, 4); } while (0)
76 do { EMIT2(b1, b2); EMIT(off, 4); } while (0)
78 do { EMIT3(b1, b2, b3); EMIT(off, 4); } while (0)
80 do { EMIT4(b1, b2, b3, b4); EMIT(off, 4); } while (0)
1926 EMIT(0xC6, 1); break; in do_jit()
[all …]
Dbpf_jit_comp.c37 #define EMIT(bytes, len) \ macro
40 #define EMIT1(b1) EMIT(b1, 1)
41 #define EMIT2(b1, b2) EMIT((b1) + ((b2) << 8), 2)
42 #define EMIT3(b1, b2, b3) EMIT((b1) + ((b2) << 8) + ((b3) << 16), 3)
43 #define EMIT4(b1, b2, b3, b4) EMIT((b1) + ((b2) << 8) + ((b3) << 16) + ((b4) << 24), 4)
46 do { EMIT1(b1); EMIT(off, 4); } while (0)
48 do { EMIT2(b1, b2); EMIT(off, 4); } while (0)
50 do { EMIT3(b1, b2, b3); EMIT(off, 4); } while (0)
52 do { EMIT4(b1, b2, b3, b4); EMIT(off, 4); } while (0)
55 #define EMIT_ENDBR() EMIT(gen_endbr(), 4)
[all …]