public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug libstdc++/112593] New: FAIL: 26_numerics/headers/cmath/equivalent_functions.cc on Solaris 11.3
@ 2023-11-17 17:17 redi at gcc dot gnu.org
  2023-11-23 14:02 ` [Bug libstdc++/112593] FAIL: 26_numerics/headers/cmath/equivalent_functions.cc on Solaris ro at gcc dot gnu.org
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: redi at gcc dot gnu.org @ 2023-11-17 17:17 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=112593

            Bug ID: 112593
           Summary: FAIL:
                    26_numerics/headers/cmath/equivalent_functions.cc on
                    Solaris 11.3
           Product: gcc
           Version: 14.0
            Status: UNCONFIRMED
          Keywords: testsuite-fail
          Severity: normal
          Priority: P3
         Component: libstdc++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: redi at gcc dot gnu.org
  Target Milestone: ---
            Target: sparc-sun-solaris2.11

/export/home/jwakely/src/gcc/libstdc++-v3/testsuite/26_numerics/headers/cmath/equivalent_functions.cc:197:
void test_long_double_overload(): Assertion 'std::cosh(x) == std::coshl(x)'
failed.


std::cosh is provided by
/export/home/jwakely/build/gcc/include-fixed/iso/math_iso.h which has:

namespace std {
...
extern long double __coshl(long double);
...
inline long double cosh(long double __X) { return __coshl(__X); }


std::coshl is provided by libstdc++'s <cmath> (since r14-5341-g0b880466e910b4)
which does:

using std::coshl;

That finds ::coshl from /export/home/jwakely/build/gcc/include-fixed/math.h:

extern long double coshl (long double);


That means that Solaris provides both ::coshl and also std::__coshl, and they
return different values for cosh(1.0):

std::cosh(x)    = 1.5430806348152437784779056207570615
std::__coshl(x) = 1.5430806348152437784779056207570615
std::coshl(x)   = 1.5430806348152437784779056207570617

The first two match, as expected because std::cosh just calls std::__coshl.

I don't know why Solaris provides two different implementations of coshl.

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

end of thread, other threads:[~2024-06-04 12:49 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-11-17 17:17 [Bug libstdc++/112593] New: FAIL: 26_numerics/headers/cmath/equivalent_functions.cc on Solaris 11.3 redi at gcc dot gnu.org
2023-11-23 14:02 ` [Bug libstdc++/112593] FAIL: 26_numerics/headers/cmath/equivalent_functions.cc on Solaris ro at gcc dot gnu.org
2023-11-23 14:44 ` redi at gcc dot gnu.org
2024-06-04 12:49 ` ro at CeBiTec dot Uni-Bielefeld.DE

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