diff options
author | Tue Ly <lntue@google.com> | 2022-07-25 13:44:46 -0400 |
---|---|---|
committer | Tue Ly <lntue@google.com> | 2022-07-26 09:12:37 -0400 |
commit | 628fbbef81c5ac806e6dbf2bce18dd44980051b1 (patch) | |
tree | 01ce1e4e9065501a8bc9f09958a8437248def414 /llvm/lib/Bitcode | |
parent | 91ee67206289ec80c3c02f063040fa4638be0d63 (diff) | |
download | llvm-628fbbef81c5ac806e6dbf2bce18dd44980051b1.zip llvm-628fbbef81c5ac806e6dbf2bce18dd44980051b1.tar.gz llvm-628fbbef81c5ac806e6dbf2bce18dd44980051b1.tar.bz2 |
[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
Diffstat (limited to 'llvm/lib/Bitcode')
0 files changed, 0 insertions, 0 deletions