Re: [PATCH RFC] arm64: eBPF JIT compiler

2014-07-04 Thread Will Deacon
On Fri, Jul 04, 2014 at 07:56:54AM +0100, Z Lim wrote: > On Thu, Jul 3, 2014 at 2:14 AM, Will Deacon wrote: > > Does this sound remotely feasible? > > So I looked at insn.c and the only overlap at this point is B/BL codegen. > A whole lot more, e.g. arithmetic, logical, and memory ops, will need

Re: [PATCH RFC] arm64: eBPF JIT compiler

2014-07-03 Thread Z Lim
Hi Will, On Thu, Jul 3, 2014 at 2:14 AM, Will Deacon wrote: > Hello, > > On Wed, Jul 02, 2014 at 06:20:24AM +0100, Zi Shen Lim wrote: [...] > > First off, this is really cool. Thanks for putting in the effort to get this > supported on arm64! I'm happy to run tests on some real hardware if you te

Re: [PATCH RFC] arm64: eBPF JIT compiler

2014-07-03 Thread Daniel Borkmann
On 07/03/2014 11:14 AM, Will Deacon wrote: On Wed, Jul 02, 2014 at 06:20:24AM +0100, Zi Shen Lim wrote: The JIT compiler emits A64 instructions. It supports eBPF only. Legacy BPF is supported thanks to conversion by BPF core. JIT is enabled in the same way as for other architectures:

Re: [PATCH RFC] arm64: eBPF JIT compiler

2014-07-03 Thread Will Deacon
Hello, On Wed, Jul 02, 2014 at 06:20:24AM +0100, Zi Shen Lim wrote: > The JIT compiler emits A64 instructions. It supports eBPF only. > Legacy BPF is supported thanks to conversion by BPF core. > > JIT is enabled in the same way as for other architectures: > > echo 1 > /proc/sys/net/core

Re: [PATCH RFC] arm64: eBPF JIT compiler

2014-07-02 Thread Z Lim
On Wed, Jul 2, 2014 at 9:57 PM, Z Lim wrote: > On Wed, Jul 2, 2014 at 2:28 PM, Alexei Starovoitov wrote: >> On Tue, Jul 1, 2014 at 10:20 PM, Zi Shen Lim wrote: >> Do you really need 'jump by register' then? Regular 'bl' would be much >> faster. > > We'll need BLR to cover all cases. BL instruct

Re: [PATCH RFC] arm64: eBPF JIT compiler

2014-07-02 Thread Z Lim
On Wed, Jul 2, 2014 at 2:28 PM, Alexei Starovoitov wrote: > On Tue, Jul 1, 2014 at 10:20 PM, Zi Shen Lim wrote: >> The JIT compiler emits A64 instructions. It supports eBPF only. >> Legacy BPF is supported thanks to conversion by BPF core. >> >> JIT is enabled in the same way as for other archite

Re: [PATCH RFC] arm64: eBPF JIT compiler

2014-07-02 Thread Alexei Starovoitov
On Tue, Jul 1, 2014 at 10:20 PM, Zi Shen Lim wrote: > The JIT compiler emits A64 instructions. It supports eBPF only. > Legacy BPF is supported thanks to conversion by BPF core. > > JIT is enabled in the same way as for other architectures: > > echo 1 > /proc/sys/net/core/bpf_jit_enable >

Re: [PATCH RFC] arm64: eBPF JIT compiler

2014-07-01 Thread Alexei Starovoitov
On Tue, Jul 1, 2014 at 10:20 PM, Zi Shen Lim wrote: > The JIT compiler emits A64 instructions. It supports eBPF only. > Legacy BPF is supported thanks to conversion by BPF core. > > JIT is enabled in the same way as for other architectures: > > echo 1 > /proc/sys/net/core/bpf_jit_enable >

[PATCH RFC] arm64: eBPF JIT compiler

2014-07-01 Thread Zi Shen Lim
The JIT compiler emits A64 instructions. It supports eBPF only. Legacy BPF is supported thanks to conversion by BPF core. JIT is enabled in the same way as for other architectures: echo 1 > /proc/sys/net/core/bpf_jit_enable Or for additional compiler output: echo 2 > /proc/sys/n