Intel® oneAPI Math Kernel Library
Ask questions and share information with other developers who use Intel® Math Kernel Library.

VML crashes in DLL projects

w32
초급자
1,072 조회수
My custom DLL contains comuptation with VML functions call. MKL 9.0 is linked to DLL throw mkl_c.lib and libguide.lib.
But when app calls my DLL computation code, process is crached in any vml functions. Debuger shows exception (access violation) in TLS read code.

Example (vml code for cpu specific GetMode function):

mov ecx,dword ptr ds:[2CC31BCh] (this is __tls_index)
mov edx,dword ptr fs:[2Ch]
mov ebx,dword ptr [edx+ecx*4] (exception (ecx == 0 and edx == 0))


Can you help me?
0 포인트
6 응답
Andrey_N_Intel
1,072 조회수

Thank you for your question. Could youlink your DLL to mkl_c_dll.lib? This should help. Please, let us know how it works for you.

0 포인트
w32
초급자
1,072 조회수
Thanks, mkl_c_dll.lib resolves problem.

But now my DLL use dynamic MKL dlls and total size of application is very large (~40Mb). How can i decrease size?
0 포인트
Andrey_N_Intel
1,072 조회수
If your application contains calls to VML functions only you might want to link your DLL tomkl_vml_*.dll, msvcr71.dll,and libguide40.dll. Please, let's know how it works for you. Thanks.
0 포인트
w32
초급자
1,072 조회수
No. My DLL uses some LAPACK funtions.
0 포인트
Andrey_N_Intel
1,072 조회수
You could link your application also to mkl_lapack32.dll or mkl_lapack64.dll (depending on the data type you use) in addition to the VML related dlls.
0 포인트
w32
초급자
1,072 조회수
Thank you.
0 포인트
응답