This is the mail archive of the
elfutils-devel@sourceware.org
mailing list for the elfutils project.
Re: Some dwarf "nitpicks"
- From: Roland McGrath <roland at redhat dot com>
- To: elfutils-devel at lists dot fedorahosted dot org
- Date: Wed, 09 Mar 2011 10:34:46 -0800
- Subject: Re: Some dwarf "nitpicks"
> Ah, yes. That is what I thought first too. But gcc is sneaky :)
> If gcc detects gas has support for the .loc directive, it will not
> output the section itself, but let gas generate it (because the
> assembler has exact info on instruction sizes).
Sure, but there is no .loc in there! In fact, it's gas that is quite
sneaky here.
/* If there is no line information and no non-empty .debug_info
section, or if there is both a non-empty .debug_info and a non-empty
.debug_line, then we do nothing. */
So its the presence of some .section .debug_info content (even without any
.file, let alone .loc) that makes it emit the .debug_line header.
If there is a bug here, it's a gas bug.
Thanks,
Roland