A simple script to benchmark, and hopefully illustrate good practices of tensor operations in Modern Fortran
You need an installation of OpenBLAS that is compiled with USE_OPENMP=1
, see here for notes
gfortran dgemm_test.f90 -o dgemm_test -lopenblas -fopenmp -O3
ifort dgemm_test.f90 -o dgemm_test -L${MKLROOT}/lib/intel64 -lmkl_intel_ilp64 -lmkl_intel_thread -lmkl_core -liomp5 -lpthread -lm -ldl -i8 -I"${MKLROOT}/include" -fopenmp -O3 -heap-arrays