selftests/bpf: Add a selftest for checking subreg equality
authorYonghong Song <yhs@fb.com>
Mon, 17 Apr 2023 22:21:39 +0000 (15:21 -0700)
committerAlexei Starovoitov <ast@kernel.org>
Mon, 17 Apr 2023 22:50:02 +0000 (15:50 -0700)
commit49859de997c3115b85544bce6b6ceab60a7fabc4
treedea1dee4515026d2088b98f53144c0631c608e6a
parent3be49f79555ee975acb4ad8b5de06fa4351264aa
selftests/bpf: Add a selftest for checking subreg equality

Add a selftest to ensure subreg equality if source register
upper 32bit is 0. Without previous patch, the test will
fail verification.

Acked-by: Eduard Zingerman <eddyz87@gmail.com>
Signed-off-by: Yonghong Song <yhs@fb.com>
Link: https://lore.kernel.org/r/20230417222139.360607-1-yhs@fb.com
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
tools/testing/selftests/bpf/prog_tests/verifier.c
tools/testing/selftests/bpf/progs/verifier_reg_equal.c [new file with mode: 0644]