Community
cancel
Showing results for 
Search instead for 
Did you mean: 
netphilou31
New Contributor II
144 Views

runtime dlls required

Hi,

I would like to know which runtime dlls are required to use the vslNewStream, vdRngUniform and vslDeleteStream functions of the MKL. My application (dll) loads some of them manually (using the LoadLibrary function) at the begining and the application runs fine (I load manually the following dlls: libmmd, libifcoremdd, libifportmd, libiomp5md, msvcr100d, mkl_core, mkl_sequential and mkl_vml_avx) except that the dll named "mkl_vml_avx" does not seem to be correctly unloaded before leaving my dll even if the FreeLibrary function returns a non zero value (no information of unloading the dll in Visual Studio output window). However, the second time I try to use the vslNewStream function in my dll (after my dll is unloaded and loaded again) my application crashes at the line calling the vslNewStream function. I have checked that the first time the vslNewStream call returns 0 as well as the vdRngUniform and vslDeleteStream function so the calls seem to be ok.

Any idea ?

Best regards,

Phil.

 

0 Kudos
6 Replies
Zhen_Z_Intel
Employee
144 Views

Dear customer,

Symbols for vslNewStream, vslRngUniform and vslDeleteStream are defined in dll for interface layer. Seems you didn't add to link with interface layer dll. Please use MKL advisor to check which dll you should select for corresponding platform. Thanks.

Best regards,
Fiona

netphilou31
New Contributor II
144 Views

Hi Fiona,

Thanks for your reply,

I used the link you provided, but it seems that I need to add libraries to my link step. However, I don't want to proceed this way because I want to load manually the dlls required by using the LoadLibrary function (I don't want that these dlls are loaded automatically and dynamically at runtime because I want to control which dlls are used and I want to distribute and install them in a specific folder).

Is there any other way ? 

The MKL Advisor listed the following libraries:

  • mkl_intel_c_dll.lib
  • mkl_sequential_dll.lib
  • mkl_core_dll.lib

I already loaded manuyally the mkl_sequential.dll and mkl_core.dll dlls in my application. I did not use the mkl_intel_c.dll but it does not seem to be required. 

Best regards,

Phil.

Zhen_Z_Intel
Employee
144 Views

Dear customer,

Seems you are using windows ia32 platform. You probably need to load library file for interface layer, you could try to list all symbols in this dll to see, those symbols for vsl functions are defined in this dll. In cmd, >dumpbin /SYMBOLS mkl_intel_c_dll.lib > output.txt

Best regards,
Fiona

netphilou31
New Contributor II
144 Views

Dear Fiona,

I already get the dependencies of the redist dlls I need and I don't see any additionnal ones with the DUMPBIN command. Furthermore are you sure that the /SYMBOLS switch is the one to use? when I use it on my dll is does not show anything except the summary of the .data, .rdata, .reloc, .rsrc and .text sections. However if I use the /dependents or /imports switches the results are better even if I cannot see the vslxxxxx symbols.

Best regards,

Phil.

Zhen_Z_Intel
Employee
144 Views

Dear customer,

The option "/SYMBOLS" is intended to list all symbols in this lib file. The "/dependences" is used to find dll denpedency of dll file, not symbols for function usage. It's fine. I generate all symbol list of "mkl_intel_c_dll.lib" for you, you could find those symbols "_vslNewStream", "_vdRngUniform" and "_vslDeleteStream" in this file.

Please add to link mkl_intel_c_dll.lib (dynamic) or mkl_intel_c.lib (static) manually. Or I recommend to use MKL custom dll tools to help you generate your own custom dll. What you need to provide is just function list. Learn more info from https://software.intel.com/en-us/node/528362

Best regards,
Fiona

netphilou31
New Contributor II
144 Views

Dear Fiona,

Thanks for all. I already had some trouble due to runtime libraries needed and I was asked to use the MKL custom dll tool to generate the dll containing all the required functions but I did not find it really easy to use (probably because I didn't know exactly what I needed). I will try again to see if it can help.

Best regards,

Phil.

Reply