public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug fortran/19302] New: nearest test case fails
@ 2005-01-06 23:24 coudert at clipper dot ens dot fr
  2005-01-06 23:28 ` [Bug fortran/19302] " pinskia at gcc dot gnu dot org
                   ` (9 more replies)
  0 siblings, 10 replies; 11+ messages in thread
From: coudert at clipper dot ens dot fr @ 2005-01-06 23:24 UTC (permalink / raw)
  To: gcc-bugs

The test intrinsic_nearest.f90 from the fortran testsuite included with gcc
fails on sparc-sun-solaris2.9 will all optimization levels. I can reduce it to
the following code:

-------------------------------------------
program test_nearest
  real inf, max, x
  integer infi, maxi
  equivalence (inf,infi)
  equivalence (max,maxi)

! ??? This is pretty sketchy, but passes on most targets.
  infi = z'7f800000'
  maxi = z'7f7fffff'

  x = nearest (-inf, 1.0)
  print *, x, -max
  if (x .ne. -max) call abort()
end
-------------------------------------------

The comment (from the original test file) makes me feel that perhaps the nearest
intrinsic is fine but only the values for infi and maxi are proven wrong, but
I'm not really sure. And, if it's the case, some "more universal" values should
be fed in.

-- 
           Summary: nearest test case fails
           Product: gcc
           Version: unknown
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: fortran
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: coudert at clipper dot ens dot fr
                CC: gcc-bugs at gcc dot gnu dot org
GCC target triplet: sparc-sun-solaris2.9


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


^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2005-02-21 21:43 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-01-06 23:24 [Bug fortran/19302] New: nearest test case fails coudert at clipper dot ens dot fr
2005-01-06 23:28 ` [Bug fortran/19302] " pinskia at gcc dot gnu dot org
2005-01-07  0:32 ` [Bug fortran/19302] intrinsic_nearest.f90 fails ebotcazou at gcc dot gnu dot org
2005-01-07  0:33 ` ebotcazou at gcc dot gnu dot org
2005-01-07 10:57 ` Thomas dot Koenig at online dot de
2005-01-07 12:30 ` coudert at clipper dot ens dot fr
2005-01-24  7:30 ` coudert at clipper dot ens dot fr
2005-02-12 22:25 ` ebotcazou at gcc dot gnu dot org
2005-02-20 15:52 ` [Bug libfortran/19302] " ebotcazou at gcc dot gnu dot org
2005-02-22  0:54 ` cvs-commit at gcc dot gnu dot org
2005-02-22  1:15 ` ebotcazou at gcc dot gnu dot org

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).