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: [patch] PR ld/11817 Revert part of compressed debug patch to fix ld breakage


Hi Cary,

I updated the branch. Reading compress debug sections should work now.

On Fri, Jul 16, 2010 at 3:19 PM, Cary Coutant <ccoutant@google.com> wrote:
>>> I was thinking the right way to do this would probably be to keep the
>>> section name unchanged, but change the section type from SHT_PROGBITS
>>> to SHT_GNU_COMPRESSED_BITS.
>>
>> Doing this may trigger more changes. In theory, ?no one should
>> depend on section name. You can get the original section name
>> by checking the new decompressed bit.
>
> Sorry, I didn't finish the thought, and I don't think it was clear
> what I meant. I meant that, if I were doing this from scratch, instead
> of naming the compressed sections ".zdebug_info", etc., I'd have kept
> the names unchanged, but changed the section type from SHT_PROGBITS to
> SHT_GNU_COMPRESSED_BITS in the ELF section table, and readers would
> have known that decompression was necessary based on the section type
> instead of the section name (agreeing with your assertion that no one
> should depend on the section name). I'd have changed gas to output the
> new section type when compressing, and changed bfd and gold to
> decompress any SHT_GNU_COMPRESSED_BITS section.

That sounds better if we don't have to worry about the older tools.

> I think that would have been more elegant, but it would have probably
> been a more difficult transition, as older tools would not have
> gracefully ignored the compressed sections.
>

That is true.

Thanks.


-- 
H.J.


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