0

I am new with intel_mkl. I downloaded it as a researcher for 12 months from the site. I am using visual studio 2012 C on windows 10 64 bits. I have i7 core.

I wanted to solve a large linear system of equations thus I am using dgesv_to solve this system and it works. But because of the issue of row major and column major issue the solution was wrong.

I searched for a solution for the problem and I found LAPACKE_dgesv( LAPACK_ROW_MAJOR, n, nrhs, a, lda, ipiv, b, ldb );with the following header files:

#include <mkl.h>
#include <mkl_cblas.h>
#include <mkl_blas.h>
#include <mkl_lapack.h>
#include <mkl_lapacke.h>

but it gives me the following error

fatal error LNK1120: 1 unresolved externals

When I searched for a solution, I found that they are telling to linklibmkl_intel_ilp64.akernel32.lib or libmkl_intel_lp64.akernel32.lib according to the use of lp64 or ilp64. I don't know which one the system uses. Thus, I tried both of them (as try and error) but it gives the following error

LINK : fatal error LNK1104: cannot open file 'libmkl_intel_ilp64.akernel32.lib'

NB: (if it matters) solution platform is win32

Update:

I added in the additional library directory the following url "C:\Program Files (x86)\IntelSWTools\compilers_and_libraries_2016.3.207\windows\mkl\lib\intel64_win" Also I added in the C/C++ general additional include directories"C:\Program Files (x86)\IntelSWTools\compilers_and_libraries_2016.3.207\windows\mkl\include"

Now the old errors disappeared, but a new error appeared

Source.obj : error LNK2019: unresolved external symbol _LAPACKE_dgesv referenced in function _main

What shall I do with this error

1 Answers1

0

Should it be libmkl_intel_ilp64.a kernel32.lib?

You may want to use this to help you generate correct link options.

https://software.intel.com/en-us/articles/intel-mkl-link-line-advisor

There are many discussions about ILP64/LP64. You may want to Google them.

https://software.intel.com/en-us/node/528353

kangshiyin
  • 9,681
  • 1
  • 17
  • 29
  • I already tried it but the problem is I don't know the answer for questions he is asking like and I don't know how to know it like: static and dynamic linking, interface layer, threading layer. can you help me how to find them or answer them – mahmoud ayyad Jul 19 '16 at 22:32
  • @mahmoudayyad a typical setting is dynamic linking, LP64, OpenMP threading. Everything is your choice except for the interface layer. – kangshiyin Jul 20 '16 at 01:17
  • when I used what u told me it gives me the following error " LINK : fatal error LNK1104: cannot open file 'mkl_intel_lp64_dll.lib mkl_core_dll.lib mkl_intel_thread_dll.lib' " – mahmoud ayyad Jul 22 '16 at 18:07
  • Did you tell your compiler where to find these files by setting the environment variable ${MKLROOT}, or by changing it directly to the path of MKL libraries? – kangshiyin Jul 22 '16 at 18:24
  • I have edited the post as I solved the problem... may you please see the new error and tell me what should i do now – mahmoud ayyad Jul 22 '16 at 19:17