aboutsummaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python
diff options
context:
space:
mode:
authorLorenz Bauer <[email protected]>2020-09-21 13:12:26 +0100
committerAlexei Starovoitov <[email protected]>2020-09-21 15:00:41 -0700
commitfd1b0d604c56e0d9f143b39a92132a2ea9625e6d (patch)
tree1e267745789439496f30a151536d621e1151389a /tools/perf/scripts/python
parentc18f0b6aee2aaa6ab2aefd4b9aa1d89142a48824 (diff)
bpf: Hoist type checking for nullable arg types
check_func_arg has a plethora of weird if statements with empty branches. They work around the fact that *_OR_NULL argument types should accept a SCALAR_VALUE register, as long as it's value is 0. These statements make it difficult to reason about the type checking logic. Instead, skip more detailed type checking logic iff the register is 0, and the function expects a nullable type. This allows simplifying the type checking itself. Signed-off-by: Lorenz Bauer <[email protected]> Signed-off-by: Alexei Starovoitov <[email protected]> Acked-by: Andrii Nakryiko <[email protected]> Acked-by: Martin KaFai Lau <[email protected]> Link: https://lore.kernel.org/bpf/[email protected]
Diffstat (limited to 'tools/perf/scripts/python')
0 files changed, 0 insertions, 0 deletions