On Fri, May 23, 2025 at 1:53 PM Yonghong Song <yonghong.song@xxxxxxxxx> wrote: > --- /dev/null > +++ b/tools/testing/selftests/bpf/progs/verifier_bpf_trap.c > @@ -0,0 +1,71 @@ > +// SPDX-License-Identifier: GPL-2.0 > +/* Copyright (c) 2025 Meta Platforms, Inc. and affiliates. */ > +#include <vmlinux.h> > +#include <bpf/bpf_helpers.h> > +#include "bpf_misc.h" > + > +#if __clang_major__ >= 21 I added "&& 0" here to avoid failing the build on current clang 21. > +SEC("socket") > +__description("__builtin_trap with simple c code") > +__failure __msg("unexpected __bpf_trap() due to uninitialized variable?") > +void bpf_builtin_trap_with_simple_c(void) > +{ > + __builtin_trap(); > +} > +#endif