public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "tmsriram at google dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug target/59385] gcc 4.9 fails to use fma with __attribute__((target("fma")))
Date: Fri, 06 Dec 2013 22:58:00 -0000	[thread overview]
Message-ID: <bug-59385-4-trMFyvu2Px@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-59385-4@http.gcc.gnu.org/bugzilla/>

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

--- Comment #4 from Sriraman Tallam <tmsriram at google dot com> ---
The "widening_mult" has the answer. This pass converts this gimple sequence

  double _31;
  double _33;
  double _36;
  double _37;

  _31 = *a_4;
  _33 = *b_6;
  _34 = _33 * _31;
  _36 = *c_8;
  _37 = _34 + _36;

into:

  _31 = *a_4;
  _33 = *b_6;
  _36 = *c_8;
  _37 = _33 * _31 + _36; (fma gets recognized from this pattern in rtl expand)

for the compiler where the vfmadd132sd insn is generated.

This conversion fails to happen in gcc-4.9. The problem should mostly be in
this function convert_mult_to_widen in treessa-math-opts.c. I have not looked
closely at this function yet.


  parent reply	other threads:[~2013-12-06 22:58 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-12-04 16:45 [Bug c/59385] New: " jtaylor.debian at googlemail dot com
2013-12-04 16:45 ` [Bug c/59385] " jtaylor.debian at googlemail dot com
2013-12-05 19:45 ` [Bug target/59385] " tmsriram at google dot com
2013-12-06 22:58 ` tmsriram at google dot com [this message]
2013-12-07  0:42 ` tmsriram at google dot com
2014-01-09 10:48 ` jtaylor.debian at googlemail dot com
2014-01-31 10:49 ` [Bug target/59385] [4.9 regression] " rguenth at gcc dot gnu.org
2014-01-31 11:14 ` rguenth at gcc dot gnu.org
2014-01-31 12:26 ` jtaylor.debian at googlemail dot com

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-59385-4-trMFyvu2Px@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).