This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
Re: DWARF line number table problem when .byte is used for prefix (x86)
> On Tue, Aug 31, 2010 at 06:27:15PM -0700, H.J. Lu wrote:
>> It is
>>
>> http://sourceware.org/bugzilla/show_bug.cgi?id=11802
On Tue, Aug 31, 2010 at 7:11 PM, Daniel Jacobowitz <dan@codesourcery.com> wrote:
> It's also gas/6717.
>
>> I think it is a gcc bug.
>
> Why? ?I disagree.
OK, so there are at least three reports of this problem, only one of
which involves gcc-generated code. That suggests to me that a fix
belongs in gas. If you put a .loc instruction in front of a .byte,
.short, or even a .p2align, it ought to do the right thing.
In response to HJ's comment on bug 11802, yes, people put readonly
constants in text sections, but they shouldn't be putting them
immediately after a .loc instruction.
It seems like the fix should be as simple as adding a call to
dwarf2_emit_insn() in a couple of places, but I'm not sure if it would
need to condition the call on whether we're in a text section or not.
I'll give it a try when I get a chance.
-cary