]> git.baikalelectronics.ru Git - kernel.git/commit
bpf: change x86 JITed program stack layout
authorAlexei Starovoitov <ast@fb.com>
Tue, 30 May 2017 20:31:34 +0000 (13:31 -0700)
committerDavid S. Miller <davem@davemloft.net>
Wed, 31 May 2017 23:29:48 +0000 (19:29 -0400)
commit8291c2e9089c91b9b1120bd294eda83a0acba098
treed8cb564978e0f74b91e0a297e98976c2b3af79ba
parent151b426febc850c879853c89fcf6367708488544
bpf: change x86 JITed program stack layout

in order to JIT programs with different stack sizes we need to
make epilogue and exception path to be stack size independent,
hence move auxiliary stack space from the bottom of the stack
to the top of the stack.
Nice side effect is that JITed function prologue becomes shorter
due to imm8 offset encoding vs imm32.

Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Acked-by: Daniel Borkmann <daniel@iogearbox.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
arch/x86/net/bpf_jit.S
arch/x86/net/bpf_jit_comp.c