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: What causes the 'BFD: Dwart Error:' ?


PRC wrote:
If I comment out definition of `mydata1' in 1.c, the objdump error disappear as well.
How does this error occur?

Using __attribute__ ((section)) creates a section with data. Your linker script is putting this section data into the bss section. However, a bss section never contains data. Since everything will be forced to zero at run time, there is no point in having any actual data in the bss section. Note that the file offset of the following section is the same as the bss section, since the bss section contains no actual data in the object file.


I think bfd is getting confused, trying to append data to the should- be-empty bss section, and accidentally overwriting the debugging info. This data is all zeros. Leading zeros in the debug info will be ignored, until it gets to non-zero info, which will then fail to parse giving various curious error messages.

Jim


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