Developer Guide for Intel® oneAPI Math Kernel Library for Linux*
Using the q mkl Compiler Options
The Intel® oneAPI DPC++/C++ Compiler, the Intel® Fortran Compiler Classic, and the Intel® Fortran Compiler support the following mkl compiler option variants so that you can easily link against the Intel® oneAPI Math Kernel Library (oneMKL) in your application:
-qmkl=parallel (-qmkl)
Links against the oneMKL Intel® (OpenMP) threading layer and the necessary libraries. The -qmkl=parallel option can be simplified to -qmkl .
-qmkl=parallel -qtbb (-qmkl -qtbb)
Links against the oneMKL Intel TBB threading layer and the necessary libraries. The -qtbb option is supported only by the Intel® oneAPI DPC++/C++ Compiler.
-qmkl=sequential
Links against the oneMKL sequential threading layer and the necessary libraries.
For each -qmkl compiler option variant on Intel 64–architecture systems, the compiler links your application against the LP64 interface except when you are using the C++ compiler icpx with the -fsycl option, which links against the ILP64 interface. To link against the ILP64 interface in other cases, use the -qmkl-ilp64 compiler option variants (see Using the -qmkl-ilp64 Compiler Option ).
On Linux* systems, the -qmkl compiler option must be specified both in the compilation and link lines. In addition, dynamic linking against oneMKL is the default for the -qmkl compiler option. If you want to link against oneMKL statically, you must additionally specify -static-intel .
For the complete compilation and link lines, use the oneMKL Link Line Advisor . For more information, see Linking in Detail .