projects
/
musl
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
move __stdio_exit_needed to stdio_impl.h
[musl]
/
src
/
math
/
coshl.c
diff --git
a/src/math/coshl.c
b/src/math/coshl.c
index
d09070b
..
06a56fe
100644
(file)
--- a/
src/math/coshl.c
+++ b/
src/math/coshl.c
@@
-8,10
+8,7
@@
long double coshl(long double x)
#elif LDBL_MANT_DIG == 64 && LDBL_MAX_EXP == 16384
long double coshl(long double x)
{
#elif LDBL_MANT_DIG == 64 && LDBL_MAX_EXP == 16384
long double coshl(long double x)
{
- union {
- long double f;
- struct{uint64_t m; uint16_t se; uint16_t pad;} i;
- } u = {.f = x};
+ union ldshape u = {x};
unsigned ex = u.i.se & 0x7fff;
uint32_t w;
long double t;
unsigned ex = u.i.se & 0x7fff;
uint32_t w;
long double t;
@@
-41,4
+38,10
@@
long double coshl(long double x)
t = expl(0.5*x);
return 0.5*t*t;
}
t = expl(0.5*x);
return 0.5*t*t;
}
+#elif LDBL_MANT_DIG == 113 && LDBL_MAX_EXP == 16384
+// TODO: broken implementation to make things compile
+long double coshl(long double x)
+{
+ return cosh(x);
+}
#endif
#endif