The CORE-MATH project

[FAQ] [git] [mailing list] [worst cases] [references]

CORE-MATH Mission: provide on-the-shelf high performance open-source mathematical functions with correct rounding that can be integrated into current mathematical libraries (GNU libc, Intel Math Library, AMD Libm, Newlib, OpenLibm, Musl, Apple Libm, llvm-libc, Microsoft libm, CUDA libm, ROCm)

Average number of clock cycles needed by CORE-MATH functions (revision 55c872b, f5d9e09 for log2l) on an Intel Xeon Silver 4214, with GCC 13.2.0, compared to GNU libc 2.37, the Intel Math Library from icx 2023.2.0 and LLVM libc (revision d099dbb):

Usages of CORE-MATH:

Available CORE-MATH functions (under MIT license):

functionbinary32binary64binary80binary128
acos code code
acosh code code
acospi code code
asin code code
asinh code code
asinpi code code
atan code code
atan2 code code
atan2pi code code
atanh code code
atanpi code code
cbrt code code (proof) code
cos code code
cosh code code
cospi code code
erf code code
erfc code code
exp code code
exp10 code code
exp10m1 code code
exp2 code code code
exp2m1 code code
expm1 code code
hypot code code
lgamma code
log code code (with Gappa proof)
log10 code code
log10p1 code code
log1p code code
log2 code code code
log2p1 code code
pow code code
rsqrt code code
sin code code
sincos
sinh code code
sinpi code code
tan code code
tanh code code
tanpi code code
tgamma code

Caption:

Notes:

Other correctly-rounded implementations:

functionbinary32binary64binary80binary128
acos rlibm llvm crlibm
acosh llvm
acospi crlibm
asin rlibm llvm crlibm
asinh llvm
asinpi crlibm
atan rlibm llvm crlibm
atan2 llvm
atan2pi
atanh llvm crlibm
atanpi crlibm
cbrt llvm llvm
cos rlibm llvm,llvm crlibm,llvm
cosh rlibm llvm llvm crlibm
cospi rlibm,llvm crlibm
erf llvm
erfc
exp rlibm llvm,llvm crlibm, llvm
exp10 rlibm llvm llvm
exp10m1
exp2 rlibm llvm llvm llvm crlibm, llvm
exp2m1 llvm
expm1 llvm,llvm crlibm,llvm
hypot llvm,llvm llvm
lgamma
log rlibm llvm crlibm, llvm
log10 rlibm llvm crlibm, llvm
log10p1
log1p llvm crlibm, llvm
log2 rlibm llvm crlibm, llvm
log2p1
pow llvm (see this) crlibm (2)
rsqrt
sin rlibm llvm,llvm crlibm,llvm
sincos llvm
sinh rlibm llvm llvm crlibm
sinpi rlibm,llvm crlibm
tan rlibm llvm,llvm crlibm,llvm
tanh llvm llvm
tanpi crlibm
tgamma