This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH][PR sanitizer/77631] Support separate debug info in libbacktrace
- From: Matthias Klose <doko at ubuntu dot com>
- To: Richard Biener <richard dot guenther at gmail dot com>, Denis Khalikov <d dot khalikov at partner dot samsung dot com>, Ian Lance Taylor <iant at google dot com>
- Cc: GCC Patches <gcc-patches at gcc dot gnu dot org>
- Date: Tue, 14 Mar 2017 10:22:53 +0100
- Subject: Re: [PATCH][PR sanitizer/77631] Support separate debug info in libbacktrace
- Authentication-results: sourceware.org; auth=none
- References: <CGME20170313171637eucas1p2d70c4ed7cbd6d088c8c58dc76e1ef722@eucas1p2.samsung.com> <2d276071-3570-0a00-d046-29d5b84f2b7f@partner.samsung.com> <CAFiYyc3GBGFym5Sv8DBurFmKPUmRpO6LTMgQFACqNpBMJQZSeg@mail.gmail.com>
On 14.03.2017 09:27, Richard Biener wrote:
> On Mon, Mar 13, 2017 at 6:16 PM, Denis Khalikov
> <d.khalikov@partner.samsung.com> wrote:
>> Hello everyone, i have a patch for this issue.
>
> Great!
>
>> List of implemented functionality:
>>
>> 1.Reading .gnu_debuglink section from ELF file:
>> a. Reading name of debug info file.
>> b. Verifying crc32 sum.
>>
>> 2. Searching for separate debug info file from paths:
>> a. /usr/lib/debug/path/to/executable
>> b. /path/to/executable
>> c. /path/to/executable/.debug
>>
>> Assumed that debug info file generated by objcopy from binutils.
>>
>> objcopy --only-keep-debug foo foo.debug
>> strip -g foo
>> objcopy --add-gnu-debuglink=foo.debug foo
These days using the build-id for separate debug info seems to be the new way of
doing that, so adding support for the build-id method would be useful. See PR
binutils/20876 for how binutils is doing that.
Matthias