[lld] Support for PECOFF in gnu ld mode

Martell Malone martellmalone at gmail.com
Sun Jun 7 22:48:53 PDT 2015


Hi Rui,

The first and the second patches look good. They just add __image_base__ as
> an alias for __ImageBase (I don't know why mingw uses different symbols
> than regular Windows symbols, though).


Great then we are off to a good start :)

The rest is to support COFF files with GNU command line driver. I don't
> know if we want to support that. Do you think even if we have a complete
> link.exe-compatible linker, we still want to use GNU ld-compatible COFF
> linker on Windows?


Yes I am certain this will be wanted.
Any mingw-w64 user / developer would never touch link.exe and expect an ld
compatable linker.
There are many cross platform projects that do this, to give an example the
vlc media player does.
Currently these projects use gcc and binutils and I would like to push them
in the direction of clang and lld :)

I think I have it separated out really well not to affect the ELF linker.
It doesn't add much to the code because of how well you guys have the
classes structured :)


On Mon, Jun 8, 2015 at 4:45 AM, Rui Ueyama <ruiu at google.com> wrote:

> Hi Martell,
>
> The first and the second patches look good. They just add __image_base__
> as an alias for __ImageBase (I don't know why mingw uses different symbols
> than regular Windows symbols, though).
>
> The rest is to support COFF files with GNU command line driver. I don't
> know if we want to support that. Do you think even if we have a complete
> link.exe-compatible linker, we still want to use GNU ld-compatible COFF
> linker on Windows?
>
> On Sun, Jun 7, 2015 at 7:12 PM, Martell Malone <martellmalone at gmail.com>
> wrote:
>
>> Hi All,
>>
>> I have added support for PECOFF in gnu ld mode.
>> Currently it now works to create x86_64 executable for mingw-w64.
>>
>> I'm not sure what the review process for lld involves or where i should
>> send my series of patches so advice going forward would be appreciated as I
>> plan to work on lld a lot over the next while.
>>
>> I am having link errors still on armv7 and i686 that I would love some
>> help with :)
>> Attached are the patches and buildlogs for simple hello world programs
>> under both i686 and x86_64 insight into the i686 link errors would be great
>> :)
>> I already know that i686 prepends an underscore to all symbol names but I
>> don't think this is the cause other devs may know more which is why I ask
>>
>> Kind Regards
>> Martell
>>
>>
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20150608/a21317c3/attachment.html>


More information about the llvm-commits mailing list