NSIMD comes with several additional modules. A module provides a set of functionnalities that are usually not at the same level as SIMD intrinsics and/or that do not provide all C and C++ APIs. These functionnalities are given with the library because they make heavy use of NSIMD core which abstract SIMD intrinsics. Below is the exhaustive list of modules.
Memory management
This module provides C-style memory managmenent functions:
malloc, calloc, free, copy to/from devices, etc... Its purpose is to facilitate
the use of data buffers in a portable way for systems with CPUs only and
for systems with CPUs and GPUs.
Fixed-point arithmetic
This module provides vectorized fixed-point arithmetic through
a C++98 API. The programmer can choose the integral type and the place of the
coma for representing its fixed-point numbers. A number of operators are
also provided.
Random number generators
This module define functions that generate pseudorandom numbers usingalgorithms described in Parallel Random Numbers: As Easy as 1,2,3, byJohn K. Salmon, Mark A. Moraes, Ron O. Dror and David E.Shaw.
Tiny expression templates 1D
This module provide a thin layer of expression templates above
NSIMD core. It also allows the programmer to target Intel, NVIDIA and AMD GPUs.
Expression template are a C++ technique that allows the programmer to write
code "à la MATLAB" where variables usually represents vectors and operators
are itemwise.
SPMD programming
SPMD programming allows the programmer to focus on kernels and
the compiler to vectorize kernel code more effectively. Basically this
module provides a "à la CUDA" programming C++ DSL to targets CPU SIMD as well
as Intel, NVIDIA and AMD GPUs.