This is the mail archive of the
elfutils-devel@sourceware.org
mailing list for the elfutils project.
Re: [PATCH] readelf: Find skeleton units when inspecting split .dwo (--dwarf-skeleton).
- From: Mark Wielaard <mark at klomp dot org>
- To: elfutils-devel at sourceware dot org
- Date: Mon, 28 May 2018 17:23:33 +0200
- Subject: Re: [PATCH] readelf: Find skeleton units when inspecting split .dwo (--dwarf-skeleton).
- References: <1527252224-21660-1-git-send-email-mark@klomp.org>
On Fri, 2018-05-25 at 14:43 +0200, Mark Wielaard wrote:
> To get the right context (especially addresses) when looking at a .dwo file
> we really need the skeleton file. If we can find it (simply replace .dwo
> with .o) then use that to get to the split DWARF units so that libdw sets
> up all relevant information to resolve.
>
> Also adds a --dwarf-skeleton option so the user can explicitly give a
> skeleton file to use (for example when all .o files are linked and removed
> already). Unfortunately this might not work if libdw cannot get from the
> skeleton file to the .dwo file (because they have been moved around).
> In that case eu-readelf "cheats", it will link up the libdw datastructures
> so that the skeleton and split DWARF units are setup correctly anyway.
> This does introduce a problem when trying to cleanup the Dwarf handle
> ownership graph. So we will deliberately leak memory by not closing the
> underlying Dwfl in that case.
Pushed to master.