]> git.baikalelectronics.ru Git - kernel.git/commit
bpf, x64: save one byte per shl/shr/sar when imm is 1
authorDaniel Borkmann <daniel@iogearbox.net>
Sat, 24 Feb 2018 00:07:58 +0000 (01:07 +0100)
committerAlexei Starovoitov <ast@kernel.org>
Sat, 24 Feb 2018 06:50:00 +0000 (22:50 -0800)
commitf5f0f38bc2931b376721cc1c5c9464d809a56b5f
tree3b7969431a064be0e3079257d01f895bf5692f97
parent1daa5f5f7e3955ee1123e794f9e2b53bd1745eef
bpf, x64: save one byte per shl/shr/sar when imm is 1

When we shift by one, we can use a different encoding where imm
is not explicitly needed, which saves 1 byte per such op.

Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
arch/x86/net/bpf_jit_comp.c