urvesh
January 16, 2014, 8:12am
1
I want to use magma for linear algebra operations. I couldn’t find proper guide for installation
I am using CentOS with CUDA toolkit 5.5 installed on it.
What other libraries do I need to install as prerequisite and how to get them?
how to make proper make.inc file?
Thanks!
urvesh
January 21, 2014, 6:47am
2
finally, I was able to use it after some struggle…
Few points for someone who may have same issues or confusion
read README file properly. Find out what you need according to your requirements
Apart from CUDA, Make sure you have Lapack, ATLAS and BLAS installed. find their directory
(in my case, in CentOS, you can do it by “yum install blas.x86_64 atlas.x86_64 lapack.x86_64 ”)
find the installed directory (use “locate command”)
prepare “make.inc” file. edit make.inc.atlas
here is how my file looked like
GPU_TARGET = Kepler
CC = gcc
NVCC = nvcc
FORT = gfortran
ARCH = ar
ARCHFLAGS = cr
RANLIB = ranlib
OPTS = -O3 -DADD_ -fopenmp -DMAGMA_SETAFFINITY
F77OPTS = -O3 -DADD_
FOPTS = -O3 -DADD_ -x f95-cpp-input
NVOPTS = -O3 -DADD_ -Xcompiler -fno-strict-aliasing
LDOPTS = -fopenmp
Depending on how ATLAS and LAPACK were compiled, you may need one or more of:
-lifcore -ldl -lf2c -lgfortran
LIB = -llapack -lf77blas -latlas -lcblas -lcublas -lcudart -lstdc++ -lm -lgfortran
define library directories here or in your environment
LAPACKDIR = /usr/lib64
ATLASDIR = /usr/lib64/atlas
CUDADIR = /usr/local/cuda
-include make.check-atlas
-include make.check-cuda
LIBDIR = -L$(LAPACKDIR)
-L$(ATLASDIR)
-L$(CUDADIR)/lib64
INC = -I$(CUDADIR)/include
run “make”
make “install”
some related issues…
in CentOS I had to setup symbolic links for files like liblapack.so.3.2.1 to liblapack.so using -ln command. Before that they were not detected