bpf: Request to add -mcpu=v4 support for ARM/MIPS/NFP/POWERPC/RISCV/S390/SPARC/X86_32
Yonghong Song
reviewerHi,
A new set of bpf insns have been recently added in llvm with flag [-mcpu=v4](https://reviews.llvm.org/D144829). In the kernel, x86_64 and arm64 have implemented -mcpu=v4 support:
x86_64:
https://lore.kernel.org/all/[email protected]/
arm64:
https://lore.kernel.org/bpf/[email protected]/
The following arch's do not have -mcpu=v4 support yet:
arm, mips, nfp, powerpc, riscv, sc90, sparc and x86_32
If you have a chance, could you take a look at what x86_64/arm64 does and add support to the above arch'es?
Thanks!
Yonghong
Alright, riscv64 is already being adapted, will be sent soon.
Quoted 20 lines · Yonghong Song
Hi,
A new set of bpf insns have been recently added in llvm with flag [-mcpu=v4](https://reviews.llvm.org/D144829). In the kernel,
x86_64and arm64 have implemented -mcpu=v4 support:
x86_64:
https://lore.kernel.org/all/[email protected]/
arm64:
https://lore.kernel.org/bpf/[email protected]/The following arch's do not have -mcpu=v4 support yet:
arm, mips, nfp, powerpc, riscv, sc90, sparc andx86_32If you have a chance, could you take a look at what x86_64/arm64 does and add support to the above arch'es?
Thanks!
Yonghong
Yonghong Song
reviewerQuoted 1 line · Pu Lehui
Alright, riscv64 is already being adapted, will be sent soon.
Thanks! Looking forward to the patch set.
Quoted 20 lines · Yonghong Song
Quoted 18 lines
Hi,
A new set of bpf insns have been recently added in llvm with flag [-mcpu=v4](https://reviews.llvm.org/D144829). In the kernel,
x86_64and arm64 have implemented -mcpu=v4 support:
x86_64: https://lore.kernel.org/all/[email protected]/
arm64: https://lore.kernel.org/bpf/[email protected]/The following arch's do not have -mcpu=v4 support yet:
arm, mips, nfp, powerpc, riscv, sc90, sparc andx86_32If you have a chance, could you take a look at what x86_64/arm64 does and add support to the above arch'es?
Thanks!
Yonghong
Quoted 10 lines · On Sat, 19 Aug 2023 18:41:30 -0700 Yonghong Song wrote:
Hi,
A new set of bpf insns have been recently added in llvm with flag [-mcpu=v4](https://reviews.llvm.org/D144829). In the kernel,
x86_64and arm64 have implemented -mcpu=v4 support:x86_64:https://lore.kernel.org/all/[email protected]/
arm64:
https://lore.kernel.org/bpf/[email protected]/
Quoted 5 lines
The following arch's do not have -mcpu=v4 support yet:
arm, mips, nfp, powerpc, riscv, sc90, sparc andx86_32If you have a chance, could you take a look at what x86_64/arm64 does and add support to the above arch'es?
Louis, is anyone on your side still working on BPF for NFP? div/mod and the jump will be impossible but there may be instructions for sign extend or bswap?
Quoted 14 lines · Jakub Kicinski
Quoted 13 lines · On Sat, 19 Aug 2023 18:41:30 -0700 Yonghong Song wrote:
Hi,
A new set of bpf insns have been recently added in llvm with flag [-mcpu=v4](https://reviews.llvm.org/D144829). In the kernel,
x86_64and arm64 have implemented -mcpu=v4 support:x86_64:https://lore.kernel.org/all/[email protected]/
arm64:
https://lore.kernel.org/bpf/[email protected]/The following arch's do not have -mcpu=v4 support yet:
arm, mips, nfp, powerpc, riscv, sc90, sparc andx86_32
Quoted 6 lines
Quoted 2 lines
If you have a chance, could you take a look at what x86_64/arm64 does and add support to the above arch'es?
Louis, is anyone on your side still working on BPF for NFP? div/mod and the jump will be impossible but there may be instructions for sign extend or bswap?
There isn't a lot of activity on the BPF side for nfp, but here and there some things do get addressed. I will run it past the team, it does seem like those might be possible with the architecture - thanks for the ping.