public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "sje at cup dot hp dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug fortran/31832] FAIL: gfortran.dg/integer_exponentiation_2.f90 at -O1 and above
Date: Thu, 07 Jun 2007 22:47:00 -0000	[thread overview]
Message-ID: <20070607224738.25417.qmail@sourceware.org> (raw)
In-Reply-To: <bug-31832-276@http.gcc.gnu.org/bugzilla/>



------- Comment #1 from sje at cup dot hp dot com  2007-06-07 22:47 -------
I have looked into this bug and I think it is an HP math lib bug.  The 64 bit
powf function is using %fr12R but not saving/restoring it the way it is
supposed to.  I have a query in to the math lib folks to see if they can verify
my finding.

Here is a smaller test case that prints different values at -O1 or -O2 than at
-O0.

program test
  real a
  call run_me (-1.1, -1)
  a = -1.1
end program test

subroutine run_me(a, i)
  implicit none

  real, intent(in) :: a
  integer, intent(in) :: i
  print *, a**-2.0
  print *, (1/a)*(1/a)
  call check_equal_r (a**-2.0, (1/a)*(1/a))
end subroutine run_me

subroutine check_equal_r (a, b)
  real, intent(in) :: a, b
  print *, a
  print *, b
end subroutine check_equal_r


-- 

sje at cup dot hp dot com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |sje at cup dot hp dot com


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


  reply	other threads:[~2007-06-07 22:47 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-05-05  1:21 [Bug fortran/31832] New: " danglin at gcc dot gnu dot org
2007-06-07 22:47 ` sje at cup dot hp dot com [this message]
2007-07-06  8:45 ` [Bug fortran/31832] " dfranke at gcc dot gnu dot org
2007-07-07 15:10 ` danglin at gcc dot gnu dot org
2007-08-08 17:29 ` fxcoudert at gcc dot gnu dot org
2007-08-08 17:30 ` fxcoudert at gcc dot gnu dot org
2007-08-09 21:55 ` fxcoudert at gcc dot gnu dot org
2007-08-09 23:30 ` dave at hiauly1 dot hia dot nrc dot ca
2007-10-05 13:02 ` fxcoudert at gcc dot gnu dot org
2007-12-08 18:07 ` fxcoudert at gcc dot gnu dot org
2008-12-27 17:34 ` danglin at gcc dot gnu dot org
2008-12-28 16:23 ` danglin at gcc dot gnu dot org
2008-12-29 20:12 ` danglin at gcc dot gnu dot org
2008-12-31 15:44 ` danglin at gcc dot gnu dot org
2008-12-31 15:45 ` danglin at gcc dot gnu dot 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=20070607224738.25417.qmail@sourceware.org \
    --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).