This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [texi, LTO]: Mention that -flto and -fwhole-program can be used simultaneously
- From: Diego Novillo <dnovillo at google dot com>
- To: Tobias Burnus <burnus at net-b dot de>
- Cc: gcc-patches at gcc dot gnu dot org
- Date: Mon, 5 Oct 2009 13:44:45 -0400
- Subject: Re: [texi, LTO]: Mention that -flto and -fwhole-program can be used simultaneously
- References: <20091005162613.GA29241@net-b.de>
On Mon, Oct 5, 2009 at 12:26, Tobias Burnus <burnus@net-b.de> wrote:
> Hi all,
>
> I had the impression that it is not obvious that -fwhole-program can be
> applied simultaneously -- and that one may think that -flto already
> does the -fwhole-program optimizations as it sees the whole program
> (which is not the case).
>
> I therefore propose to add a note to the manual as proposed below.
> OK for the trunk? Or do you have a better suggestion for the wording?
I would rather mention in the -flto entry that -flto does not imply
-fwhole-program. Something along the lines of "link time
optimizations do not require the presence of the whole program to
operate. If the application does not have any runtime dependencies,
such as shared libraries or dynamically loaded modules, it should be
possible to combine -flto with -fwhole-program to allow the
interprocedural optimizers to use more aggressive assumptions, which
may lead to improved optimization opportunities."
Diego.