coff section flags: STYP_COPY, in particular, for TI COFF files
John E Hein
jhein@timing.com
Sat Apr 5 00:48:00 GMT 2003
I am looking into supporting the TMS320C6x
(c6x-tools.sourceforge.net), and I've found that the COFF files
generated by TI's compiler (Code Composer Studio) include some
sections flagged by STYP_COPY.
This is not handled in bfd/coffcode.h
Sections flagged by STYP_COPY are to be relocated and loaded, but not
allocated. For instance, there's a .vers section that has section
flags 0x50 (STYP_COPY | STYP_DATA). binutils marks these with
SEC_LOAD & SEC_ALLOC (loaded & allocated).
In recent TI tools (CCS 2.20), there's another section ($BRID) which
has the same problem.
Note that the c54x support that is now included in binutils has the
same flaw.
There are also problems with STYP_DSECT (not handled by binutils in
sec_to_styp_flags()) and also with STYP_PAD (should be loaded, but not
marked by binutils with SEC_LOAD). But I haven't seen a COFF file
generated by the TI tools that have the STYP_DSECT nor STYP_PAD flags
set (yet).
Attached is a patch. Comments?
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: patch
URL: <https://sourceware.org/pipermail/binutils/attachments/20030405/01709a3a/attachment.ksh>
More information about the Binutils
mailing list