Automatic use of Vectorized Math Library routines (VML) possible?

Automatic use of Vectorized Math Library routines (VML) possible?

We have users migrating from IBM System to Intel based systems.  A user was asking about Vectorized versions of the library that has the same functionality as MASS from IBM:

Based on the link above, VML in the MKL library seems to have the same functionality, but looking at the documentation a few things were not clear.

Does the compiler automatically take advantage of the Vectorized versions of these functions?  Is there a specific level of options or list of options that would enable this?

The documentation refers to HA, LA, and EP versions of these libraries, but it's not clear how to select the performance/precision combination:

It's possible I am not hitting the right links from my searches, can you please let me know if it is possible to automatically use the Vectorized versions of these functions?  If yes, how do you choose the different accuracy versions available?  I assume programming language is not an issue, but in case it is, here I am interested in FORTRAN.



3 Beiträge / 0 neu
Letzter Beitrag
Nähere Informationen zur Compiler-Optimierung finden Sie in unserem Optimierungshinweis.

The only method for implicit MKL calls is the one for matrix multiplication called opt-matmul in ifort.
IBM masslib appears more closely analogous to the svml library which comes with Intel compilers and is employed automatically for vectorization of math functions which aren't trivial to expand in line. There is also an svml option in gfortran.
As the name implies, svml is somewhat analogous to vml but implements "short vector" functions (number of operands correspond to simd register width). The compiler takes care automatically of splitting a vector into short vectors.
svml doesn't implement the same 3 levels of accuracy for each function and precision as vml. There are separate versions for each simd architecture, where appropriate, plus an "arch-consistency" version (much improved in the 13.0 release) which has just one code path regardless of which Intel or AMD simd platform is detected. There are also "imf-accuracy" options which you can read about in the Intel compiler documentation but I don't expect them to affect implicit svml calls.

The VML component of Intel MKL is a collection of math functions that take inputs vectors (arrays) of values and produce results in vectors. Users need to call these functions explicitly in their code. Intel compilers do not generate code to automatically use these functions. Please do not confuse VML with SVML. The latter is a feature of Intel compilers and may be more similar to IBM masslib.

If you want to know more about how to use the VML in MKL, please check out It should also answers your questions about balancing accuracy and performance.

Kommentar hinterlassen

Bitte anmelden, um einen Kommentar hinzuzufügen. Sie sind noch nicht Mitglied? Jetzt teilnehmen