linux/arch/riscv/net
Luke Nelson ca349a6a10 bpf, riscv: Optimize BPF_JMP BPF_K when imm == 0 on RV64
This patch adds an optimization to BPF_JMP (32- and 64-bit) BPF_K for
when the BPF immediate is zero.

When the immediate is zero, the code can directly use the RISC-V zero
register instead of loading a zero immediate to a temporary register
first.

Co-developed-by: Xi Wang <xi.wang@gmail.com>
Signed-off-by: Xi Wang <xi.wang@gmail.com>
Signed-off-by: Luke Nelson <luke.r.nels@gmail.com>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
Reviewed-by: Björn Töpel <bjorn.topel@gmail.com>
Acked-by: Björn Töpel <bjorn.topel@gmail.com>
Link: https://lore.kernel.org/bpf/20200506000320.28965-4-luke.r.nels@gmail.com
2020-05-06 09:48:15 +02:00
..
bpf_jit_comp32.c bpf, riscv: Fix stack layout of JITed code on RV32 2020-04-30 16:14:50 +02:00
bpf_jit_comp64.c bpf, riscv: Optimize BPF_JMP BPF_K when imm == 0 on RV64 2020-05-06 09:48:15 +02:00
bpf_jit_core.c riscv, bpf: Factor common RISC-V JIT code 2020-03-05 16:13:47 +01:00
bpf_jit.h riscv, bpf: Add RV32G eBPF JIT 2020-03-05 16:13:47 +01:00
Makefile riscv, bpf: Add RV32G eBPF JIT 2020-03-05 16:13:47 +01:00