public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "t_nissie at yahoo dot co.jp" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug middle-end/56015] [4.6/4.7/4.8 Regression] expand expands p[9] = COMPLEX_EXPR <-IMAGPART_EXPR <p[9]>, REALPART_EXPR <p[9]>>; incorrectly.
Date: Thu, 17 Jan 2013 11:58:00 -0000	[thread overview]
Message-ID: <bug-56015-4-7tbitvwuOP@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-56015-4@http.gcc.gnu.org/bugzilla/>


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

--- Comment #5 from Takeshi Nishimatsu <t_nissie at yahoo dot co.jp> 2013-01-17 11:58:24 UTC ---
(In reply to comment #3)
> Created attachment 29189 [details]
> gcc48-pr56015.patch
> 
> Untested fix.

Thank you for your fix.
I add one more test multiplying -i.

program pr56015
  implicit none
  complex*16 m(10),p(10)
  m(:) = (0.3d0, 0.4d0)
  m(:) = (0.0d0,-1.0d0) * m(:)
  call bar (m)
  p(:) = (0.1d0, 0.2d0)
  p(:) = (0.0d0, 1.0d0) * p(:)
  call foo (p)
contains
  subroutine bar (m)
    complex*16 m(10)
    if (any (m .ne. ( 0.4d0,-0.3d0))) call abort
  end subroutine
  subroutine foo (p)
    complex*16 p(10)
    if (any (p .ne. (-0.2d0, 0.1d0))) call abort
  end subroutine
end program pr56015


  parent reply	other threads:[~2013-01-17 11:58 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-01-17  8:40 [Bug fortran/56015] New: Option -ffast-math reveals i*(a+bi) -> -b-bi, a complex multiplication bug t_nissie at yahoo dot co.jp
2013-01-17  8:52 ` [Bug middle-end/56015] expand expands p[9] = COMPLEX_EXPR <-IMAGPART_EXPR <p[9]>, REALPART_EXPR <p[9]>>; incorrectly pinskia at gcc dot gnu.org
2013-01-17 10:30 ` [Bug middle-end/56015] [4.6/4.7/4.8 Regression] " jakub at gcc dot gnu.org
2013-01-17 10:31 ` jakub at gcc dot gnu.org
2013-01-17 10:48 ` rguenth at gcc dot gnu.org
2013-01-17 11:58 ` t_nissie at yahoo dot co.jp [this message]
2013-01-18 17:15 ` jakub at gcc dot gnu.org
2013-01-18 17:26 ` [Bug middle-end/56015] [4.6/4.7 " jakub at gcc dot gnu.org
2013-02-01 14:11 ` jakub at gcc dot gnu.org
2013-02-01 14:32 ` [Bug middle-end/56015] [4.6 " jakub at gcc dot gnu.org
2013-04-03 18:20 ` jakub 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-56015-4-7tbitvwuOP@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).