Hi Aaron,

On Tue, Feb 27, 2024 at 08:11:39PM -0500, Aaron Merey wrote:
> __libdw_getdieranges builds an aranges list by iterating over each
> CU and recording each address range.
> 
> This function is an alternative to dwarf_getaranges.  dwarf_getaranges
> attempts to read address ranges from .debug_aranges, which might be
> absent or incomplete.
> 
> This patch replaces dwarf_getaranges with __libdw_getdieranges in
> dwarf_addrdie and dwfl_module_addrdie.  The existing tests in
> run-getsrc-die.sh are also rerun with .debug_aranges removed from
> the testfiles.
> 
> https://sourceware.org/bugzilla/show_bug.cgi?id=22288
> https://sourceware.org/bugzilla/show_bug.cgi?id=30948
> 
> Signed-off-by: Aaron Merey <ame...@redhat.com>
> ---
> 
> v2 addresses feedback from Mark's review:
> https://sourceware.org/pipermail/elfutils-devel/2024q1/006853.html
> 
> Avoid calling free on arangelist when it's possibly corrupt.
> Run tests in run-getsrc-die.sh twice, once with .debug_aranges
> present in the testfile and once with the section removed.

This looks good to me.
Please also add a NEWS entry about this.

Thanks,

Mark

Reply via email to