This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH, bootstrap]: Add bootstrap-lto-noplugin build configuration (PR65537)
- From: Jan Hubicka <hubicka at ucw dot cz>
- To: Uros Bizjak <ubizjak at gmail dot com>
- Cc: "gcc-patches at gcc dot gnu dot org" <gcc-patches at gcc dot gnu dot org>
- Date: Thu, 26 Mar 2015 02:11:48 +0100
- Subject: Re: [PATCH, bootstrap]: Add bootstrap-lto-noplugin build configuration (PR65537)
- Authentication-results: sourceware.org; auth=none
- References: <CAFULd4bu3nLimG5WvWa=8=7w+G=uV3+F0iHLJELTq=qDgGut=A at mail dot gmail dot com>
> Hello!
>
> Attached patch introduces bootstrap-lto-noplugin bootstrap
> configuration for hosts that do not support linker plugin (e.g. CentOS
> 5.11 with binutils 2.17). Also, the patch adds some additional
> documentation to bootstrap-lto option.
>
> config/ChangeLog:
>
> 2015-03-24 Uros Bizjak <ubizjak@gmail.com>
>
> PR bootstrap/65537
> * bootstrap-lto-noplugin.mk: New build configuration.
>
> gcc/ChangeLog:
>
> 2015-03-24 Uros Bizjak <ubizjak@gmail.com>
>
> PR bootstrap/65537
> * doc/install.texi (Building a native compiler): Document new
> bootstrap-lto-noplugin configuration. Mention that bootstrap-lto
> configuration assumes that the host supports the linker plugin.
>
> Patch was bootstrapped and tested on x86_64-linux-gnu (CentOS 5.11)
> host, configured with --with-build-config=bootstrap-lto build
> configuration.
>
> OK for mainline?
> Index: gcc/doc/install.texi
> ===================================================================
> --- gcc/doc/install.texi (revision 221636)
> +++ gcc/doc/install.texi (working copy)
> @@ -2519,8 +2519,14 @@
> @item @samp{bootstrap-lto}
> Enables Link-Time Optimization for host tools during bootstrapping.
> @samp{BUILD_CONFIG=bootstrap-lto} is equivalent to adding
> -@option{-flto} to @samp{BOOT_CFLAGS}.
> +@option{-flto} to @samp{BOOT_CFLAGS}. This option assumes that the host
> +supports the linker plugin (e.g. GNU ld version 2.21 or later or GNU gold
> +version 2.21 or later).
>
> +@item @samp{bootstrap-lto-noplugin}
> +This option is similar to @code{bootstrap-lto}, but is intended for
> +hosts that do not support the linker plugin.
Can you, please, add a note that without linker plugin the static libraries are
not compiled with linktime optimization. Because GCC middle-end and backend is
in libbackend.a it means that only (part of) the frontend is actually LTO
optimized?
Currently it seems bit too welcoming to skip the linker update.
Honza
> +
> @item @samp{bootstrap-debug}
> Verifies that the compiler generates the same executable code, whether
> or not it is asked to emit debug information. To this end, this