public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "hubicka at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug tree-optimization/54073] [4.7/4.8 Regression] SciMark Monte Carlo test performance has seriously decreased in recent GCC releases
Date: Tue, 13 Nov 2012 15:55:00 -0000	[thread overview]
Message-ID: <bug-54073-4-33hJllHMtW@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-54073-4@http.gcc.gnu.org/bugzilla/>


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

Jan Hubicka <hubicka at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |hubicka at gcc dot gnu.org

--- Comment #12 from Jan Hubicka <hubicka at gcc dot gnu.org> 2012-11-13 15:54:22 UTC ---
The decision on whether to use cmov or jmp was always tricky on x86
architectures. Cmov increase dependency chains, register pressure (both values
needs to be loaded in) and has long opcode. So jump sequence, if well
predicted, flows better through the out-of-order core. If badly predicted it
is, of course, a disaster. I think more modern CPUs solved the problems with
long latency of cmov, but the dependency chains are still there.

This patch fixes a bug in a pattern rather than tweaks heuristic on
predictability. As such I think it is OK for mainline. 

We should do something about rnflow. I will look into that.
The usual wisdom is that lacking profile feedback one should handle non-loop
branhces as inpredctable and loop branches as predictable, so all handled by
ifconvert fals to the first category. With profile feedback one can see branch
probability and if it is close to 0 or REG_BR_PROB_BASE tread the branch as
predictable. We handle this with predictable_edge_p parameter passed to
BRANCH_COST (that by itself is a gross, but for years we was not able to come
with something saner)

Honza


  parent reply	other threads:[~2012-11-13 15:55 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-07-23 15:25 [Bug tree-optimization/54073] New: " t.artem at mailcity dot com
2012-07-23 15:44 ` [Bug tree-optimization/54073] " t.artem at mailcity dot com
2012-07-24  9:23 ` [Bug tree-optimization/54073] [4.7/4.8 Regression] " rguenth at gcc dot gnu.org
2012-07-24 11:29 ` markus at trippelsdorf dot de
2012-07-24 13:21 ` rguenth at gcc dot gnu.org
2012-07-26 15:41 ` venkataramanan.kumar at amd dot com
2012-07-26 16:13 ` markus at trippelsdorf dot de
2012-08-16 11:06 ` rguenth at gcc dot gnu.org
2012-09-07 10:09 ` rguenth at gcc dot gnu.org
2012-09-20 10:28 ` jakub at gcc dot gnu.org
2012-11-13 13:05 ` jakub at gcc dot gnu.org
2012-11-13 15:07 ` t.artem at mailcity dot com
2012-11-13 15:14 ` ubizjak at gmail dot com
2012-11-13 15:24 ` jakub at gcc dot gnu.org
2012-11-13 15:55 ` hubicka at gcc dot gnu.org [this message]
2012-11-16 11:41 ` jakub at gcc dot gnu.org
2012-11-16 14:50 ` [Bug tree-optimization/54073] [4.7 " jakub at gcc dot gnu.org
2012-12-31  9:41 ` pinskia at gcc dot gnu.org
2013-02-16 19:12 ` jake.stine at gmail dot com
2013-02-17  8:41 ` ubizjak at gmail dot com
2013-04-11  7:59 ` rguenth at gcc dot gnu.org
2014-06-12 13:16 ` rguenth at gcc dot gnu.org

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-54073-4-33hJllHMtW@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).