This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Making it easy to use -flto for bootstrap


On Thu, Jun 17, 2010 at 9:32 PM, Eric Botcazou <ebotcazou@adacore.com> wrote:
>> Furthermore, simply adding -flto to BOOT_CFLAGS didn't quite work,
>> because Ada doesn't seem to be ready for LTO.
>
> No, it's supposed to work on mainline, there are LTO tests in gnat.dg.

LTO bootstrap indeed fails with Ada (first you run into ICEs due
to -g, then if building without that you get incompatible types of
global syms inside the RTS for some Ada to C bindings if I
understand correctly).

To reproduce:

../configure --enable-stage1-languages=c,lto --enable-gold
--with-plugin-ld=/usr/bin/gold
make BOOT_CFLAGS="-O2 -g -fuse-linker-plugin -fwhopr -B
/path-to-build/prev-lto-plugin/.libs"

same with -flto, for convenience parallelize link with -fwhopr=N.  Add
STAGE1_CFLAGS="-O2 -g" for your convenience.

It would be nice to have small reproducers for the -g ICEs.

Richard.

> --
> Eric Botcazou
>


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]