public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "rguenther at suse dot de" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug lto/55102] The options -flto and -On do not behave as described in GCC docs
Date: Wed, 27 Mar 2013 13:09:00 -0000	[thread overview]
Message-ID: <bug-55102-4-sOrrRyYoz6@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-55102-4@http.gcc.gnu.org/bugzilla/>


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55102

--- Comment #4 from rguenther at suse dot de <rguenther at suse dot de> 2013-03-27 13:09:18 UTC ---
On Wed, 27 Mar 2013, hubicka at gcc dot gnu.org wrote:

> 
> http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55102
> 
> --- Comment #3 from Jan Hubicka <hubicka at gcc dot gnu.org> 2013-03-27 12:47:04 UTC ---
> Doing IPA analysis at -O0 for LTO streaming won't really solve the fact that
> functions are not early optimized.  I would vote for at least issuing a waning
> when LTOing -O0 objects into -On, n>=1 LTO binary or simply declaring -O0 to be
> non-LTO only.
> 
> But indeed, we probably should make analysis/summary streaming of all IPA
> passes so -fno-ipa-cp and such works as expected all the time.  I have patch
> fot that somewhere already.
> 
> We probably should lean the route of streaming the options used and honoring
> them rather than taking whatever is passed to linker...

Well, we _do_ stream them.  The issue is that we need to formally
define how to merge N sets of options from the N input files
at WPA stage to M sets of options for the M LTRANS units
(with eventually, but not necessarily, M == 1).

Oh, and implement it, of course.

At the moment the LTO driver (lto-wrapper.c) has a brief look at
options because it creates options for the WPA stage (which
shouldn't really care about the options passed ... in which
case it could do the option processing from the TUs and eventually
simply partition them into sets of TUs that have the same options).

So - Honza, what about first making WPA "ignore" all flags?
(all optimization and target flags)  IPA pass processing should
just unconditionally run and handle inputs which have the IPA
sections present.


      parent reply	other threads:[~2013-03-27 13:09 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-10-27 19:27 [Bug lto/55102] New: " d.g.gorbachev at gmail dot com
2012-10-29 14:39 ` [Bug lto/55102] " rguenth at gcc dot gnu.org
2013-03-26 20:51 ` ebotcazou at gcc dot gnu.org
2013-03-27 12:47 ` hubicka at gcc dot gnu.org
2013-03-27 13:09 ` rguenther at suse dot de [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=bug-55102-4-sOrrRyYoz6@http.gcc.gnu.org/bugzilla/ \
    --to=gcc-bugzilla@gcc.gnu.org \
    --cc=gcc-bugs@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).