Intel® Moderncode for Parallel Architectures
Support for developing parallel programming applications on Intel® Architecture.

Problem

Martin_Fuchs
Beginner
1,577 Views
Hello I have following problem. I want to use mkl on a Intel core2 CPU (Vendor ID: GenuineIntel) using the ifort compiler. I get this error message:
/home/fuchs/intel/Compiler/11.1/072/mkl/lib/em64t/libmkl_pgi_thread.so: undefined reference to `__mth_i_dfloatuk'
/home/fuchs/intel/Compiler/11.1/072/mkl/lib/em64t/libmkl_pgi_thread.so: undefined reference to `_mp_orders_chunk8'
/home/fuchs/intel/Compiler/11.1/072/mkl/lib/em64t/libmkl_pgi_thread.so: undefined reference to `_mp_penter'
/home/fuchs/intel/Compiler/11.1/072/mkl/lib/em64t/libmkl_pgi_thread.so: undefined reference to `_mp_lcpu2'
/home/fuchs/intel/Compiler/11.1/072/mkl/lib/em64t/libmkl_pgi_thread.so: undefined reference to `_mp_orders_init8'
/home/fuchs/intel/Compiler/11.1/072/mkl/lib/em64t/libmkl_pgi_thread.so: undefined reference to `_mp_ncpus'
/home/fuchs/intel/Compiler/11.1/072/mkl/lib/em64t/libmkl_pgi_thread.so: undefined reference to `_mp_pexit'
/home/fuchs/intel/Compiler/11.1/072/mkl/lib/em64t/libmkl_pgi_thread.so: undefined reference to `__fmth_i_dsincos'
/home/fuchs/intel/Compiler/11.1/072/mkl/lib/em64t/libmkl_pgi_thread.so: undefined reference to `__c_mset4'
/home/fuchs/intel/Compiler/11.1/072/mkl/lib/em64t/libmkl_pgi_thread.so: undefined reference to `__c_mcopy8'
/home/fuchs/intel/Compiler/11.1/072/mkl/lib/em64t/libmkl_pgi_thread.so: undefined reference to `_mp_p'
/home/fuchs/intel/Compiler/11.1/072/mkl/lib/em64t/libmkl_pgi_thread.so: undefined reference to `_mp_orders_beg'
/home/fuchs/intel/Compiler/11.1/072/mkl/lib/em64t/libmkl_pgi_thread.so: undefined reference to `_mp_scheds8'
/home/fuchs/intel/Compiler/11.1/072/mkl/lib/em64t/libmkl_pgi_thread.so: undefined reference to `_mp_scheds_dyn_init8'
/home/fuchs/intel/Compiler/11.1/072/mkl/lib/em64t/libmkl_pgi_thread.so: undefined reference to `_mp_scheds'
/home/fuchs/intel/Compiler/11.1/072/mkl/lib/em64t/libmkl_pgi_thread.so: undefined reference to `_mp_ncpus2'
/home/fuchs/intel/Compiler/11.1/072/mkl/lib/em64t/libmkl_pgi_thread.so: undefined reference to `__c_mzero4'
/home/fuchs/intel/Compiler/11.1/072/mkl/lib/em64t/libmkl_pgi_thread.so: undefined reference to `_mp_scheds_dyn_init'
/home/fuchs/intel/Compiler/11.1/072/mkl/lib/em64t/libmkl_pgi_thread.so: undefined reference to `__c_mcopy8_bwd'
/home/fuchs/intel/Compiler/11.1/072/mkl/lib/em64t/libmkl_pgi_thread.so: undefined reference to `_mp_v'
/home/fuchs/intel/Compiler/11.1/072/mkl/lib/em64t/libmkl_pgi_thread.so: undefined reference to `_mp_penter_set'
...

I used this compiler settings:
/home/fuchs/intel/Compiler/11.1/072/bin/intel64/ifort -O3 /home/fuchs/workspace-f90/Schwerefeldbestimmung/*.o RefOrbit.f90 -o RefOrbit -I/home/fuchs/workspace-f90/Schwerefeldbestimmung/ -L/home/fuchs/intel/Compiler/11.1/072/mkl/lib/em64t -lmkl_pgi_thread -lmkl_core -lmkl_intel_ilp64 -lmkl_lapack95_ilp64 -openmp

Can someone help me please...


0 Kudos
7 Replies
Michael_K_Intel2
Employee
1,579 Views
Hi Martin,

the unresolved symbols that you've seen come from the PGI threading library of MKL. As you're compiling and linking with ifort you should remove the PGI library from the command line and replace with either libmkl_gnu_thread.a or libmkl_intel_thread.a.

Does that work out for you?

Cheers,
-michael
0 Kudos
Martin_Fuchs
Beginner
1,577 Views
Jep that worked... now I can compile without any errors but when I start the executable it says...
./RefOrbit: error while loading shared libraries: libmkl_intel_thread.so: cannot open shared object file: No such file or directory

0 Kudos
Gennady_F_Intel
Moderator
1,579 Views
Martin,
my 2 cents regarding this issue: for the future it would be usefull if you will refer to the MKL Linker Adviser, which will provide thr proper linking line for all most important combinations.
--Gennady
0 Kudos
Gennady_F_Intel
Moderator
1,577 Views
did you check LD_LIBRARY_PATH?
0 Kudos
Martin_Fuchs
Beginner
1,579 Views
Jepped that worked... Now finally this error
./RefOrbit: error while loading shared libraries: libiomp5.so: cannot open shared object file: No such file or directory

this might be similar I guess...
0 Kudos
Martin_Fuchs
Beginner
1,579 Views
LD_LIBRARY_PATH=/DGFI16/home/fuchs/intel/Compiler/11.1/072/lib/intel64:$LD_LIBRARY_PATH
^^ so finally I made it... Thanks so much to every one... !!! With this last line it compiled and worked...
0 Kudos
Gennady_F_Intel
Moderator
1,579 Views
Well. Thats fine. Let me add one more comment regarding error while loading shared libraries: libiomp5.so
I noticed you uses MKL version which is bundled with Intel Compiler,
hence in this case all libiomp*.* binary objects are situated into /lib/intel64/ directory,
Where, as I guess in your case == /home/fuchs/intel/Compiler/11.1/072/
--Gennady
0 Kudos
Reply