s390/bpf: Fix optimizing out zero-extensions
Currently the JIT completely removes things like `reg32 += 0`, however, the BPF_ALU semantics requires the target register to be zero-extended in such cases. Fix by optimizing out only the arithmetic operation, but not the subsequent zero-extension. Reported-by:Johan Almbladh <johan.almbladh@anyfinetworks.com> Fixes: 05462310 ("s390/bpf: Add s390x eBPF JIT compiler backend") Reviewed-by:
Heiko Carstens <hca@linux.ibm.com> Signed-off-by:
Ilya Leoshkevich <iii@linux.ibm.com> Signed-off-by:
Vasily Gorbik <gor@linux.ibm.com>
parent
6e61dc9d
Please register or sign in to comment