This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] Fix differing debug-range blocks with/out --dwarf-check


On Wed, Jan 14, 2015 at 8:42 AM, Henderson, Stuart
<Stuart.Henderson@analog.com> wrote:
> Ping.
> https://sourceware.org/ml/binutils/2015-01/msg00019.html
>
> Cheers,
> Stu
>
> -----Original Message-----
> From: binutils-owner@sourceware.org [mailto:binutils-owner@sourceware.org] On Behalf Of Henderson, Stuart
> Sent: Monday, January 05, 2015 12:40 PM
> To: binutils@sourceware.org
> Subject: [PATCH] Fix differing debug-range blocks with/out --dwarf-check
>
> Hello,
> A while back a change was made to not report .debug_ranges blocks, that are referenced twice in .debug_info, as overlaps when we're doing --dwarf-check.  A side-effect of this is that we now show the doubly referenced block once with --dwarf-check and twice without.
>
> e.g. objdump --dwarf=Ranges without --dwarf-check:
> ...
>     000000e8 c100c650 c100c652*
>     000000e8 c100c654 c100c658*
>     000000e8 <End of list>
>     00000100 c100c6a6 c100c748*
>     00000100 c100c750 c100c76a*
>     00000100 c100c772 c100c7fe*
>     00000100 c100c806 c100c80a*
>     00000100 c100c812 c100c8aa*
>     00000100 c100c8b2 c100c988*
>     00000100 <End of list>
>     00000100 c100c6a6 c100c748*
>     00000100 c100c750 c100c76a*
>     00000100 c100c772 c100c7fe*
>     00000100 c100c806 c100c80a*
>     00000100 c100c812 c100c8aa*
>     00000100 c100c8b2 c100c988*
>     00000100 <End of list>
>     00000138 c100c6d0 c100c748*
>     00000138 c100c942 c100c94a*
> ...
>
> objdump --dwarf=Ranges with --dwarf-check:
> ...
>     000000e8 c100c650 c100c652*
>     000000e8 c100c654 c100c658*
>     000000e8 <End of list>
>     00000100 c100c6a6 c100c748*
>     00000100 c100c750 c100c76a*
>     00000100 c100c772 c100c7fe*
>     00000100 c100c806 c100c80a*
>     00000100 c100c812 c100c8aa*
>     00000100 c100c8b2 c100c988*
>     00000100 <End of list>
>     00000138 c100c6d0 c100c748*
>     00000138 c100c942 c100c94a*
>     00000138 <End of list>
> ...
>
> For the sake of consistency, I suggest we always do the latter:
>
> 2015-01-05  Stuart Henderson <shenders@gcc.gnu.org>
>
>         * dwarf.c (display_debug_ranges): Don't report the same .debug_ranges
>         block twice.
>
> Stu

Can you add a testcase, similar to binutils/testsuite/binutils-all/dw2-1.S?

-- 
H.J.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]