[PATCH] [lld][ELF] Fix debug info handling.

Shankar Easwaran shankare at codeaurora.org
Fri Sep 13 15:56:30 PDT 2013


On 9/13/2013 5:49 PM, Nick Kledzik wrote:
> On Sep 13, 2013, at 3:39 PM, Shankar Easwaran <shankare at codeaurora.org> wrote:
>
>> The comparison would need to be done in the DefinedAtom though, if _contentType == typeCode and _sectionName == ".text" return sectionBasedOnContent.
> No.

Sorry for the confusion, I meant on the ELFReader side as you are 
mentioning(ELFDefinedAtom).

>   
>
> What I am saying is that on the ELF Reader side, if the atom is in a section named “.text”, the atom being constructed would have its sectionChoice set to sectionBasedOnContentnot and it would not be given a section name.  On the ELF Writer side, if an atom has a section choice of sectionBasedOnContent, then the contentType is checked and typeCode implies it should go into the .text section.  And the same for other standard sections like .data and .bss.
>
>> Do you see any other advantage with sectionBasedOnContent ?
> The YAML will be much smaller (no section attributes for most atoms).  The native format will be a little smaller because names like .text and .data won’t need to be encoded.
Completely agree, will make the change in the next patch.

Thanks

Shankar Easwaran

-- 
Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, hosted by the Linux Foundation




More information about the llvm-commits mailing list