[PATCH bpf-next v2 0/2] bpf: Skip bounds adjustment for conditional jumps on same register

KaFai Wan posted 2 patches 3 months, 2 weeks ago
kernel/bpf/verifier.c                         | 32 +++++++++++++++++++
.../selftests/bpf/progs/verifier_bounds.c     | 18 +++++++++++
2 files changed, 50 insertions(+)
[PATCH bpf-next v2 0/2] bpf: Skip bounds adjustment for conditional jumps on same register
Posted by KaFai Wan 3 months, 2 weeks ago
This small patchset is about avoid verifier bug warning when conditional
 jumps on same register when the register holds a scalar with range.

v2:
 - Enhance is_branch_taken() and is_scalar_branch_taken() to handle
   branch direction computation for same register. (Eduard and Alexei)
 - Update the selftest.

v1:
  https://lore.kernel.org/bpf/20251022164457.1203756-1-kafai.wan@linux.dev/
---
KaFai Wan (2):
  bpf: Skip bounds adjustment for conditional jumps on same register
  selftests/bpf: Add test for BPF_JGT on same register

 kernel/bpf/verifier.c                         | 32 +++++++++++++++++++
 .../selftests/bpf/progs/verifier_bounds.c     | 18 +++++++++++
 2 files changed, 50 insertions(+)

-- 
2.43.0