Re: [PATCH] perf/annotate: Use architecture-agnostic register limit
From: Arnaldo Carvalho de Melo
Date: Wed Oct 01 2025 - 10:15:11 EST
On Tue, Sep 23, 2025 at 12:11:27PM -0700, Ian Rogers wrote:
> On Tue, Sep 23, 2025 at 10:43 AM Suchit Karunakaran
> <suchitkarunakaran@xxxxxxxxx> wrote:
> >
> > Remove the arch-specific guard around TYPE_STATE_MAX_REGS and define it
> > as 32 for all architectures. The architecture that perf is built on may
> > not match the architecture that produced the perf.data file, so relying
> > on __powerpc__ or similar is fragile. Using 32 as a fixed upper bound is
> > safe since it is greater than the previous maximum of 16.
> > Add a comment to clarify that TYPE_STATE_MAX_REGS is an arch-independent
> > maximum rather than a build-time choice.
> >
> > Suggested-by: Ian Rogers <irogers@xxxxxxxxxx>
> > Signed-off-by: Suchit Karunakaran <suchitkarunakaran@xxxxxxxxx>
>
> Reviewed-by: Ian Rogers <irogers@xxxxxxxxxx>
Thanks, applied to perf-tools-next,
- Arnaldo