Intel® oneAPI Math Kernel Library
Ask questions and share information with other developers who use Intel® Math Kernel Library.
Announcements
Welcome to the Intel Community. If you get an answer you like, please mark it as an Accepted Solution to help others. Thank you!

Executables linked with MKL crash

MemoryLeak
Beginner
337 Views

Hey Guys,

I'm using Windows 10, Version 10.0.18362 Build 18362, on a x64-based Intel Core i7 processor. I installed MKL using w_mkl_2020.4.311.exe and it perfectly integrated into my Visual Studio 2019.

In the Visual Studio debugger I can use MKL functions without problems. If I try to execute the .exe-file in the folder (release/debug), it crashes. Here is the impelmentation:

#include <iostream>
#include <mkl.h>

int main() {

const double *a = new double [4] {1,2,3,4 };
const double* b = new double[4]{ 1,2,3,4 };
double* r = new double[4]{ 0,0,0,0 };

vdAdd(4, a, b, r);

return 0;

}

The crash occurs when invoking vdAdd. What could be causing this problem?

Thanks in advance!
Greetings,
MemoryLeak

 

0 Kudos
2 Replies
mecej4
Black Belt
326 Views

Please detail how you "execute the .exe-file in the folder" .

If you simply open a plain command window and attempt to run an EXE that depends on Intel compiler and MKL DLLs, the EXE will not run unless PATH has been modified to make those DLLs accessible.

Another possibility is that when you build and run inside the VS debugger the EXE that gets run is not in the folder that you think that it should be in. Check the creation date of the EXE in the folder for agreement with what you would expect it to be.

I built and ran your code in a CMD window configured for Parallel Studio 2020, without opening Visual Studio at all, and it ran fine.

Gennady_F_Intel
Moderator
279 Views

This issue has been resolved and we will no longer respond to this thread. If you require additional assistance from Intel, please start a new thread. Any further interaction in this thread will be considered community only. 



Reply