public inbox for gcc-prs@sourceware.org
help / color / mirror / Atom feed
* target/6540: sparc-sun-solaris2.7 (perhaps all bi-arch sparc) fail libstdc++-v3 18_support/numeric_limits.cc
@ 2002-05-02 9:06 ghazi
0 siblings, 0 replies; 2+ messages in thread
From: ghazi @ 2002-05-02 9:06 UTC (permalink / raw)
To: gcc-gnats; +Cc: davem
>Number: 6540
>Category: target
>Synopsis: sparc-sun-solaris2.7 (perhaps all bi-arch sparc) fail libstdc++-v3 18_support/numeric_limits.cc
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: unassigned
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Thu May 02 09:06:00 PDT 2002
>Closed-Date:
>Last-Modified:
>Originator: Kaveh Ghazi
>Release: gcc version 3.1 20020501 (prerelease)
>Organization:
>Environment:
sparc-sun-solaris2.7 native as/ld
>Description:
The libstdc++-v3 test 18_support/numeric_limits.cc fails on sparc-sun-solaris2.7 for -m32 but succeeds for -m64 as seen here:
http://gcc.gnu.org/ml/gcc-testresults/2002-05/msg00028.html
http://gcc.gnu.org/ml/gcc-testresults/2002-05/msg00048.html
It passes on sparcv9:
http://gcc.gnu.org/ml/gcc-testresults/2002-05/msg00003.html
On my solaris2.7 system, it fails on the long double test_extrema. I tracked this down to the definition of LDBL_MIN/LDBL_MAX from gcc/config/float-sparc.h. In there, we define a 128 bit LDBL_* only if sparcv9 or arch64 are defined. However sol2-bi.h hardcodes LONG_DOUBLE_TYPE_SIZE to 128.
So this is really a bug in the float.h that gets generated for solaris2.7. Using this program to demonstrate:
#include <stdio.h>
#include <float.h>
int main()
{
long double min = LDBL_MIN, max = LDBL_MAX;
printf ("%d\n%Le\n%Le\n", (int) sizeof(long double), min, max);
return 0;
}
If I compile with -m32, I get:
16
2.225074e-308
1.797693e+308
If I compile with -m64, I get:
16
3.362103e-4932
1.189731e+4932
IMHO, I should get the latter result for both cases.
>How-To-Repeat:
>Fix:
>Release-Note:
>Audit-Trail:
>Unformatted:
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: target/6540: sparc-sun-solaris2.7 (perhaps all bi-arch sparc) fail libstdc++-v3 18_support/numeric_limits.cc
@ 2002-05-02 14:59 davem
0 siblings, 0 replies; 2+ messages in thread
From: davem @ 2002-05-02 14:59 UTC (permalink / raw)
To: davem, gcc-bugs, gcc-prs, ghazi, nobody
Synopsis: sparc-sun-solaris2.7 (perhaps all bi-arch sparc) fail libstdc++-v3 18_support/numeric_limits.cc
State-Changed-From-To: open->closed
State-Changed-By: davem
State-Changed-When: Thu May 2 14:59:11 2002
State-Changed-Why:
Fixed, see audit trail.
http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gcc&pr=6540
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2002-05-02 21:59 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-05-02 9:06 target/6540: sparc-sun-solaris2.7 (perhaps all bi-arch sparc) fail libstdc++-v3 18_support/numeric_limits.cc ghazi
2002-05-02 14:59 davem
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).