[PATCH v1 0/2] Build ID mmap related fixes

Ian Rogers posted 2 patches 1 month, 1 week ago
tools/perf/bench/inject-buildid.c  |  2 +-
tools/perf/builtin-buildid-cache.c |  8 ++--
tools/perf/builtin-inject.c        |  4 +-
tools/perf/tests/sdt.c             |  2 +-
tools/perf/util/build-id.c         |  4 +-
tools/perf/util/debuginfo.c        |  8 +++-
tools/perf/util/dsos.c             |  4 +-
tools/perf/util/symbol-elf.c       |  9 +++--
tools/perf/util/symbol-minimal.c   | 59 +++++++++++++++---------------
tools/perf/util/symbol.c           |  8 ++--
tools/perf/util/symbol.h           |  2 +-
tools/perf/util/synthetic-events.c |  2 +-
12 files changed, 58 insertions(+), 54 deletions(-)
[PATCH v1 0/2] Build ID mmap related fixes
Posted by Ian Rogers 1 month, 1 week ago
Now that build ID mmap is the default I was seeing hangs during event
synthesis in the perftool-testsuite_report. The hang was happening due
to data pages giving block device file paths and opening the file to
read a build ID was blocking in the open. In investigating this issue
a bug in symbol-minimal was found. These 2 patches fix both issues. As
the issues are present in v6.17-rc2, I think it would be worthwhile to
add the patches as v6.17 fixes.

Ian Rogers (2):
  perf symbol-minimal: Fix ehdr reading in filename__read_build_id
  perf symbol: Add blocking argument to filename__read_build_id

 tools/perf/bench/inject-buildid.c  |  2 +-
 tools/perf/builtin-buildid-cache.c |  8 ++--
 tools/perf/builtin-inject.c        |  4 +-
 tools/perf/tests/sdt.c             |  2 +-
 tools/perf/util/build-id.c         |  4 +-
 tools/perf/util/debuginfo.c        |  8 +++-
 tools/perf/util/dsos.c             |  4 +-
 tools/perf/util/symbol-elf.c       |  9 +++--
 tools/perf/util/symbol-minimal.c   | 59 +++++++++++++++---------------
 tools/perf/util/symbol.c           |  8 ++--
 tools/perf/util/symbol.h           |  2 +-
 tools/perf/util/synthetic-events.c |  2 +-
 12 files changed, 58 insertions(+), 54 deletions(-)

-- 
2.51.0.rc2.233.g662b1ed5c5-goog
Re: [PATCH v1 0/2] Build ID mmap related fixes
Posted by Namhyung Kim 1 month, 1 week ago
Hi Ian,

On Fri, Aug 22, 2025 at 05:00:22PM -0700, Ian Rogers wrote:
> Now that build ID mmap is the default I was seeing hangs during event
> synthesis in the perftool-testsuite_report. The hang was happening due
> to data pages giving block device file paths and opening the file to
> read a build ID was blocking in the open. In investigating this issue
> a bug in symbol-minimal was found. These 2 patches fix both issues. As
> the issues are present in v6.17-rc2, I think it would be worthwhile to
> add the patches as v6.17 fixes.

Looks good to me.  I'll add them for v6.17.

Thanks,
Namhyung

> 
> Ian Rogers (2):
>   perf symbol-minimal: Fix ehdr reading in filename__read_build_id
>   perf symbol: Add blocking argument to filename__read_build_id
> 
>  tools/perf/bench/inject-buildid.c  |  2 +-
>  tools/perf/builtin-buildid-cache.c |  8 ++--
>  tools/perf/builtin-inject.c        |  4 +-
>  tools/perf/tests/sdt.c             |  2 +-
>  tools/perf/util/build-id.c         |  4 +-
>  tools/perf/util/debuginfo.c        |  8 +++-
>  tools/perf/util/dsos.c             |  4 +-
>  tools/perf/util/symbol-elf.c       |  9 +++--
>  tools/perf/util/symbol-minimal.c   | 59 +++++++++++++++---------------
>  tools/perf/util/symbol.c           |  8 ++--
>  tools/perf/util/symbol.h           |  2 +-
>  tools/perf/util/synthetic-events.c |  2 +-
>  12 files changed, 58 insertions(+), 54 deletions(-)
> 
> -- 
> 2.51.0.rc2.233.g662b1ed5c5-goog
>