[gold] PATCH: PR gold/14993: Section sorting interferes with the incremental update
Cary Coutant
ccoutant@google.com
Thu Jan 3 19:48:00 GMT 2013
More information about the Binutils mailing list
Thu Jan 3 19:48:00 GMT 2013
- Previous message (by thread): [gold] PATCH: PR gold/14993: Section sorting interferes with the incremental update
- Next message (by thread): [gold] PATCH: PR gold/14993: Section sorting interferes with the incremental update
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
> We set negative section offset in Input_section::set_address_and_file_offset, > when storing section offset as an address. Although it is overridden by > Sized_relobj_file<size, big_endian>::layout_section later, the negative > offset doesn't work on x32 since a section offset (18446744073709551050 > == 0xFFFFFFFFFFFFFDCA == -3530) that doesn't fit in a 32-bit Address. > This patch changes negative offset to -1, which is converted to > invalid_address. Tested it on x86-64, x32 and ia32. OK to install? I don't think the negative file offset should be happening in the first place, and it seems to be caused by the fact that we've turned on input section tracking for .text. With an incremental update, the offset assigned in Output_section::add_input_section should be final (and non-negative), and it shouldn't be overridden later in Sized_relobj_file::layout_section. I think the right solution is to suppress section sorting during an incremental update -- the two are fundamentally incompatible. I'll take a closer look at this. > + if (file_offset < 0) > + file_offset = static_cast<off_t>(-1); No need for the cast here. Thanks for the analysis. -cary
- Previous message (by thread): [gold] PATCH: PR gold/14993: Section sorting interferes with the incremental update
- Next message (by thread): [gold] PATCH: PR gold/14993: Section sorting interferes with the incremental update
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Binutils mailing list