llvm/libc
Tue Ly 628fbbef81 [libc] Use nearest_integer instructions to improve expm1f performance.
Use nearest_integer instructions to improve expf performance.

Performance tests with CORE-MATH's perf tool:

Before the patch:
```
$ ./perf.sh expm1f
LIBC-location: /home/lnt/experiment/llvm/llvm-project/build/projects/libc/lib/libllvmlibc.a
GNU libc version: 2.31
GNU libc release: stable
CORE-MATH reciprocal throughput   : 10.096
System LIBC reciprocal throughput : 44.036
LIBC reciprocal throughput        : 11.575

$ ./perf.sh expm1f --latency
LIBC-location: /home/lnt/experiment/llvm/llvm-project/build/projects/libc/lib/libllvmlibc.a
GNU libc version: 2.31
GNU libc release: stable
CORE-MATH latency   : 42.239
System LIBC latency : 122.815
LIBC latency        : 50.122
```
After the patch:
```
$ ./perf.sh expm1f
LIBC-location: /home/lnt/experiment/llvm/llvm-project/build/projects/libc/lib/libllvmlibc.a
GNU libc version: 2.31
GNU libc release: stable
CORE-MATH reciprocal throughput   : 10.046
System LIBC reciprocal throughput : 43.899
LIBC reciprocal throughput        : 9.179

$ ./perf.sh expm1f --latency
LIBC-location: /home/lnt/experiment/llvm/llvm-project/build/projects/libc/lib/libllvmlibc.a
GNU libc version: 2.31
GNU libc release: stable
CORE-MATH latency   : 42.078
System LIBC latency : 120.488
LIBC latency        : 41.528
```

Reviewed By: zimmermann6

Differential Revision: https://reviews.llvm.org/D130502
2022-07-26 09:12:37 -04:00
..
AOR_v20.02
benchmarks Remove unneeded cl::ZeroOrMore for cl::opt/cl::list options 2022-06-05 00:31:44 -07:00
cmake/modules [libc] Implement sinf function that is correctly rounded to all rounding modes. 2022-07-22 10:07:31 -04:00
config [libc] Add dirent.h functions opendir, readdir, closedir and dirfd. 2022-07-25 20:23:25 +00:00
docs [libc] Use nearest_integer instructions to improve expm1f performance. 2022-07-26 09:12:37 -04:00
fuzzing [libc][NFC] split standalone_cpp into single headers 2022-03-08 11:56:08 -08:00
include [libc] Add dirent.h functions opendir, readdir, closedir and dirfd. 2022-07-25 20:23:25 +00:00
lib Use add_llvm_install_targets for install-llvmlibc 2022-07-04 17:18:36 +00:00
loader [libc] Enable a few stdlib and time functions on aarch64. 2022-07-14 14:37:50 -07:00
spec [libc] Add dirent.h functions opendir, readdir, closedir and dirfd. 2022-07-25 20:23:25 +00:00
src [libc] Use nearest_integer instructions to improve expm1f performance. 2022-07-26 09:12:37 -04:00
test [libc][Obvious] Use the correct StringView constructor in dirent_test. 2022-07-25 20:47:17 +00:00
utils [libc] Specify rounding mode for strto[f|d] tests 2022-07-13 20:20:30 +00:00
.clang-tidy
.gitignore [libc][Obvious] Add build folder to .gitignore. 2022-03-04 13:16:55 -05:00
CMakeLists.txt [libc] Implement FLAGS option for generating all combinations for targets. 2022-06-01 00:54:07 -04: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.