Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.

Thread safe Fortran dll:s

Anna_B_1
Beginner
894 Views

Hi,

I have read the post by Martyn Corden: https://software.intel.com/en-us/articles/threading-fortran-applications-for-parallel-performance-on-multi-core-systems?language=es on thread safe Fortran.

There he writes that not all native Fortran libraries are thread safe, and that the thread safe library libifcoremt will be linked automatically when compiled with the /Qopenmp flag.

At my computer I do not have any libifcoremt.dll, only a .lib file.

I have three questions:

1. How may I distribute the thread safe version of libifcore into our installations? 

2. Are there more assemblies or libraries that are not thread safe?

3. Are the libifcoremt.lib and other thread safe libraries included in some assemblies that I may distribute?

 

Best regards, Anna

0 Kudos
3 Replies
mecej4
Honored Contributor III
894 Views

Libraries from Microsoft and Intel with names such as libxxyymt.lib are static, multi-threaded libraries. When you link to one or more of these libraries, the code sections from the library objects that are needed are linked into your EXE, which as a result can become quite big. There is no corresponding DLL, nor is one needed.

If you use libraries with names such as libxxyymd.lib, which are dynamic import libraries, the actual code is contained in companion DLLs.

0 Kudos
TimP
Honored Contributor III
894 Views

My understanding is all recent Intel compilers and all currently supported visual studio versions provide thread safe libraries so this no longer should be a concern. 

For linking a dll there is a small import lib but this question is distinct from thread safety.

As mecej4 hinted, the lib names with md and mt assert thread safety.

 

 

0 Kudos
Steven_L_Intel1
Employee
894 Views

We provide a installer for the compiler redistributables in both executable form and in "merge module" form for installers. See here. The merge modules are in the "redist" folder under your installation of Intel Visual Fortran.

0 Kudos
Reply