public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "rguenth at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug tree-optimization/63743] Thumb1: big regression for float operators by r216728
Date: Wed, 05 Nov 2014 12:34:00 -0000	[thread overview]
Message-ID: <bug-63743-4-OtoedQmuey@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-63743-4@http.gcc.gnu.org/bugzilla/>

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63743

Richard Biener <rguenth at gcc dot gnu.org> changed:

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

--- Comment #5 from Richard Biener <rguenth at gcc dot gnu.org> ---
This is just operand canonicalization according to tree_swap_operands which is
now consistently applied.  It was a bug that it wasn't applied before (the
usual offender here is SSA rewriting that doesn't fold "changed" statements
nor re-canonicalizes).

You are just (un)lucky btw, try both

double
test1 (double x, double y)
{
  double tem = x + y;
  double tem2 = x;
  return tem2 * tem;
}

and

double
test1 (double x, double y)
{
  double tem = x + y;
  double tem2 = x;
  return tem * tem2;
}

there is nothing that forces ordering in the way you would prefer it.  So as
Jakub says - this needs addressing in RTL expansion and/or TER and SSA
coalescing.


  parent reply	other threads:[~2014-11-05 12:34 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-11-05  8:20 [Bug tree-optimization/63743] New: " zhenqiang.chen at arm dot com
2014-11-05  8:35 ` [Bug tree-optimization/63743] " jakub at gcc dot gnu.org
2014-11-05  9:40 ` zhenqiang.chen at arm dot com
2014-11-05  9:51 ` jakub at gcc dot gnu.org
2014-11-05 10:21 ` zhenqiang.chen at arm dot com
2014-11-05 12:34 ` rguenth at gcc dot gnu.org [this message]
2014-12-26 13:54 ` ysrumyan at gmail dot com
2015-01-15 14:56 ` rguenth at gcc dot gnu.org
2015-01-28  8:01 ` thopre01 at gcc dot gnu.org
2015-03-04  6:58 ` thopre01 at gcc dot gnu.org
2015-03-09  1:32 ` thopre01 at gcc dot gnu.org
2015-03-11  5:06 ` thopre01 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-63743-4-OtoedQmuey@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).