There's potential here to maybe lose some/all of builtins.cpp, but I'll
look at that separately later.
Test: treehugger
Change-Id: I2c2bc1d0753affdd214daeb09fa1ac7cd73db347
This reverts commit 253a830631 and moves
us forward to a revision that contains fixes for the problem with the
previous attempt.
This also makes sincos(3)/sincosf(3)/sincosl(3) available to `_BSD_SOURCE`
as well as `_GNU_SOURCE`.
The new FreeBSD libm code requires the FreeBSD `__CONCAT` macro, and all
our existing callers are FreeBSD too, so update that.
There's also an assumption that <complex.h> drags in <math.h> which isn't
true for us, so work around that with `-include` in the makefile. This
then causes clang to recognize a bug -- returning from a void function --
in our fake (LP32) sincosl(3), so fix that too.
Bug: http://b/111710419
Change-Id: I84703ad844f8afde6ec6b11604ab3c096ccb62c3
Test: ran tests
We've been using #pragma once for new internal files, but let's be more bold.
Bug: N/A
Test: builds
Change-Id: I7e2ee2730043bd884f9571cdbd8b524043030c07
Some of this code is used in the NDK libandroid_support now, as a static
library, so just being HIDDEN in the ELF sense isn't sufficient.
Rename digittoint to __libm_digittoint so we don't trample anyone's toes.
Also remove imprecise_powl and imprecise_tgammal. It turns out (to my
surprise) that we don't even have ld128 implementations of powl and tgammal,
so even LP64 was just using the "fake_long_double.c" hack in effect. Since
that's the case, let's *actually* do that because then we're not polluting
with the internal names in addition to the aliases.
Bug: N/A
Test: readelf
Change-Id: I273cc8fdc7ce53f9b8dfd4ef7796e358fe901837
- promoted IEEEld2bits to fpmath since most of the where the same for
diffrent archs
- removed _fpmath
- reinstated weak_references
- moved isfinite and isnormal to libc
- clean up fake_long_doubles
- clean up some useless ifdefs
- added missing nexttoward* tests
Bug: 14134235
Change-Id: I95639c4885653fe47fd7dc0570ee5bb3389bbc6b
The aarch64 toolchain doesn't support them, and we were already implementing
most of the fake long-double functions differently anyway.
Change-Id: I4a2f2df81972ee9c34ddfe96cec81b126506d881
Also fix the signature of usleep, and the definition of useconds_t which
should be unsigned, as the 'u' in its name implies.
This patch also cleans up the existing FreeBSD hacks by moving the libm
stuff from <sys/cdefs.h> to a libm-private header, and adding comments
about the hacks we use to build FreeBSD source.
Change-Id: Ibe5067a380502df94a0a3a7901969b35411085b6