public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "fxcoudert at gcc dot gnu dot org" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug fortran/27561] [mingw32] floating-point extreme values are wrong Date: Tue, 30 May 2006 13:17:00 -0000 [thread overview] Message-ID: <20060530131652.27608.qmail@sourceware.org> (raw) In-Reply-To: <bug-27561-10129@http.gcc.gnu.org/bugzilla/> ------- Comment #2 from fxcoudert at gcc dot gnu dot org 2006-05-30 13:16 ------- Lots of things are going badly here: $ cat dale.f90 real(4) :: x4 real(8) :: x8 print *, " ** REAL(KIND=4) tests ** " write(*,*) digits(x4), maxexponent(x4), minexponent(x4), & precision(x4), radix(x4), range(x4) write(*,"(80(G40.20))") epsilon(x4), huge(x4), tiny(x4) if (epsilon(x4) == 0.0_4) print *, "EPSILON is wrong" if (tiny(x4) == 0.0_4) print *, "TINY is wrong" print *, " ** REAL(KIND=8) tests ** " write(*,*) digits(x8), maxexponent(x8), minexponent(x8), & precision(x8), radix(x8), range(x8) write(*,"(80(G40.20))") epsilon(x8), huge(x8), tiny(x8) if (epsilon(x8) == 0.0_8) print *, "EPSILON is wrong" if (tiny(x8) == 0.0_8) print *, "TINY is wrong" end On i386-linux, we have: $ gfortran dale.f90 && ./a.out ** REAL(KIND=4) tests ** 24 128 -125 6 2 37 0.11920928955078125000E-06 0.34028234663852885981E+39 0.11754943508222875080E-37 ** REAL(KIND=8) tests ** 53 1024 -1021 15 2 307 0.22204460492503130808E-15 0.17976931348623157081+309 0.22250738585072013831-307 but on i386-mingw32, we get: ** REAL(KIND=4) tests ** 24 128 -125 6 2 38 0.0000000000000000000 +Infinity 0.0000000000000000000 EPSILON is wrong TINY is wrong ** REAL(KIND=8) tests ** 53 1024 -1021 15 2 308 0.0000000000000000000 +Infinity 0.0000000000000000000 EPSILON is wrong TINY is wrong -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=27561
next prev parent reply other threads:[~2006-05-30 13:17 UTC|newest] Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top 2006-05-11 17:18 [Bug fortran/27561] New: i386-pc-mingw32 version incorrect error dir at lanl dot gov 2006-05-30 13:12 ` [Bug fortran/27561] [mingw32] floating-point extreme values are wrong fxcoudert at gcc dot gnu dot org 2006-05-30 13:17 ` fxcoudert at gcc dot gnu dot org [this message] 2006-05-30 13:59 ` fxcoudert at gcc dot gnu dot org 2006-05-30 15:06 ` fxcoudert at gcc dot gnu dot org 2006-05-30 16:34 ` dir at lanl dot gov 2006-05-30 17:01 ` dir at lanl dot gov 2006-05-31 12:54 ` fxcoudert 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=20060530131652.27608.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: linkBe 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).