Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Configure.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ endif()

if (SLEEF_ENABLE_TLFLOAT)
set(TLFLOAT_MINIMUM_VERSION 1.12.0)
set(TLFLOAT_GIT_TAG "65af4a47b38e9ad09fe139f2e79eda6a6277b912")
set(TLFLOAT_GIT_TAG "3615de3925fa8321c40b77730af372666626c41b")

set(TLFLOAT_SOURCE_DIR "${PROJECT_SOURCE_DIR}/submodules/tlfloat")
set(TLFLOAT_INSTALL_DIR "${SLEEF_SUBMODULE_INSTALL_DIR}/tlfloat")
Expand Down
196 changes: 196 additions & 0 deletions README.adoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,196 @@
== SLEEF - SIMD Library for Evaluating Elementary Functions

SLEEF is a library that implements vectorized versions of C standard
math functions. This library also includes DFT subroutines.

* *Web Page:* https://sleef.org/
* *Sources:* https://github.com/shibatch/sleef

== Supported environment

=== Test matrix

The following table summarizes currently supported OSes and compilers.

[cols="1,1,1,1,1,1,1,1,1"]
|===

|
2+|Linux
4+|Windows
2+|Mac

|
|gcc
|llvm
|MSVC
|Clang
|MinGW
|Cygwin
|Clang
|GCC

|x86_64
|✔
|✔
|✔
|✔
|✔
|✖
|✔
|?

|RISC-V 64
|✔
|?
|N/A
|N/A
|N/A
|N/A
|N/A
|N/A

|AArch64
|✔
|✔
|✖
|✖
|✖
|✖
|✔
|?

|POWER
|✔
|?
|N/A
|N/A
|N/A
|N/A
|N/A
|N/A

|S390X
|✔
|?
|N/A
|N/A
|N/A
|N/A
|N/A
|N/A

|AArch32
|✔
|?
|N/A
|N/A
|N/A
|N/A
|N/A
|N/A

|===

✔ : Tested on CI, ? : Not tested, ✖ : Not supported


== How to build SLEEF

The library itself does not have any additional dependency.

In order to build SLEEF, you need CMake 3.18+, and C and C++ compilers of the same version.
It is also recommended to have the following tools.

* Ninja
* Git

https://github.com/shibatch/tlfloat[TLFloat] is automatically downloaded if no suitable version is found on your system.

Some tests require:

* libssl and libcrypto, that can be provided by installing openssl.
* libm, libgmp and libmpfr
* libfftw.


The build procedure is as follows.

[arabic]
. Check out the source code from our GitHub repository

....
git clone https://github.com/shibatch/sleef
....

[arabic, start=2]
. Make a separate directory to create an out-of-source build

....
cd sleef && mkdir build
....

[arabic, start=3]
. Run cmake to configure the project

....
cmake -S . -B build
....

By default this will generate shared libraries. In order to generate
static libraries, pass option `-DBUILD_SHARED_LIBS=OFF`.

For more verbose output add option `-DSLEEF_SHOW_CONFIG=ON`.

[arabic, start=4]
. Run make to build the project

....
cmake --build build -j --clean-first
....

[arabic, start=5]
. Run tests using ctests

....
ctest --test-dir build -j
....

For more detailed build instructions please refer to the
link:./docs/1-user-guide/build-with-cmake[dedicated section on CMake] or
to https://sleef.org/1-user-guide/#preliminaries[our web page].

== How to cross-compile SLEEF

For more detailed please refer to
link:./docs/1-user-guide#cross_linux[cross-compile SLEEF]

== Install SLEEF

=== From source

Assuming following instructions were followed.

[arabic, start=6]
. Install to specified directory `<prefix>`

....
cmake --install build --prefix=<prefix>
....

=== Uninstall

In order to uninstall SLEEF library and headers run

....
sudo xargs rm -v < build/install_manifest.txt
....

== License

The software is distributed under the Boost Software License, Version
1.0. See accompanying file link:./LICENSE.txt[LICENSE.txt] or copy at
http://www.boost.org/LICENSE_1_0.txt. Contributions to this project are
accepted under the same license.

Copyright © 2010-2025 SLEEF Project, Naoki Shibata and contributors.
Loading
Loading