[libc-commits] [PATCH] D132809: [libc][math] Added auxiliary function log2_eval for asinhf/acoshf/atanhf.

Kirill Okhotnikov via Phabricator via libc-commits libc-commits at lists.llvm.org
Sun Aug 28 10:14:49 PDT 2022


orex created this revision.
orex added reviewers: lntue, sivachandra, zimmermann6.
Herald added subscribers: libc-commits, ecnelises, tschuett, mgorny.
Herald added projects: libc-project, All.
orex requested review of this revision.

1. `double log2_eval(double)` function added with better than float precision is added.
2. Some refactoring done to put all auxiliary functions and corresponding data

to one place to reuse the code.

3. Added tests for new functions.
4. Performance and precision tests of the function shows, that it more precise than exiting log2,

(no exceptional cases), but timing is ~5% higer that on current one.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D132809

Files:
  libc/src/math/generic/CMakeLists.txt
  libc/src/math/generic/common_constants.cpp
  libc/src/math/generic/common_constants.h
  libc/src/math/generic/coshf.cpp
  libc/src/math/generic/exp2f.cpp
  libc/src/math/generic/expxf.h
  libc/src/math/generic/sinhf.cpp
  libc/src/math/generic/supfuncf.cpp
  libc/src/math/generic/supfuncf.h
  libc/src/math/generic/tanhf.cpp
  libc/test/src/CMakeLists.txt
  libc/test/src/math/CMakeLists.txt
  libc/test/src/math/expxf_test.cpp
  libc/test/src/math/supfuncf_test.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D132809.456193.patch
Type: text/x-patch
Size: 20056 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/libc-commits/attachments/20220828/ad42a990/attachment-0001.bin>


More information about the libc-commits mailing list