Intel® Fortran Compiler Classic and Intel® Fortran Compiler Developer Guide and Reference

ID 767251
Date 3/22/2024
Public

A newer version of this document is available. Customers should click here to go to the newest version.

Document Table of Contents

qopenmp-lib, Qopenmp-lib

Lets you specify an OpenMP* runtime library to use for linking. This feature is only available for ifort.

Syntax

Linux:

-qopenmp-lib=type

Windows:

/Qopenmp-lib:type

Arguments

type

Specifies the type of library to use; it implies compatibility levels. Currently, the only possible value is:

compat

Tells the compiler to use the compatibility OpenMP* runtime library (libiomp). This setting provides compatibility with object files created using Microsoft* and GNU* compilers.

Default

-qopenmp-lib=compat
or /Qopenmp-lib:compat

The compiler uses the compatibility OpenMP* runtime library (libiomp).

Description

This option lets you specify an OpenMP* runtime library to use for linking.

The compatibility OpenMP runtime libraries are compatible with object files created using the Microsoft* OpenMP runtime library (vcomp) or the GNU OpenMP runtime library (libgomp).

To use the compatibility OpenMP runtime library, compile and link your application using the compat setting for option [q or Q]openmp-lib. To use this option, you must also specify one of the following compiler options:

  • Linux* systems: -qopenmp or -qopenmp-stubs

  • Windows* systems: /Qopenmp or /Qopenmp-stubs

Linux

The compatibility Intel OpenMP* runtime library lets you combine OpenMP* object files compiled with the GNU* gcc or gfortran compilers with similar OpenMP* object files compiled with the Intel® C, Intel® C++, or Intel® Fortran Compiler. The linking phase results in a single, coherent copy of the runtime library.

This option is processed by the compiler driver command that initiates linking, adding library names explicitly to the link command.

You cannot link object files generated by the Intel® Fortran compiler to object files compiled by the GNU Fortran compiler, regardless of the presence or absence of the [Q]openmp compiler option. This is because the Fortran runtime libraries are incompatible.

Windows

The compatibility OpenMP* runtime library lets you combine OpenMP* object files compiled with the Microsoft* C/C++ compiler with OpenMP* object files compiled with the Intel® C, Intel® C++, or Intel® Fortran compilers. The linking phase results in a single, coherent copy of the runtime library.

This option is processed by the compiler, which adds directives to the compiled object file that are processed by the linker.

NOTE:
The compatibility OpenMP runtime library is not compatible with object files created using versions of the Intel compilers earlier than 10.0.

IDE Equivalent

None

Alternate Options

None

See Also