Re: [PATCH v5 0/6] perf annotate-data: Fix hangs on broken debug info, AMD mem record
From: Arnaldo Carvalho de Melo
Date: Fri Sep 25 2026 - 11:59:15 EST
On Fri, Sep 25, 2026 at 08:46:05AM -0700, Namhyung Kim wrote:
> On Fri, Sep 25, 2026 at 05:06:51PM +0200, Arnaldo Carvalho de Melo wrote:
> > Hi,
> >
> > This originated in another patch series, 'perf tools: Annotate fixes,
> > stdio progress indication, debuginfo-client in more places', and is
> > being split off so that these fixes can be reviewed right away; the
> > debuginfod download feature work from it will come later, separately,
> > based on this series.
> >
> > - 'perf report -s type' spins forever on the dwz compressed debug info of
> > zlib-ng (libz.so.1): die_collect_vars() saves a type DIE offset that is
> > relative to the file the DIE lives in, the dwz alt file for types shared
> > by several CUs, and resolving it in the main file parses whatever is at
> > that offset, here a typedef whose DW_AT_type refers to itself, making the
> > typedef/qualifier chase spin (patch 3), with the chases bounded so that
> > other kinds of broken debug info don't hang perf either (patches 1, 2
> > and 4);
> >
> > - 'perf mem record' requests PERF_SAMPLE_CPU (patch 5) and uses the IBS
> > swfilt filter when the kernel exposes it (patch 6), with the tables
> > carrying the term kept in the arch/x86 code, where the knowledge that
> > IBS needs it stays, as Ravi Bangoria suggested reviewing Namhyung
> > Kim's v6 review remark on this patch
> > (<4349c387-5b8a-4e8d-932a-5175a7598e1e@xxxxxxx>, replying to
> > <aqsRVABj23jaaiSq@xxxxxxxxxx>).
> >
> > About PATCH 5, answering Namhyung Kim's v6 review question
> > (<aqsPKGVUkWk6wvYA@xxxxxxxxxx>) about the --sample-cpu default: the
> > data source field is about the memory hierarchy level of the access,
> > it has no record of which CPU issued it, and while the TID is in
> > every sample and in the CTF stream, a thread time-sliced on one CPU
> > or moved between SMT siblings is not told apart by it from cross-core
> > contention, so it is the CPU id that keys it, and it is what the
> > false-sharing detector in pahole needs. The TID is recorded as well.
> >
> > Requires elfutils 0.160 for dwarf_cu_getdwarf(), so the libdw feature test
> > probes for it and Makefile.config says 0.160: older versions now disable
> > dwarf support with that message instead of failing to link.
>
> I have a nitpick on the patch 4, but otherwise looks good to me.
>
> Reviewed-by: Namhyung Kim <namhyung@xxxxxxxxxx>
I'm fixing that one, thanks for reviewing!
- Arnaldo