mirror of
https://github.com/jart/cosmopolitan.git
synced 2025-05-23 22:02:27 +00:00
Port a lot more code to AARCH64
- Introduce epoll_pwait() - Rewrite -ftrapv and ffs() libraries in C code - Use more FreeBSD code in math function library - Get significantly more tests passing on qemu-aarch64 - Fix many Musl long double functions that were broken on AARCH64
This commit is contained in:
parent
91791e9f38
commit
550b52abf6
158 changed files with 6018 additions and 3499 deletions
|
@ -29,8 +29,8 @@ TEST(log2l, test) {
|
|||
EXPECT_STREQ("INFINITY", gc(xdtoal(log2l(INFINITY))));
|
||||
EXPECT_STREQ("-INFINITY", gc(xdtoal(log2l(0))));
|
||||
EXPECT_STREQ("-INFINITY", gc(xdtoal(log2l(-0.))));
|
||||
EXPECT_STREQ("-NAN", gc(xdtoal(log2l(-1))));
|
||||
EXPECT_STREQ("-NAN", gc(xdtoal(log2l(-2))));
|
||||
EXPECT_TRUE(isnan(log2l(-1)));
|
||||
EXPECT_TRUE(isnan(log2l(-2)));
|
||||
}
|
||||
|
||||
TEST(log2, test) {
|
||||
|
@ -41,8 +41,8 @@ TEST(log2, test) {
|
|||
EXPECT_STREQ("INFINITY", gc(xdtoa(log2(INFINITY))));
|
||||
EXPECT_STREQ("-INFINITY", gc(xdtoa(log2(0))));
|
||||
EXPECT_STREQ("-INFINITY", gc(xdtoa(log2(-0.))));
|
||||
EXPECT_STREQ("-NAN", gc(xdtoa(log2(-1))));
|
||||
EXPECT_STREQ("-NAN", gc(xdtoa(log2(-2))));
|
||||
EXPECT_TRUE(isnan(log2(-1)));
|
||||
EXPECT_TRUE(isnan(log2(-2)));
|
||||
}
|
||||
|
||||
TEST(log2f, test) {
|
||||
|
@ -52,15 +52,15 @@ TEST(log2f, test) {
|
|||
EXPECT_STREQ("INFINITY", gc(xdtoaf(log2f(INFINITY))));
|
||||
EXPECT_STREQ("-INFINITY", gc(xdtoaf(log2f(0))));
|
||||
EXPECT_STREQ("-INFINITY", gc(xdtoaf(log2f(-0.))));
|
||||
EXPECT_STREQ("-NAN", gc(xdtoaf(log2f(-1))));
|
||||
EXPECT_STREQ("-NAN", gc(xdtoaf(log2f(-2))));
|
||||
EXPECT_TRUE(isnan(log2f(-1)));
|
||||
EXPECT_TRUE(isnan(log2f(-2)));
|
||||
}
|
||||
|
||||
BENCH(log2, bench) {
|
||||
double _log2(double) asm("log2");
|
||||
float _log2f(float) asm("log2f");
|
||||
long double _log2l(long double) asm("log2l");
|
||||
EZBENCH2("log2", donothing, _log2(.7)); /* ~9ns */
|
||||
EZBENCH2("log2f", donothing, _log2f(.7)); /* ~6ns */
|
||||
EZBENCH2("log2l", donothing, _log2l(.7)); /* ~21ns */
|
||||
EZBENCH2("log2", donothing, _log2(.7)); // ~8ns
|
||||
EZBENCH2("log2f", donothing, _log2f(.7)); // ~6ns
|
||||
EZBENCH2("log2l", donothing, _log2l(.7)); // ~21ns
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue