SOS! How to avoid to use mkl_vml_def.dll?

SOS! How to avoid to use mkl_vml_def.dll?

Hi,

The implementation in my COM dll calls Vml functions, IIS call my dll, when Iput mkl_vml_def.dll to the samefolder of IIS, the implementationruns well, but when Idelete themkl_vml_def.dll, the implementation will crash. On some PCs I have no right to add a file to the IIS folder System32, I have the right to put the dll to another disk except system disk.how can I solve this problem?Ilink withmkl_ia32.lib to replace mkl_vml_def.dllbut no use.

Best Reguards.

13 posts / 0 new
Last post
For more complete information about compiler optimizations, see our Optimization Notice.

As I wrote above, it`s prohibited to use statical MKL in your own DLL. It happen because we use TLS (thread local storage sections) for support of ThreadSafe feature in our library. These sections should be initialized in begining of application. Mechanish of inicialization is different for statical and dynamical libraries and then you link statical MKL to your own DLL your receive crash because TSL sections aren`t initialized.

Are your experements with PATH variable successful?

Andrey

You are using functionality from mkl_vml_def.dll. OS should load this DLL into memory. OS should to know where this DLL located. One of ways to tell OS where to find needed DLL is set PATH environment variable.

Andrey

Many manythanks,

but how to set PATH environment variable for this dll? which is the default variable for this dll? I use MKL_VML_X87dll but no use.

Can any way to staticlink with MKL library successfully? Sometimes it's very trouble to release my software with MKL dlls.

PATH variable is common variable that tells OS where to find executables (.exe, .dll and etc). You can set it manualy: right click on "my computer" -> properties -> advanced -> environment variables.

Yes, you can link MKL staticaly. For doing this you should use libraries without "_dll" suffix. For example: mkl_intel_c.lib mkl_intel_thread.lib mkl_core.lib libguide.lib.

Andrey

right click on "my computer" -> properties -> advanced -> environment variables.

Yes, I use this way, but failed, I don't know why? I set Variable name:MKL_VML_X87dll, Variable value:E:C0702TCom2out estmkl_vml_def.dll,which isthe real path of the mkl_vml_def.dll file. maybe the OS does not reconsize the Variable name:MKL_VML_X87dll?

For doing this you should use libraries without "_dll" suffix. For example: mkl_intel_c.lib mkl_intel_thread.lib mkl_core.lib libguide.lib.

Yes, I do this, when building there aremany warnings as below, and when running the implementation willthrow exception, I use MKL 9.1 version soI static link mkl_c.lib, libguide.lib & mkl_ia32.lib, my compiler is intel 9.1 version.

But when I link libguide40.lib, mkl_c_dll.lib and put libguide40.dll & mkl_vml_def.dll to the same folder of the executables file, the implemenattion runs well.

These are the warnings when link staticaly:

Make build directory
Creating library...
xilib: executing 'C:PROGRA~1MICROS~1VC98Binlib.exe'
mkl_ia32.lib(vsl_t7_wh_tables.obj) : warning LNK4006: __vsl_WH_A already defined in mkl_ia32.lib(vsl_v8_wh_tables.obj); second definition ignored
mkl_ia32.lib(vsl_t7_wh_tables.obj) : warning LNK4006: __vsl_WH_M already defined in mkl_ia32.lib(vsl_v8_wh_tables.obj); second definition ignored
mkl_ia32.lib(vsl_t7_wh_tables.obj) : warning LNK4006: __vsldWH_IM_Tab already defined in mkl_ia32.lib(vsl_v8_wh_tables.obj); second definition ignored
mkl_ia32.lib(vsl_t7_sobol_tables.obj) : warning LNK4006: _uSobolMInit already defined in mkl_ia32.lib(vsl_v8_sobol_tables.obj); second definition ignored
mkl_ia32.lib(vsl_t7_sobol_tables.obj) : warning LNK4006: _uSobolIrredPoly already defined in mkl_ia32.lib(vsl_v8_sobol_tables.obj); second definition ignored
mkl_ia32.lib(vsl_t7_sobol_tables.obj) : warning LNK4006: _iSobolIrredPolyDeg already defined in mkl_ia32.lib(vsl_v8_sobol_tables.obj); second definition ignored
mkl_ia32.lib(vsl_t7_niederr_tables.obj) : warning LNK4006: _uNiederrIrredPoly already defined in mkl_ia32.lib(vsl_v8_niederr_tables.obj); second definition ignored
mkl_ia32.lib(vsl_t7_niederr_tables.obj) : warning LNK4006: _iNiederrIrredPolyDeg already defined in mkl_ia32.lib(vsl_v8_niederr_tables.obj); second definition ignored
mkl_ia32.lib(vsl_t7_mt2203_table.obj) : warning LNK4006: __vsl_mt2203_table already defined in mkl_ia32.lib(vsl_v8_mt2203_table.obj); second definition ignored
mkl_ia32.lib(vml_t7_strings.obj) : warning LNK4006: _mkl_vml_service_strlen1 already defined in mkl_ia32.lib(vml_v8_strings.obj); second definition ignored
mkl_ia32.lib(vml_t7_strings.obj) : warning LNK4006: _mkl_vml_service_strcat1 already defined in mkl_ia32.lib(vml_v8_strings.obj); second definition ignored
mkl_ia32.lib(vsl_w7_wh_tables.obj) : warning LNK4006: __vsl_WH_A already defined in mkl_ia32.lib(vsl_v8_wh_tables.obj); second definition ignored
mkl_ia32.lib(vsl_w7_wh_tables.obj) : warning LNK4006: __vsl_WH_M already defined in mkl_ia32.lib(vsl_v8_wh_tables.obj); second definition ignored
mkl_ia32.lib(vsl_w7_wh_tables.obj) : warning LNK4006: __vsldWH_IM_Tab already defined in mkl_ia32.lib(v
sl_v8_wh_tables.obj); second definition ignored
mkl_ia32.lib(vsl_w7_sobol_tables.obj) : warning LNK4006: _uSobolMInit already defined in mkl_ia32.lib(vsl_v8_sobol_tables.obj); second definition ignored
mkl_ia32.lib(vsl_w7_sobol_tables.obj) : warning LNK4006: _uSobolIrredPoly already defined in mkl_ia32.lib(vsl_v8_sobol_tables.obj); second definition ignored
mkl_ia32.lib(vsl_w7_sobol_tables.obj) : warning LNK4006: _iSobolIrredPolyDeg already defined in mkl_ia32.lib(vsl_v8_sobol_tables.obj); second definition ignored
mkl_ia32.lib(vsl_w7_niederr_tables.obj) : warning LNK4006: _uNiederrIrredPoly already defined in mkl_ia32.lib(vsl_v8_niederr_tables.obj); second definition ignored
mkl_ia32.lib(vsl_w7_niederr_tables.obj) : warning LNK4006: _iNiederrIrredPolyDeg already defined in mkl_ia32.lib(vsl_v8_niederr_tables.obj); second definition ignored
mkl_ia32.lib(vsl_w7_mt2203_table.obj) : warning LNK4006: __vsl_mt2203_table already defined in mkl_ia32.lib(vsl_v8_mt2203_table.obj); second definition ignored
mkl_ia32.lib(vml_w7_strings.obj) : warning LNK4006: _mkl_vml_service_strlen1 already defined in mkl_ia32.lib(vml_v8_strings.obj); second definition ignored
mkl_ia32.lib(vml_w7_strings.obj) : warning LNK4006: _mkl_vml_service_strcat1 already defined in mkl_ia32.lib(vml_v8_strings.obj); second definition ignored
mkl_ia32.lib(vsl_a6_wh_tables.obj) : warning LNK4006: __vsl_WH_A already defined in mkl_ia32.lib(vsl_v8_wh_tables.obj); second definition ignored
mkl_ia32.lib(vsl_a6_wh_tables.obj) : warning LNK4006: __vsl_WH_M already defined in mkl_ia32.lib(vsl_v8_wh_tables.obj); second definition ignored
mkl_ia32.lib(vsl_a6_wh_tables.obj) : warning LNK4006: __vsldWH_IM_Tab already defined in mkl_ia32.lib(vsl_v8_wh_tables.obj); second definition ignored
mkl_ia32.lib(vsl_a6_sobol_tables.obj) : warning LNK4006: _uSobolMInit already defined in mkl_ia32.lib(vsl_v8_sobol_tables.obj); second definition ignored
mkl_ia32.lib(vsl_a6_sobol_tables.obj) : warning LNK4006: _uSobolIrredPoly already defined in mkl_ia32.lib(vsl_v8_sobol_tables.obj); second definition ignored
mkl_ia32.lib(vsl_a6_sobol_tables.obj) : warning LNK4006: _iSobolIrredPolyDeg already defined in mkl_ia32.lib(vsl_v8_sobol_tables.obj); second definition ignored
mkl_ia32.lib(vsl_a6_niederr_tables.obj) : warning LNK4006: _uNiederrIrredPoly already defined in mkl_ia32.lib(vsl_v8_niederr_tables.obj); second definition ignored
mkl_ia32.lib(vsl_a6_niederr_tables.obj) : warning LNK4006: _iNiederrIrredPolyDeg already defined in mkl_ia32.lib(vsl_v8_niederr_tables.obj); second definition ignored
mkl_ia32.lib(vsl_a6_mt2203_table.obj) : warning LNK4006: __vsl_mt2203_table already defined in mkl_ia32.lib(vsl_v8_mt2203_table.obj); second definition ignored
mkl_ia32.lib(vml_a6_strings.obj) : warning LNK4006: _mkl_vml_service_strlen1 already defined in mkl_ia32.lib(vml_v8_strings.obj); second definition ignored
mkl_ia32.lib(vml_a6_strings.obj) : warning LNK4006: _mkl_vml_service_strcat1 already defined in mkl_ia32.lib(vml_v8_strings.obj); second definition ignored
mkl_ia32.lib(vsl_px_wh_tables.obj) : warning LNK4006: __vsl_WH_A already defined in mkl_ia32.lib(vsl_v8_wh_tables.obj); second definition ignored
mkl_ia32.lib(vsl_px_wh_tables.obj) : warning LNK4006: __vsl_WH_M already defined in mkl_ia32.lib(vsl_v8_wh_tables.obj); second definition ignored
mkl_ia32.lib(vsl_px_wh_tables.obj) : warning LNK4006: __vsldWH_IM_Tab already defined in mkl_ia32.l
ib(vsl_v8_wh_tables.obj); second definition ignored
mkl_ia32.lib(vsl_px_sobol_tables.obj) : warning LNK4006: _uSobolMInit already defined in mkl_ia32.lib(vsl_v8_sobol_tables.obj); second definition ignored
mkl_ia32.lib(vsl_px_sobol_tables.obj) : warning LNK4006: _uSobolIrredPoly already defined in mkl_ia32.lib(vsl_v8_sobol_tables.obj); second definition ignored
mkl_ia32.lib(vsl_px_sobol_tables.obj) : warning LNK4006: _iSobolIrredPolyDeg already defined in mkl_ia32.lib(vsl_v8_sobol_tables.obj); second definition ignored
mkl_ia32.lib(vsl_px_niederr_tables.obj) : warning LNK4006: _uNiederrIrredPoly already defined in mkl_ia32.lib(vsl_v8_niederr_tables.obj); second definition ignored
mkl_ia32.lib(vsl_px_niederr_tables.obj) : warning LNK4006: _iNiederrIrredPolyDeg already defined in mkl_ia32.lib(vsl_v8_niederr_tables.obj); second definition ignored
mkl_ia32.lib(vsl_px_mt2203_table.obj) : warning LNK4006: __vsl_mt2203_table already defined in mkl_ia32.lib(vsl_v8_mt2203_table.obj); second definition ignored
mkl_ia32.lib(vml_px_strings.obj) : warning LNK4006: _mkl_vml_service_strlen1 already defined in mkl_ia32.lib(vml_v8_strings.obj); second definition ignored
mkl_ia32.lib(vml_px_strings.obj) : warning LNK4006: _mkl_vml_service_strcat1 already defined in mkl_ia32.lib(vml_v8_strings.obj); second definition ignored

PATH - it`s the name of environment variable. For your case set value of it to: "E:C0702TCom2;%PATH%" (without quotes) in "users variables" section.

My apologizes for my second proposal about statical usage of MKL. It`s prohibited to use statical MKL in your own DLLs.

Andrey

When I link MKL 10.0staticaly.I linkmkl_intel_c.lib mkl_intel_thread.lib mkl_core.lib libguide.lib., but there are many warnings as 9.1 version & the implementationcan not run, but when I link with libguide40.lib,mkl_intel_c_dll.lib,mkl_intel_thread_dll.lib & mkl_core_dll.lib and put the corresponding dll files to the same folder the implementation runs well, why?

Many many thanks,

But how I initialize the TSL sections?

PATH variable has been successful when other client call the dll, but for IIS it's still fail.

In current versions of MKL you can`t initialize TLS sections for MKL by yourself.

After you cahnge any environment variable you should restart applications if you want to these applications are affected by your changes. Did you restart IIS after PATH variable was modified?

Andrey

Yes, I restart IIS when I change the PATH variable every time.

Thank you!

Hmm. It`s strange situation.

Try to set PATH variable in the "system variables" section instead "user variables" section. Just add "E:C0702TCom2;" (without quotes) to the begining of the line.

How you restrt IIS? Maybe you need to reboot OS?

Andrey

I use the same settings but yesterday other client succeeded, IIS failed, today all succeed. so it's very strange. yesterday & today I all use IISreset to restart IIS.

Many many thanks again!!!

Leave a Comment

Please sign in to add a comment. Not a member? Join today