]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
bpf: Don't run arg-tracking analysis twice on main subprog
authorPaul Chaignon <paul.chaignon@gmail.com>
Thu, 7 May 2026 18:22:06 +0000 (20:22 +0200)
committerAlexei Starovoitov <ast@kernel.org>
Sat, 9 May 2026 23:12:40 +0000 (16:12 -0700)
commit512809bb8a370d071f66fc53abe67368e171dec5
treedbcfc80d25360ec47f2572a84595651b6f6e9e6b
parent18fc650ccd7fe3376eca89203668cfb8268f60df
bpf: Don't run arg-tracking analysis twice on main subprog

Because subprog 0, the main subprog, is considered a global function,
we end up running the arg-tracking dataflow analysis twice on it. That
results in slightly longer verification but mostly in more verbose
verifier logs. This patch fixes it by keeping only the iteration over
global subprogs.

When running over all of Cilium's programs with BPF_LOG_LEVEL2, this
reduces verbosity by ~20% on average.

Fixes: bf0c571f7feb6 ("bpf: introduce forward arg-tracking dataflow analysis")
Signed-off-by: Paul Chaignon <paul.chaignon@gmail.com>
Acked-by: Eduard Zingerman <eddyz87@gmail.com>
Link: https://lore.kernel.org/r/e4d7b53d4963ef520541a782f5fc8108a168877c.1778176504.git.paul.chaignon@gmail.com
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
kernel/bpf/liveness.c