[PATCH] [lld] ELF: Initial implementation for ARM static linking

Denis Protivensky dprotivensky at accesssoftek.com
Thu Nov 27 23:18:31 PST 2014


Hi,

The updated patch with addressed notes is attached:
- emulation name changed to "armelf_linux_eabi"
- corrected comment referencing x86_64 instead of ARM
- TODO list is added
- test case written with elfyaml is added

- Denis.


On 11/26/2014 05:01 PM, Will Newton wrote:

On 26 November 2014 at 12:17, Denis Protivensky
<dprotivensky at accesssoftek.com><mailto:dprotivensky at accesssoftek.com> wrote:
> Hi,
>
> The patch contains the skeleton code for ELF binary generation for ARM platform.
> The code is "almost" able to statically link the simplest case of void main() { return 0; } sample.

Do you know what functionality is missing to enable that?

> Added all needed relocations, GOT and TLS handling.
> Some of these may still be improper which causes segfaults.
>
> NOTE: the tests are absent because there's no simple way to generate diff for binary files (which are used in tests by the linker).

Is it possible to use ELFYAML for the tests similarly to e.g. the MIPS
backend? I recently posted a patch to add ARM support to ELFYAML.

A couple of things I noticed:

1. GNU ld seems to use "armelf_linux_eabi" for the emulation name
rather than "armlinux"
2. One comment reference to x86-64 that should be ARM
3. It would be useful to add a TODO list that lists all the known
unimplemented parts

Otherwise this looks like a good start!

--
Will Newton
Toolchain Working Group, Linaro

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20141127/8a586eb4/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: elf.arm.patch
Type: text/x-patch
Size: 63311 bytes
Desc: elf.arm.patch
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20141127/8a586eb4/attachment.bin>


More information about the llvm-commits mailing list