All of lore.kernel.org
 help / color / mirror / Atom feed
From: sashiko-bot@kernel.org
To: "James Clark" <james.clark@linaro.org>
Cc: linux-perf-users@vger.kernel.org
Subject: Re: [PATCH v2 07/14] perf arm-spe: Use generic snapshot search
Date: Fri, 21 Aug 2026 09:57:54 +0000	[thread overview]
Message-ID: <20260821095755.319B31F000E9@smtp.kernel.org> (raw)
In-Reply-To: <20260821-james-cs-unformatted-per-thread-fix-v2-7-00c4fd0701b4@linaro.org>

> The new generic snapshot search gives a similar result as the
> reimplemented version of it here. One slight difference is in the
> pointer fixup. SPE has:
> 
>   *head += mm->len;
>   *old = *head - mm->len;
> 
> Which gives exactly the same result but written in reverse order to the
> generic one:
> 
>   *old = *head;
>   *head += mm->len;
> 
> SPE also had a special fixup case for head pointers greater than the
> buffer length, which is not needed because the SPE driver always wraps
> them, and __auxtrace_mmap__read() handles that anyway. It also didn't
> have the special case for old > head for when the wrap heuristic fails
> but the pointers showed a wrap had happened.
> 
> The other feature lost is that this search only looked from head to the
> end of the buffer, rather than always at the last 512 bytes. This was
> flawed because once head is close to the end, it's likely it could
> contain zero padding from actual SPE data and a wrap would be missed.
> It's better to err on the side of caution and mark as a wrap, rather
> than trying to optimize by limiting the search from head onwards.
> 
> Signed-off-by: James Clark <james.clark@linaro.org>

Sashiko has reviewed this patch and found no issues. It looks great!

-- 
Sashiko AI review · https://sashiko.dev/#/patchset/20260821-james-cs-unformatted-per-thread-fix-v2-0-00c4fd0701b4@linaro.org?part=7


  reply	other threads:[~2026-08-21  9:57 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-08-21  9:48 [PATCH v2 00/14] perf cs-etm: Per-thread mode fixes and snapshot wrap support James Clark
2026-08-21  9:48 ` [PATCH v2 01/14] perf cs-etm: Fix nVHE per-thread decoding James Clark
2026-08-21 10:00   ` sashiko-bot
2026-08-21  9:49 ` [PATCH v2 02/14] perf cs-etm: Warn for invalid timestamp option James Clark
2026-08-21  9:56   ` sashiko-bot
2026-08-21  9:49 ` [PATCH v2 03/14] perf cs-etm: Turn on context packet timestamps in per-thread mode James Clark
2026-08-21 10:01   ` sashiko-bot
2026-08-21 10:09     ` James Clark
2026-08-21  9:49 ` [PATCH v2 04/14] perf cs-etm: Use per-CPU queues for " James Clark
2026-08-21 10:04   ` sashiko-bot
2026-08-21  9:49 ` [PATCH v2 05/14] perf cs-etm: Increase default timestamp generation period James Clark
2026-08-21  9:58   ` sashiko-bot
2026-08-21  9:49 ` [PATCH v2 06/14] perf auxtrace: Turn Intel BTS snapshot search into a generic one James Clark
2026-08-21 10:00   ` sashiko-bot
2026-08-21  9:49 ` [PATCH v2 07/14] perf arm-spe: Use generic snapshot search James Clark
2026-08-21  9:57   ` sashiko-bot [this message]
2026-08-21  9:49 ` [PATCH v2 08/14] perf auxtrace: intel-pt: Use new snapshot_has_wrapped callback James Clark
2026-08-21 10:00   ` sashiko-bot
2026-08-21  9:49 ` [PATCH v2 09/14] perf cs-etm: Queue partial AUX records James Clark
2026-08-21  9:56   ` sashiko-bot
2026-08-21  9:49 ` [PATCH v2 10/14] perf cs-etm: Don't print missing buffers in snapshot mode James Clark
2026-08-21 10:01   ` sashiko-bot
2026-08-21  9:49 ` [PATCH v2 11/14] perf auxtrace: cs-etm: Capture wrapped snapshots James Clark
2026-08-21 10:00   ` sashiko-bot
2026-08-21  9:49 ` [PATCH v2 12/14] perf test: Allow infinite named_thread loops James Clark
2026-08-21 10:03   ` sashiko-bot
2026-08-21  9:49 ` [PATCH v2 13/14] perf test: Add test for per-thread mode James Clark
2026-08-21 10:04   ` sashiko-bot
2026-08-21  9:49 ` [PATCH v2 14/14] perf cs-etm: Test multiple per-thread threads James Clark
2026-08-21 10:40   ` sashiko-bot

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=20260821095755.319B31F000E9@smtp.kernel.org \
    --to=sashiko-bot@kernel.org \
    --cc=james.clark@linaro.org \
    --cc=linux-perf-users@vger.kernel.org \
    --cc=sashiko-reviews@lists.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.