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

IMSL and MKL selection from compiler directives

elquin
Beginner
1,159 Views

I'm using Intel Visual Fortran v.11.1.065 under Windows 7 64 bit. 
What I want to make is related with compiler directives, especially for math library.
Here's my idea :

1. There exist two kinds of debug configuration, for IMSL and MKL. 
Thus command line arguments contains library-specific environment variables.
2. In code, compiler directive determine which math library is selected.
Then, library-specific functions can also be selected in code.

However, I don't know how to set the compiler directives for determining libraries.

Thanks, 
HK

0 Kudos
4 Replies
Steven_L_Intel1
Employee
1,159 Views

For IMSL, a set of INCLUDE files is provided that have the appropriate !DIR$ OBJCOMMENT directives - you need several. While nothing similar exists for MKL you can certainly add your own OBJCOMMENT directives for the set of MKL libraries you need.

0 Kudos
elquin
Beginner
1,159 Views

Thank you, Mr. Lionel.

However, what I really want to know is how to make the code know which math library will be used in debugging.

After that, the compiler directives like !DIR$ OBJCOMMENT will be used in the code.

HK

0 Kudos
elquin
Beginner
1,159 Views

Thank you, Mr. Lionel.
However, what I really want to know is how to make the code know which math library will be used in debugging.
After that, the compiler directives like !DIR$ OBJCOMMENT will be used in the code.

HK

Steve Lionel (Intel) wrote:

For IMSL, a set of INCLUDE files is provided that have the appropriate !DIR$ OBJCOMMENT directives - you need several. While nothing similar exists for MKL you can certainly add your own OBJCOMMENT directives for the set of MKL libraries you need.

0 Kudos
Steven_L_Intel1
Employee
1,159 Views

I guess I didn't fully understand your question. There are not debug versions of IMSL and MKL. What do you want to be different in a debug configuration?

0 Kudos
Reply