Problem with "magma_stream" while compiling

Open discussion for MAGMA

Problem with "magma_stream" while compiling

Postby Edu_Cepas » Wed Mar 07, 2012 9:45 am

Hello,

I've compiled the library MAGMA and the test examples succesfully. The examples work perfectly.

Then, I want to use the "magma_zhegvx" function in a program. The problem I have is that the compiler doesn't find a reference to "magma_stream" while linking... I paste the error below.

I have linked the executable to -lmagma and -lmagmablas, and in the code where I use "magma_zhegvx" I have included

#include "magma.h"
#include "magma_z.h"
#include "magmablas_z.h"

Do I need to include or link something else?¿
Do you have any idea of what am I doing wrong?¿

Thank you so much in advance for your help.
EDU.

Building target: ../../../bin/inma
Invoking: Intel IA-32 C++ Linker
icpc -L../../../lib -mkl=sequential -o"../../../bin/inma" ./inma.o -lnma -lpdb2 -ltools -lmagma -lmagmablas -lcuda -lcublas -lcudart -L/home/eduardo/MAGMA/magma_1.1.0/install/lib -L/usr/local/cuda/lib64
ipo: warning #11021: unresolved magma_stream
Referenced in libmagmablas.a(zlanhe.cu_o)
Referenced in libmagmablas.a(zlascl.cu_o)
Referenced in libmagmablas.a(zauxiliary.cu_o)

ipo: remark #11000: performing multi-file optimizations
ipo: remark #11006: generating object file /tmp/ipo_icpcw8vesV.o
/home/eduardo/MAGMA/magma_1.1.0/install/lib/libmagmablas.a(zauxiliary.cu_o): In function `magmablas_zsetdiag1subdiag0':
tmpxft_00007074_00000000-1_zauxiliary.cudafe1.cpp:(.text+0x681): undefined reference to `magma_stream'
tmpxft_00007074_00000000-1_zauxiliary.cudafe1.cpp:(.text+0x6c3): undefined reference to `magma_stream'
/home/eduardo/MAGMA/magma_1.1.0/install/lib/libmagmablas.a(zauxiliary.cu_o): In function `zzero_32x32_block':
tmpxft_00007074_00000000-1_zauxiliary.cudafe1.cpp:(.text+0xa5b): undefined reference to `magma_stream'
/home/eduardo/MAGMA/magma_1.1.0/install/lib/libmagmablas.a(zauxiliary.cu_o): In function `zzero_nbxnb_block':
tmpxft_00007074_00000000-1_zauxiliary.cudafe1.cpp:(.text+0xcf0): undefined reference to `magma_stream'
/home/eduardo/MAGMA/magma_1.1.0/install/lib/libmagmablas.a(zauxiliary.cu_o): In function `magmablas_zlaset':
tmpxft_00007074_00000000-1_zauxiliary.cudafe1.cpp:(.text+0xe4d): undefined reference to `magma_stream'
/home/eduardo/MAGMA/magma_1.1.0/install/lib/libmagmablas.a(zauxiliary.cu_o):tmpxft_00007074_00000000-1_zauxiliary.cudafe1.cpp:(.text+0xf23): more undefined references to `magma_stream' follow
make: *** [../../../bin/inma] Error 1
Edu_Cepas
 
Posts: 4
Joined: Fri Feb 10, 2012 6:43 am

Re: Problem with "magma_stream" while compiling

Postby jeremiahpalmer » Wed Mar 07, 2012 3:42 pm

Try compiling with:

-Wl,--start-group $(magma_dir)/lib/libmagma.a \
$(magma_dir)/lib/libmagmablas.a -Wl,--end-group

Where magma_dir is the location of the magma directory.
jeremiahpalmer
 
Posts: 58
Joined: Fri Jan 28, 2011 12:46 pm

Re: Problem with "magma_stream" while compiling

Postby fletchjp » Wed Mar 07, 2012 7:38 pm

The magma_stream problem has come up before. See the following topic:

Different results for DGEQRF_GPU and DGEQRF2_GPU
fletchjp
 
Posts: 175
Joined: Mon Dec 27, 2010 7:29 pm

Re: Problem with "magma_stream" while compiling

Postby Edu_Cepas » Thu Mar 08, 2012 8:16 am

Ok, thank you so much. I have solved my problem with the info of the thread you told me.
Edu_Cepas
 
Posts: 4
Joined: Fri Feb 10, 2012 6:43 am

Re: Problem with "magma_stream" while compiling

Postby fletchjp » Fri Mar 09, 2012 12:29 pm

Thank you
fletchjp
 
Posts: 175
Joined: Mon Dec 27, 2010 7:29 pm

Re: Problem with "magma_stream" while compiling

Postby mgates3 » Fri Mar 09, 2012 2:35 pm

Or just repeat -lmagma:

-lmagma -lmagmablas -lmagma

-mark
mgates3
 
Posts: 427
Joined: Fri Jan 06, 2012 2:13 pm


Return to User discussion

Who is online

Users browsing this forum: No registered users and 1 guest

cron