Demonstrate sparse matrix-vector multiplication with Intel MKL.
Make sure you have the Intel oneAPI HPC Toolkit or Intel Fortran Essentials.
Get the external dependencies.
# Get externals
git submodule update --init
Then, you can configure the project.
./config/intel_ubuntu
Alternatively, if on a system where you need to specify a different MKL library
and MKL include path, you can do this with the flags -DMKLLIB
and -DMKLINCLUDE
during configuration. The below bash script does the necessary configuration,
as an example, for DKRZ's Levante.
./config/intel_levante
Lastly, you build the project and execute an example binary.
cmake --build build
./build/test/test_spblas
- Test file based on gist.
- Cmake linking based on link line advisor
- Installing intel fortran compiler
- Installing mkl
- Set environment vars
- I did
INCLUDE mkl_spblas.f90
above thePROGRAM
statement and theuse mkl_spblas
in the program block since i mimicked the direct sparse solver example for f90 on pg. 1941 of the mkl manual - Directory structure from fpm even though using cmake
- fftpack uses cmake for dependencies instead of git submodule and fetch content