[PATCH 0 of 3] Add support for using gold instead of ld

Bryan Hundven bryanhundven@gmail.com
Tue Dec 28 19:11:00 GMT 2010


On Tue, Dec 28, 2010 at 10:02 AM, Yann E. MORIN
<yann.morin.1998@anciens.enib.fr> wrote:
> Bryan, Arnaud, All,
>
> On Tuesday 28 December 2010 01:18:06 Bryan Hundven wrote:
>> On Mon, Dec 27, 2010 at 3:58 PM, Arnaud Lacombe <lacombar@gmail.com> wrote:
>> > That is incomplete You also need to pass --enable-gold to gcc's
>> > configure to build the linker plugin.
>> Right. Is this only when ld.gold is ld?
>> Or just when gold is enabled at all.
>
> Indeed, what happens if binutils is configured with both ld and gold, but
> ld is the default? Or when I configure binutils without gold, but configure
> gcc to enable gold?
>
> Does gcc directly calls to ld.gold, or still calls to ld?
>
> Defintitely, the gcc documentation is not explicit...

It sounds like we have some testing to do, or if anyone out there can
explain this behavior it will save some cpu cycles...

> For now, I'll consider that --enable-gold will only build the lto plugin...

Again. --enable-gold has been in gcc since 4.4, so --enable-gold just
makes gcc use the gold linker.

If it isn't available, I'd guess that gcc's configure would bomb out
because either ld.gold doesn't exist or ld doesn't look like a gold
linker.

LTO is in gcc 4.5 and greater, and it just so happens that binutils
gained support for building linker plugins in 2.21...

Maybe specific versions of binutils should be paired with specific
versions of gcc.

> Regards,
> Yann E. MORIN.
>
> --
> .-----------------.--------------------.------------------.--------------------.
> |  Yann E. MORIN  | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
> | +33 662 376 056 | Software  Designer | \ / CAMPAIGN     |  ___               |
> | +33 223 225 172 `------------.-------:  X  AGAINST      |  \e/  There is no  |
> | http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL    |   v   conspiracy.  |
> '------------------------------^-------^------------------^--------------------'
>

-Bryan

--
For unsubscribe information see http://sourceware.org/lists.html#faq



More information about the crossgcc mailing list