Re: [PATCH] perf llvm: Clean up after a failed disassembly
From: Arnaldo Carvalho de Melo
Date: Wed Mar 04 2026 - 17:18:47 EST
On Wed, Mar 04, 2026 at 01:10:02PM -0800, Peter Collingbourne wrote:
> On Tue, Mar 3, 2026 at 3:29 PM Ian Rogers <irogers@xxxxxxxxxx> wrote:
> >
> > On Tue, Mar 3, 2026 at 3:00 PM Peter Collingbourne <pcc@xxxxxxxxxx> wrote:
> > >
> > > An error returned from a failed backend will cause perf to call the next
> > > backend. If the error happens mid-function, e.g. due to an unrecognized
> > > instruction, we will end up with duplicated instructions in the output
> > > unless the backend that failed deletes any instructions that it created
> > > before failing. The capstone backend was already doing this but the LLVM
> > > backend was not; fix it.
> > >
> > > Link: https://linux-review.googlesource.com/id/I377eef3cd662ab98fbcd69e5004a259fa3d7aa06
> > > Signed-off-by: Peter Collingbourne <pcc@xxxxxxxxxx>
> >
> > Reviewed-by: Ian Rogers <irogers@xxxxxxxxxx>
>
> Thanks for the review. I guess this one should have also had
>
> Fixes: 048856817888 ("perf annotate: LLVM-based disassembler")
Thanks, applied to perf-tools, for v7.0.
- Arnaldo