[PATCH v2 4/4] gdb/dwarf: fix reading DW_FORM_addrx with address size of 2
Project / Subsystem
binutils / gdb/dwarf
Date
2026-09-21
Proposer
Simon Marchi <simon.marchi@efficios.com>
Source type
public_inbox
Consensus
Proposed
Sentiment
—/10
Technical tradeoffs
- • Ensuring correct handling of various DWARF forms and address sizes is crucial for debugger stability.
- • Fixing a specific bug on one architecture (AVR) might reveal or require broader changes to DWARF parsing logic.
All attributes
- project
- binutils
- subsystem
- gdb/dwarf
- patch_id
- —
- discussion_id
- 20260921173951.688121-5-simon.marchi@efficios.com
- source_type
- public_inbox
- title
- [PATCH v2 4/4] gdb/dwarf: fix reading DW_FORM_addrx with address size of 2
- headline
- gdb/dwarf: fix reading DW_FORM_addrx with address size of 2
- tldr
- Patch fixes a GDB crash when reading DW_FORM_addrx debug info with a 2-byte address size, discovered while investigating AVR binaries.
- proposer
- Simon Marchi <simon.marchi@efficios.com>
- consensus
- Proposed
- outcome
- proposed
- sentiment_score
- —
- technical_tradeoffs
-
- • Ensuring correct handling of various DWARF forms and address sizes is crucial for debugger stability.
- • Fixing a specific bug on one architecture (AVR) might reveal or require broader changes to DWARF parsing logic.
- series_id
- binutils:gdb/dwarf: fix reading dw_form_addrx with address size of 2
- series_role
- reply
- series_parts
- []
- tags
-
- • GDB
- • DWARF
- • debugging
- • AVR
- • buffer overflow
- bugzilla_url
- —
- date
- 2026-09-21T00:00:00.000Z
[PATCH v2 4/4] gdb/dwarf: fix reading DW_FORM_addrx with address size of 2
Simon Marchi submits a patch addressing a GDB crash encountered when processing DWARF debug information, specifically with DW_FORM_addrx entries and a 2-byte address size. The issue was found during an investigation of AVR binaries generated by clang. The crash occurred due to a heap-buffer-overflow in bfd_getl64 when reading address indices, indicating an incorrect handling of address size when decoding this DWARF form.