[all-commits] [llvm/llvm-project] eed9b4: [libc][math][c23] Implement C23 math function asin...
Mohamed Emad via All-commits
all-commits at lists.llvm.org
Sat Jul 26 04:02:40 PDT 2025
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: eed9b4e05810381d8655f40fe298abb2f90a95cf
https://github.com/llvm/llvm-project/commit/eed9b4e05810381d8655f40fe298abb2f90a95cf
Author: Mohamed Emad <hulxxv at gmail.com>
Date: 2025-07-26 (Sat, 26 Jul 2025)
Changed paths:
M libc/config/linux/aarch64/entrypoints.txt
M libc/config/linux/x86_64/entrypoints.txt
M libc/docs/headers/math/index.rst
M libc/include/math.yaml
M libc/src/math/CMakeLists.txt
A libc/src/math/asinpif16.h
M libc/src/math/generic/CMakeLists.txt
A libc/src/math/generic/asinpif16.cpp
M libc/test/src/math/CMakeLists.txt
A libc/test/src/math/asinpif16_test.cpp
M libc/test/src/math/smoke/CMakeLists.txt
A libc/test/src/math/smoke/asinpif16_test.cpp
M libc/utils/MPFRWrapper/MPCommon.cpp
M libc/utils/MPFRWrapper/MPCommon.h
M libc/utils/MPFRWrapper/MPFRUtils.cpp
M libc/utils/MPFRWrapper/MPFRUtils.h
Log Message:
-----------
[libc][math][c23] Implement C23 math function asinpif16 (#146226)
The function is implemented using the following Taylor series that's
generated using [python-sympy](https://www.sympy.org/en/index.html), and
it is very accurate for |x| $$\in [0, 0.5]$$ and has been verified using
Geogebra. The range reduction is used for the rest range (0.5, 1].
$$
\frac{\arcsin(x)}{\pi} \approx
\begin{aligned}[t]
& 0.318309886183791x \\
& + 0.0530516476972984x^3 \\
& + 0.0238732414637843x^5 \\
& + 0.0142102627760621x^7 \\
& + 0.00967087327815336x^9 \\
& + 0.00712127941391293x^{11} \\
& + 0.00552355646848375x^{13} \\
& + 0.00444514782463692x^{15} \\
& + 0.00367705242846804x^{17} \\
& + 0.00310721681820837x^{19} + O(x^{21})
\end{aligned}
$$
## Geogebra graph

Closes #132210
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list