I now want to upgrade these to run with MAGMA 1.1.0 and CUDA 4.0
I am having problems with the linking which I can illustrate with the testing example testing_degetrf_gpu_f
In the magma_1.1.0/testing environment it links like this (noting that in MAGMA 1.1.0 the source code is *.f90)
Code: Select all
gfortran -O3 -DADD_ -x f95-cpp-input -Dmagma_devptr_t="integer(kind=8)" -I/usr/local/cuda/include -I../include -I../quark/include -c testing_dgetrf_gpu_f.f90 -o testing_dgetrf_gpu_f.o
gfortran -O3 -DADD_ -DGPUSHMEM=200 -fPIC -Xlinker -zmuldefs -DGPUSHMEM=200 testing_dgetrf_gpu_f.o fortran.o -o testing_dgetrf_gpu_f lin/liblapacktest.a -L../lib \
-lcuda -lmagma -lmagmablas -lmagma -L/home/fletcher/GotoBLAS2 -L/usr/lib64 -L/usr/local/cuda/lib64 -lgoto2 -lpthread -lcublas -lcudart -llapack -lm
rm testing_dgetrf_gpu_f.o
make[1]: Leaving directory `/home/fletcher/magma_1.1.0/testing'
Code: Select all
fletcher@fletcher-desktop:~/sotos/super3drun3$ make testing_dgetrf_gpu_f
gfortran -O3 -DADD_ -x f95-cpp-input -Dmagma_devptr_t="integer(kind=8)" -DGPUSHMEM=200 -I/usr/local/cuda/include -I/home/fletcher/magma_1.1.0/include -c testing_dgetrf_gpu_f.f -o testing_dgetrf_gpu_f.o
gfortran -O3 -DADD_ -DGPUSHMEM=200 -fPIC -Xlinker -zmuldefs -DGPUSHMEM=200 testing_dgetrf_gpu_f.o /home/fletcher/magma_1.1.0/testing/fortran.o -o testing_dgetrf_gpu_f /home/fletcher/magma_1.1.0/testing/lin/liblapacktest.a -L/home/fletcher/magma_1.1.0/lib \
-lcuda -lmagma -lmagmablas -lmagma -L/home/fletcher/GotoBLAS2 -L/usr/lib64 -L/usr/local/cuda/lib -lgoto2 -lpthread -lcublas -lcudart -lm -Xlinker -R/home/fletcher/magma_1.1.0/lib -Xlinker -R/usr/local/cuda/lib -Xlinker -R/home/fletcher/GotoBLAS2
testing_dgetrf_gpu_f.o: In function `MAIN__':
testing_dgetrf_gpu_f.f:(.text+0x3f3): undefined reference to `magma_dgetrf_gpu_'
testing_dgetrf_gpu_f.f:(.text+0x468): undefined reference to `magma_dgetrs_gpu_'
collect2: ld returned 1 exit status
make: *** [testing_dgetrf_gpu_f] Error 1
Is it not possible to link *.f files? What is happening to cause this problem with FORTRAN linking.
I have looked in the Release Notes but can find no note of these changes.
Thank you
John