From: Eduard Zingerman <eddyz87@gmail.com>
To: bot+bpf-ci@kernel.org, bpf@vger.kernel.org, ast@kernel.org,
andrii@kernel.org
Cc: daniel@iogearbox.net, martin.lau@linux.dev, kernel-team@fb.com,
yonghong.song@linux.dev, martin.lau@kernel.org, clm@meta.com,
ihor.solodrai@linux.dev
Subject: Re: [PATCH bpf-next 03/14] bpf: Add spis_*() helpers for 4-byte stack slot bitmasks
Date: Thu, 09 Apr 2026 15:05:25 -0700 [thread overview]
Message-ID: <7dd54c3cfab9996661699a10710e24cccc79fef4.camel@gmail.com> (raw)
In-Reply-To: <bebd6ee70784d72f6b6d36e1cf6cec12bada144fb5b15f0acf5a234be1fc0616@mail.kernel.org>
On Thu, 2026-04-09 at 03:12 +0000, bot+bpf-ci@kernel.org wrote:
> > diff --git a/include/linux/bpf_verifier.h b/include/linux/bpf_verifier.h
> > index 410939d7b325..64361cb49073 100644
> > --- a/include/linux/bpf_verifier.h
> > +++ b/include/linux/bpf_verifier.h
>
> [ ... ]
>
> > +static inline spis_t spis_xor(spis_t a, spis_t b)
> > +{
> > + return (spis_t){{ a.v[0] ^ b.v[0], a.v[1] ^ b.v[1] }};
> > +}
>
> spis_xor() does not appear to have any callers in this series.
> The same applies to spis_set_bit(), spis_single_slot(),
> spis_msb_half_slot(), and spis_lsb_half_slot() -- none of them
> are used by any commit in the series up through "bpf: poison
> dead stack slots". Could these be dropped, or are they intended
> for use beyond this series?
All of these are used in:
"bpf: make liveness.c track stack with 4-byte granularity"
Does the bot check out correct repository state when checking for this?
>
> [ ... ]
>
> > +/*
> > + * Return a mask with only the MSB (higher-addressed) 4-byte half
> > + * of an 8-byte SPI set. This is sub-slot spi*2+1.
> > + */
> > +static inline spis_t spis_msb_half_slot(u32 spi)
>
> > +/*
> > + * Return a mask with only the LSB (lower-addressed) 4-byte half
> > + * of an 8-byte SPI set. This is sub-slot spi*2.
> > + */
> > +static inline spis_t spis_lsb_half_slot(u32 spi)
>
> If these helpers are kept, the comments appear to have the
> address direction inverted. Later in the series,
> clean_verifier_state() documents the sub-slot mapping as:
>
> half_spi 2*i -> slot_type[0..3] (closer to FP)
> half_spi 2*i+1 -> slot_type[4..7] (farther from FP)
>
> Since the BPF stack grows downward, closer to FP means higher
> addresses. So spi*2 is the higher-addressed half and spi*2+1
> is the lower-addressed half, which is the opposite of what
> these comments say.
Comments are fine, LSB and MSB are not mixed in __clean_func_state()
and here.
>
>
> ---
> AI reviewed your patch. Please fix the bug or email reply why it's not a bug.
> See: https://github.com/kernel-patches/vmtest/blob/master/ci/claude/README.md
>
> CI run summary: https://github.com/kernel-patches/bpf/actions/runs/24168298083
next prev parent reply other threads:[~2026-04-09 22:05 UTC|newest]
Thread overview: 29+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-04-09 1:33 [PATCH bpf-next 00/14] bpf: static stack liveness data flow analysis Eduard Zingerman
2026-04-09 1:33 ` [PATCH bpf-next 01/14] bpf: share several utility functions as internal API Eduard Zingerman
2026-04-09 17:00 ` Mykyta Yatsenko
2026-04-09 1:33 ` [PATCH bpf-next 02/14] bpf: save subprogram name in bpf_subprog_info Eduard Zingerman
2026-04-09 2:14 ` bot+bpf-ci
2026-04-09 21:55 ` Eduard Zingerman
2026-04-09 1:33 ` [PATCH bpf-next 03/14] bpf: Add spis_*() helpers for 4-byte stack slot bitmasks Eduard Zingerman
2026-04-09 3:12 ` bot+bpf-ci
2026-04-09 22:05 ` Eduard Zingerman [this message]
2026-04-09 1:33 ` [PATCH bpf-next 04/14] bpf: make liveness.c track stack with 4-byte granularity Eduard Zingerman
2026-04-09 2:26 ` bot+bpf-ci
2026-04-09 23:21 ` Eduard Zingerman
2026-04-09 1:33 ` [PATCH bpf-next 05/14] bpf: 4-byte precise clean_verifier_state Eduard Zingerman
2026-04-09 1:33 ` [PATCH bpf-next 06/14] bpf: prepare bpf_liveness api for use by static analysis pass Eduard Zingerman
2026-04-09 1:33 ` [PATCH bpf-next 07/14] bpf: introduce forward arg-tracking dataflow analysis Eduard Zingerman
2026-04-09 2:26 ` bot+bpf-ci
2026-04-09 23:28 ` Eduard Zingerman
2026-04-09 1:33 ` [PATCH bpf-next 08/14] bpf: record arg tracking results in bpf_liveness masks Eduard Zingerman
2026-04-09 2:26 ` bot+bpf-ci
2026-04-09 23:32 ` Eduard Zingerman
2026-04-09 1:33 ` [PATCH bpf-next 09/14] bpf: simplify liveness to use (callsite, depth) keyed func_instances Eduard Zingerman
2026-04-09 2:26 ` bot+bpf-ci
2026-04-09 1:33 ` [PATCH bpf-next 10/14] bpf: change logging scheme for live stack analysis Eduard Zingerman
2026-04-09 2:14 ` bot+bpf-ci
2026-04-09 23:34 ` Eduard Zingerman
2026-04-09 1:33 ` [PATCH bpf-next 11/14] selftests/bpf: update existing tests due to liveness changes Eduard Zingerman
2026-04-09 1:33 ` [PATCH bpf-next 12/14] selftests/bpf: adjust verifier_log buffers Eduard Zingerman
2026-04-09 1:33 ` [PATCH bpf-next 13/14] selftests/bpf: add new tests for static stack liveness analysis Eduard Zingerman
2026-04-09 1:33 ` [PATCH bpf-next 14/14] bpf: poison dead stack slots Eduard Zingerman
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=7dd54c3cfab9996661699a10710e24cccc79fef4.camel@gmail.com \
--to=eddyz87@gmail.com \
--cc=andrii@kernel.org \
--cc=ast@kernel.org \
--cc=bot+bpf-ci@kernel.org \
--cc=bpf@vger.kernel.org \
--cc=clm@meta.com \
--cc=daniel@iogearbox.net \
--cc=ihor.solodrai@linux.dev \
--cc=kernel-team@fb.com \
--cc=martin.lau@kernel.org \
--cc=martin.lau@linux.dev \
--cc=yonghong.song@linux.dev \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox