In dso__load_sym we only try to load the .debug_frame section from the runtime image. For distros, the debug symbols are generally in a separate file.
As a result, running perf report on arm64 can give errors such as: "$file with build id $id not found, continuing without symbols" Even when the debug symbols have been correctly installed (and loaded by perf). This patch adds logic to dso__load_sym to query syms_ss for the .debug_frame section if it can't be found in the elf file pointed to by runtime_ss. Signed-off-by: Steve Capper <steve.cap...@linaro.org> --- This patch is against 3.18-rc5. --- tools/perf/util/symbol-elf.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/tools/perf/util/symbol-elf.c b/tools/perf/util/symbol-elf.c index 1e23a5b..1336392 100644 --- a/tools/perf/util/symbol-elf.c +++ b/tools/perf/util/symbol-elf.c @@ -830,8 +830,11 @@ int dso__load_sym(struct dso *dso, struct map *map, continue; sec = elf_getscn(runtime_ss->elf, sym.st_shndx); - if (!sec) - goto out_elf_end; + if (!sec) { + sec = elf_getscn(syms_ss->elf, sym.st_shndx); + if (!sec) + goto out_elf_end; + } gelf_getshdr(sec, &shdr); -- 1.9.3 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/