[PATCH] Enable linker plugin for windows [was Re: Discussion about merging Go frontend]

Dave Korn dave.korn.cygwin@gmail.com
Sat Oct 30 16:26:00 GMT 2010


On 30/10/2010 11:44, Dave Korn wrote:
> On 29/10/2010 02:31, Ian Lance Taylor wrote:
> 
>> This implements an object file reader/writer which does everything
>> required by LTO and gccgo.  The ELF code works.  I have not tested the
>> Mach-O and COFF code at all beyond compiling it; I hope that somebody
>> else can test those targets and fix them.
>>
>> With this patch, libelf is no longer needed.
> 
>   Almost, but not quite!  The attached patch switches the lto-plugin over to
> use the new objfile reader as well.

>   Bootstrapped and tested all languages except java and ada on
> x86_64-unknown-linux-gnu, no regressions.  There are still a couple of bugs to
> iron out of the COFF-specific part of the objfile reader which I'll have fixed
> later today.
> 
>   OK for trunk (once the objfile changes have gone in)?

  As you'll see elsethread, I fixed the COFF problems.  This is the remaining
chunk of patch required to make the lto-plugin work on cygming targets.

gcc/ChangeLog:

	* gcc.c (PLUGIN_PASSTHROUGH_SPEC): New macro factored out from
	LINK_COMMAND_SPEC.
	(LINK_COMMAND_SPEC): Use it.
	(static_spec_functions[]): Add pass-through-libs entry.
	(pass_through_libs_spec_func): Add related spec function.
	* config/i386/cygming.h (PLUGIN_PASSTHROUGH_SPEC): Define.
	* doc/tm.texi.in (PLUGIN_PASSTHROUGH_SPEC): Document.
	(LINK_COMMAND_SPEC): Mention it.
	* doc/tm.texi: Regenerate.
	* doc/invoke.texi (pass-through-libs): Mention new spec function.

  Taking this for a bootstrap and test cycle now (on top of the objfile
changes).  Assuming no regressions, and one new PASS (the sole LTO test that
exercises -fuse-linker-plugin), and once all the other patches have gone in: OK?

    cheers,
      DaveK

-------------- next part --------------
A non-text attachment was scrubbed...
Name: 2010_10_29_19_53_45_lto-objfile-plugin-part2.diff
Type: text/x-c
Size: 6933 bytes
Desc: not available
URL: <https://gcc.gnu.org/pipermail/gcc/attachments/20101030/e9081b34/attachment.bin>


More information about the Gcc mailing list