Sure, more information that way is useful. Sending a patch is always
appreciated.
-eric
On Thu Oct 30 2014 at 8:46:52 AM Colin LeMahieu <colinl at codeaurora.org>
wrote:
> We had a need for calculating an ELF section load address, essentially the
> LMA address printed out from GNU objdump with the –h option:
>
> Sections:
> Idx Name Size VMA LMA File off Algn
> 0 .start 00003dc0 00000000 00000000 00001000 2**6
>
> It looks like GNU binutils calculates this by applying the delta between
> the
> vaddr and paddr of the section's enclosing segment.
>
> I implemented this inside llvm-readobj:
>
> Section {
> Index: 30
> Name: .strtab (9)
> Type: SHT_STRTAB (0x3)
> Flags [ (0x0)
> ]
> Address: 0x0
> Load Address: 0x0
> Offset: 0x64FF88
> Size: 2689979
> Link: 0
> Info: 0
> AddressAlignment: 1
> EntrySize: 0
> }
>
> Is there interest in this being upstreamed? It's a small patch.
>
> Is this the best place to put this information inside of llvm-readobj and
> underneath the 'Address:' line. If there's a better place let
me know.
>
> Qualcomm Innovation Center, Inc.
> The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum,
> a Linux Foundation Collaborative Project
>
>
>
> _______________________________________________
> LLVM Developers mailing list
> LLVMdev at cs.uiuc.edu http://llvm.cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL:
<http://lists.llvm.org/pipermail/llvm-dev/attachments/20141030/3bcdd455/attachment.html>