llvm/libc
Tue Ly a5466f0436 [libc] Improve the performance of expm1f.
Improve the performance of expm1f:
- Rearrange the selection logic for different cases to improve the overall
throughput.
- Use the same degree-4 polynomial for large inputs as `expf`
(https://reviews.llvm.org/D122418), reduced from a degree-7 polynomial.

Performance benchmark using perf tool from CORE-MATH project
(https://gitlab.inria.fr/core-math/core-math/-/tree/master):
Before this patch:
```
$ ./perf.sh expm1f

CORE-MATH reciprocal throughput   : 15.362
System LIBC reciprocal throughput : 53.288
LIBC reciprocal throughput        : 54.572

$ ./perf.sh expm1f --latency

CORE-MATH latency   : 57.759
System LIBC latency : 147.146
LIBC latency        : 118.057
```

After this patch:
```
$ ./perf.sh expm1f

CORE-MATH reciprocal throughput   : 15.359
System LIBC reciprocal throughput : 53.188
LIBC reciprocal throughput        : 14.600

$ ./perf.sh expm1f --latency

CORE-MATH latency   : 57.774
System LIBC latency : 147.119
LIBC latency        : 60.280

```

Reviewed By: michaelrj, santoshn, zimmermann6

Differential Revision: https://reviews.llvm.org/D122538
2022-03-30 19:23:25 -04:00
..
AOR_v20.02
benchmarks [NFC][libc] Disable benchmarks when the LLVM benchmark target is not available 2022-03-29 08:45:53 +00:00
cmake/modules [libc] Set rtlib to compiler-rt in integration tests. 2022-03-28 23:46:21 +00:00
config [libc] Add implementations of fopen, flose, fread, fwrite and fseek. 2022-03-24 04:20:12 +00:00
docs [libc] Rename libc-integration-test to libc-api-test. 2022-03-23 20:25:34 +00:00
fuzzing [libc][NFC] split standalone_cpp into single headers 2022-03-08 11:56:08 -08:00
include [libc] Add implementation of POSIX lseek function. 2022-03-15 16:24:48 +00:00
lib
loader [libc] Use real objects and archives in integration tests. 2022-03-24 07:02:33 +00:00
spec [libc] Add implementations of fopen, flose, fread, fwrite and fseek. 2022-03-24 04:20:12 +00:00
src [libc] Improve the performance of expm1f. 2022-03-30 19:23:25 -04:00
test [libc] Improve the performance of expm1f. 2022-03-30 19:23:25 -04:00
utils [libc] Add a new rule add_integration_test. 2022-03-23 20:57:29 +00:00
.clang-tidy
.gitignore [libc][Obvious] Add build folder to .gitignore. 2022-03-04 13:16:55 -05:00
CMakeLists.txt [NFC][libc] Disable benchmarks when the LLVM benchmark target is not available 2022-03-29 08:45:53 +00:00
LICENSE.TXT
README.txt

LLVM libc
=========

This directory and its subdirectories contain source code for llvm-libc,
a retargetable implementation of the C standard library.

LLVM is open source software. You may freely distribute it under the terms of
the license agreement found in LICENSE.txt.