[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Bug gprofng/30093] New: gprofng SIGSEGV when processing unusual dwarf
From: |
gilles.m.duboscq at gmail dot com |
Subject: |
[Bug gprofng/30093] New: gprofng SIGSEGV when processing unusual dwarf |
Date: |
Tue, 07 Feb 2023 08:39:58 +0000 |
https://sourceware.org/bugzilla/show_bug.cgi?id=30093
Bug ID: 30093
Summary: gprofng SIGSEGV when processing unusual dwarf
Product: binutils
Version: 2.41 (HEAD)
Status: UNCONFIRMED
Severity: normal
Priority: P2
Component: gprofng
Assignee: vladimir.mezentsev at oracle dot com
Reporter: gilles.m.duboscq at gmail dot com
Target Milestone: ---
When running gprofng display text on some executables that contain unusual
dwarf data I am getting a segfault.
In particular, the input dwarf has some compilation units (DW_TAG_compile_unit)
that have neither DW_AT_comp_dir nor DW_AT_stmt_list.
The issue is that when that happens, DwrCU::stmt_list_offset remains 0, as a
result, in Dwarf::archive_Dwarf, the `get_dwrLineReg` call will process
whatever is at offset 0 in .debug_line.
Then while looking for source files, `DwrLineRegs::getPath` will potentially
try to use include_directories->fetch (0) which is NULL (no comp_dir
attribute).
This leads to a segfault in StringBuilder::append.
For reference, discussion on the dwarf-producing side:
https://github.com/oracle/graal/issues/5907
--
You are receiving this mail because:
You are on the CC list for the bug.
- [Bug gprofng/30093] New: gprofng SIGSEGV when processing unusual dwarf,
gilles.m.duboscq at gmail dot com <=