Intel® Fortran Compiler and Intel® Fortran Compiler Classic Release Notes

ID 标签 766921
已更新 12/21/2023
版本 2024.0.2
公共

author-image

作者

The Intel® HPC Toolkit package provides two Fortran compilers:

  • The Intel® Fortran Compiler (ifx) has all of the Fortran language features of ifort, plus the added functionality of OpenMP* directives to offload to Intel GPUs. The OpenMP 5.0, 5.1, 5.2 and 6.0 target features for Intel GPU in ifx are not available in ifort. 
  • The Intel® Fortran Compiler Classic (ifort) uses our legacy Intel compiler technology and is provided to support users making the transition to the Intel® Fortran Compiler (ifx). This compiler is provided along with ifx during this transition period. Also, Intel Fortran Compiler Classic provides the ability to create binaries for Windows 32bit libraries and applications (ifx creates 64bit binaries only).

The Intel Fortran Compiler (ifx) is our flagship Fortran compiler. The Intel Fortran Compiler (ifx) is based on the Intel Fortran Compiler Classic (ifort) frontend and runtime libraries, but uses modern LLVM-based backend compiler technology. Thus, ifx gives you all the Fortran features you know and love in ifort, like legacy DEC extensions, superior Fortran Standards support, and powerful compiler directives. Everything you expect in Intel Fortran. But, in addition, ifx adds new capabilities for Intel’s latest CPU and GPU products, including OpenMP TARGET and automatic DO CONCURRENT offload to Intel GPUs for additional accelerated performance.

Both compilers, ifort and ifx, fully support Fortran Standards through Fortran 2018 and now include select Fortran 2023 features. 

ifx and ifort are binary (.o/.obj) and module file (.mod) compatible. Binaries and libraries generated with ifort can be linked with binaries and libraries built with ifx, and .mod files generated with one compiler can be used by the other (64-bit targets only and not compiled with -ipo). Both compilers use the the same runtime libraries. Our users tell us that the performance of applications compiled with ifx is comparable to the same application compiled with ifort.

NOTE  Intel® Fortran Compiler Classic (ifort) is now deprecated and will be discontinued in late 2024. Intel recommends that customers transition now to using the LLVM-based Intel® Fortran Compiler (ifx) for continued Windows* and Linux* support, new language support, new language features, and optimizations. For more information on ifx, see the Intel® Fortran Compiler Developer Guide and Reference and the Porting Guide for ifort Users to ifx.

NOTE macOS support is removed for Intel® Fortran Compiler Classic (ifort) in the 2024.0 release. 

Where to Find the Release

Please follow the steps to download the Intel® HPC Toolkit and follow the installation instructions.  It is recommended to install the Intel® oneAPI Base Toolkit first for full functionality. The Fortran compilers alone can be downloaded from the Standalone Components page.

Change History

This section highlights important changes from the previous product version and changes in minor releases.

New in Intel® Fortran Compiler 2024.0.2 Release

Intel Fortran Compiler 2024.0.2

  • Bug fixes
  • Includes the bug fixes that are part of Intel Fortran Compiler 2024.0.1

Intel Fortran Compiler Classic 2021.11.1

  • A deprecation message is added to the ifort command.

New in Intel® Fortran Compiler 2024.0.1 Release

Intel Fortran Compiler 2024.0.1

  • The OpenMP* runtime library is updated to support Intel® Core™ Ultra devices.
  • With these Fortran compiler packages the memory sanitizer now works as expected with -check uninit on Linux, as well as, other supported LLVM sanitizer options.
    • Some users report incorrect output using -check uninit. See this Forum post for several workarounds.
  • LLVM tools have been added to the Fortran compiler packages to allow working with fat binary executable files.

Intel Fortran Compiler Classic 2021.11.1

  • A deprecation message is added to the ifort command.

New in Intel® Fortran Compiler and Intel® Fortran Compiler Classic, 2024.0.0 Release

Intel Fortran Compiler 2024.0.0

  • Intel Fortran Compiler significantly improves productivity by adding popular LLVM sanitizers allowing developers to catch Fortran, OpenMP*, OpenMP offload address, memory leak, uninitialized memory, thread data races, deadlocks and undefined behavior on CPU.
  • Intel® Fortran Compiler adds initial Fortran 2023 standards support and enhances OpenMP 5.0, 5.1,and 5.2 and implements initial 6.0 standards compliance.
  • Corrections to reported problems.
  • Updated to include recent versions of 3rd party components, which include functional and security updates.

Intel Fortran Compiler Classic 2021.11.0

  • Corrections to reported problems.
  • Updated to include recent versions of 3rd party components, which include functional and security updates.

System Requirements

For complete system requirements please see Intel® Fortran Compiler System Requirements.

Directory Layout Change

Directory layout is improved across all products to streamline installation and setup.

The Unified Directory Layout is implemented in 2024.0. If you have multiple toolkit versions installed, the Unified layout ensures that your development environment contains the correct component versions for each installed version of the toolkit. The directory layout used before 2024.0, the Component Directory Layout, is still supported on new and existing installations.

For detailed information about the Unified layout, including how to initialize the environment and advantages with the Unified layout, refer to Use the setvars and oneapi-vars Scripts with Linux and Use the setvars and oneapi-vars Scripts with Windows.

New and Changed Compiler Features

More What's New

  • Intel Fortran Compiler (ifx) is the default Fortran compiler when using Microsoft* Visual Studio on Windows.

ifx 2024.0.0 and ifort 2021.11.0

Initial Fortran 2023 Features

  • The REDUCE locality spec on DO CONCURRENT
  • BOZ constants on RHS of INTEGER and REAL assignment statements
  • BOZ constants as INTEGER and REAL values in PARAMETER statements
  • BOZ constants as INTEGER or REAL as array constructor values
  • BOZ constants as INTEGER values in ENUMERATION statements
  • Intrinsic trigonometric functions returning degrees ACOSD(X), ASIND(X), ATAND(X), ATAN2D(Y, X), COSD(X), SIND(X), and TAND(X)

New OpenMP Features

  • In ORDERED directives, clause DOACROSS replaces the DEPEND clause.
  • OpenMP 5.2 classifies some directives as PURE. Only PURE directives are allowed in Fortran PURE procedures. The compiler will issue a message if it detects a non-PURE directive in a PURE procedure. 

ifx 2024.0.0

New OpenMP Features

  • The MATCH clause is now permitted in the DECLARE VARIANT directive. (OpenMP 5.0)
  • The DESTROY clause of the DEPOBJ construct now requires a destroy-var modifier (OpenMP 5.1)
  • The STRICT modifier can now be specified for the GRAINSIZE and NUM_TASK clauses of the TASKLOOP directive. (OpenMP 5.1)
  • The optional ORDER clause modifiers REPRODUCIBLE and UNCONSTRAINED can be specified for the CONCURRENT argument to specify ordering of iterations of a loop. (OpenMP 5.2)
  • The ORDER clause may now be specified on the DISTRIBUTE construct. (OpenMP 5.1)
  • The GROUPPRIVATE directive specifies variables to be shared by the threads of a context group, but each context group has a private copy. (OpenMP 6.0)
  • You can now specify a DEVICE_TYPE clause on the DECLARE TARGET directive.  DEVICE_TYPE (HOST) compiles the body of the construct for host device only,DEVICE_TYPE(NOHOST) compiles the body for the target device, and DEVICE_TYPE(ANY) compiles the body for both host and target. (OpenMP 5.0).

New Compiler Options

  • -fopenmp-device-code-split (Linux) and /Qopenmp-device-code-split (Windows) enable parallel compilation of SPIR-V* kernels for OpenMP offload Ahead-Of-Time compilation. 
  • -fopenmp-max-parallel-link-jobs (Linux) and /Qopenmp-max-parallel-link-jobs (Windows) determine the maximum number of parallel actions to be performed during device linking steps, where applicable.
  • -fsanitize=address (Linux) and /fsanitize:address (Windows) enable the LLVM Memory Sanitizer (MSAM) memory error detector. 
  • -fsanitize=threads enables LLVM Memory Sanitizer (MSAM) to detect data races in OpenMP and threaded code. Linux only.
  • -fprofile-ml-use enables the use of a pre-trained machine learning model to predict branch execution probabilities driving profile-guided optimizations. 
  • -mno-gather (Linux) and /Qgather- (Windows) disable the generation of gather instructions in auto-vectorization. 
  • -mno-scatter (Linux) and /Qscatter- (Windows) disable the generation of scatter instructions in auto-vectorization.  
  • -mauto-arch (Linux) and /Qauto-arch (Windows) tell the compiler to generate multiple, feature-specific auto-dispatch code paths for x86 architecture processors, if there is a performance benefit.  
  • -flink-huge-device-code tells the compiler to place device code later in the linked binary. This is to prevent 32-bit PC-relative relocations between surrounding Executable and Linkable Format (ELF) sections when the device code is larger than 2GB. Previous option -fsycl-link-huge-device-code is now deprecated and will be removed in a future release. 

New Device Hierarchy

Starting with Intel® oneAPI release 2024.0, a new device hierarchy model is introduced with the default mode that will expose each GPU tile of the Intel® Data Center GPU Max Series as independent GPU devices. This change is based on the work done by Intel and our customers to find optimal ways to reach high performance of GPUs with modern architecture. Refer to the GPU optimization guide and the article Options for using a GPU Tile Hierarchy for more details.

Additional Information

Read this supplemental article for more information about the implementation of Fortran and OpenMP standards in Intel Fortran Compiler (ifx).

Support Deprecated 

Intel® Fortran Compiler Classic (ifort) is now deprecated and will be discontinued in late 2024. Intel recommends that customers transition now to using the LLVM-based Intel® Fortran Compiler (ifx) for continued Windows* and Linux* support, new language support, new language features, and optimizations. For more information on ifx, see the Intel® Fortran Compiler Developer Guide and Reference and the Porting Guide for ifort Users to ifx.

Intel Fortran Compiler (ifx)

  • -fsycl-link-huge-device-code is deprecated and may be removed in a future release.  Use -flink-huge-device-code instead.
  • -fopenmp is deprecated and may be removed in a future release.  Use -qopenmp or -fiopenmp instead.
  • The compiler option on Linux -mkl is deprecated and may be removed in a future release. Beginning in the 2021.4.0 release the replacement is -qmkl. This compiler option tells the compiler to link to necessary libraries in the Intel® oneAPI Math Kernel Library.

Intel Fortran Compiler Classic (ifort)

  • Directive SIMD (!dir$ SIMD) is deprecated and may be removed in a future release. In the source code users should replace the directive with the OpenMP SIMD directive !$omp simd and associated clauses. When using the OpenMP SIMD directive remember to add compiler option -qopenmp-simd or -qopenmp. When compiling with -O2, -qopenmp-simd is implied.
  • The compiler option on Linux -mkl is deprecated and may be removed in a future release. Beginning in the 2021.4.0 release the replacement is -qmkl. This compiler option tells the compiler to link to necessary libraries in the Intel® oneAPI Math Kernel Library.

Support Removed

Note that starting with release 2021.7, macOS* support is limited to Mac* computers with Intel® Processors.

macOS* support

macOS support is removed for Intel® Fortran Compiler Classic (ifort) in the 2024.0 release. 

Intel® C++ Compiler Classic (icc/icpc)

Intel® C++ Compiler Classic (icc/icpc) is removed in the 2024.0 release. Intel recommends that customers transition now to using the LLVM-based Intel® oneAPI DPC++/C++ Compiler (icx/icpx) for continued Windows* and Linux* support, new language support, new language features, and optimizations. For more information on icx/icpx, see the Intel® oneAPI DPC++/C++ Compiler Developer Guide and Reference and the Porting Guide for icc Users to dpcpp or icx.

Known Issues

Installation on Windows

There is a known issue integrating Intel software developer tools (Intel® oneAPI Base Toolkit, Intel® HPC Toolkit, or their component products) into Microsoft Visual Studio 2022 (17.7 or higher) on offline systems with the Windows Performance Toolkit (Win11SDK_WindowsPerformanceToolkit) installed. This results in an incomplete integration. To work around the issue, either enable an Internet connection during Intel developer tools installation or uninstall the Windows Performance Toolkit before installing Intel developer tools, after Intel developer tools are installed, reinstall the Windows Performance Toolkit.

Non-POSIX Shells

The environment start up scripts have been migrated to POSIX compliant scripts. For non-POSIX shells, such as csh, there is a workaround for command-line usage for the Component Directory Layout:

% bash -c 'source /opt/intel/oneapi/setvars.sh ; exec csh'

For the Unified Directory Layout use

% bash -c 'source <install-dir>/<toolkit-version>/oneapi-vars.sh ; exec csh'

ifx and ifort

These are applicable when using both the ifx and ifort compiler drivers.

Evaluating Compile Time Integer Expressions

  • Beginning with the Intel Fortran Compiler (ifx) version 2023.2.0 and the Intel Fortran Complier Classic (ifort) version 2021.10.0
    • When evaluating compile time integer expressions, in some cases where overflow occurred, ifort and ifx did not issue any warning. This has been fixed.
    • When evaluating compile time integer expressions, in some cases where overflow should occur, ifort and ifx would instead silently promote the values to INTEGER(8), yielding a correct numeric result ,but with a larger KIND type  parameter. This automatic promotion to a larger KIND has been partially removed; most expressions will now overflow. This can result in numeric differences, but an overflow warning will be issued. For backwards compatibility, automatic promotion to INTEGER(8) will still occur in the limited case where all values of the expression are integer literals with no explicit KIND parameters. A warning will be issued in that case, too.

COMMON Block

  • Beginning with the Intel Fortran Compiler (ifx) version 2023.2.0 and the Intel Fortran Complier Classic (ifort) version 2021.10.0,
    • Programs that declare a COMMON block, instead of individual COMMON block variables, in an OpenMP data sharing clause cause a runtime failure, i.e. segmentation fault or incorrect result. The workaround is to declare the individual COMMON block variables.

Module (.mod) Files

Beginning with the Intel Fortran Compiler (ifx) version 2023.1.0 and the Intel Fortran Complier Classic (ifort) version 2021.9.0 module (.mod) files are compatible only with those module files created with 

  • Intel® Fortran Compiler [ Composer | Professional ] Edition for Linux*, version 11.0,
  • Intel® Visual Fortran Compiler [ Composer | Professional ] Edition for Windows*, version 11.0, or
  • Intel® Fortran Compiler [ Composer | Professional ] Edition for Mac OS* X, version 11.0 and
  • newer.

The module files created by Intel Fortran compilers prior to version 11.0 are no longer compatible.

GDB* 10.0 and Earlier 

A change between oneAPI 2023.0 and oneAPI 2023.1 prevents GDB* 10.0 and earlier versions from properly debugging SYCL and OpenMP* CPU offload code produced by the Intel® C, C++, and Fortran compilers. These older versions of GDB are present on RedHat EL8, Ubuntu 20.04, and Rocky 8.

Workarounds

  1. Use the Intel® Distribution of GDB*.
  2. Download an open source version of GDB after version 10.0

Fortran Coarray Application Hang After Executing FAIL IMAGE

If you use a FAIL IMAGE statement to make an image fail, you should use a STAT= specifier or a STAT argument in all coarray operations that might encounter that failed image if the statement or operation permits, or you should specify either the assume failed_images or standard-semantics compiler option. If you do not use a STAT= specifier, a STAT argument, or specify one of the compiler options, those operations will not check for failed images. They may then try to coordinate with the failed image, waiting for a response from it. The response would never happen and so the application would hang.

The following example demonstrates using the STAT= specifier to prevent an application hang.

SUBROUTINE FAIL_AND_SYNC ( THIS_ONE )
   INTEGER THIS_ONE
   INTEGER MY_STAT
   IF (THIS_IMAGE() .EQ. THIS_ONE) THEN
       FAIL IMAGE
   END IF
   SYNC ALL (STAT=MY_STAT)      ! Would hang without STAT=
END SUBROUTINE FAIL_AND_SYNC

Using the Coarray Feature with Red Hat 8

Applications that use the coarray feature and are running on Red Hat 8.0 or later should have Intel MPI 2019 Update 7 or later installed.  With earlier versions of MPI, applications may not complete successfully and give little information about the failure.

ifort

These are applicable when using the ifort compiler driver.

Cross Compiling (compiling in 32-bit mode on a 64-bit machine running Microsoft Windows*)

If you are running

  • Microsoft Windows* and
  • cross compiling (compiling in 32-bit mode on a 64-bit machine) and
  • using Microsoft Visual Studio* 2019 and
  • handle exceptions, particularly floating point exceptions, in your code and
  • you see a SEGV exception when your program gets a floating point exception,

your program did not handle the exception as intended.

The solution is to add legacy_x86_flt_exceptions.lib to your link command.

ifx

These are applicable when using the ifx compiler driver.

-check uninit

With the LInux version of ifx 2024.0.x there is a known bug with the new LLVM Memory Sanitizer feature. This does not affect Windows users; this is a Linux only feature.  This compiler option reports invalid information. A fix is coming in the 2024.1.0 Release. -check uninit is embedded in -check all.

Workaround 1

Compile with -check nouninit.

Workaround 2

If compiling with -check all, replace it with -check all,nouninit.

Workaround 3

Unset the environment variable LIBRARY_PATH or remove this directory in LIBRARY_PATH <oneAPI root dir>/2024.0.0/compiler/2024.0/lib.

opt-reports

There is a known issue with using opt-reports with programs containing OpenMP loop constructs with "schedule(dynamic)", which may cause the compiler to emit an error. In this case, it is recommended that the user remove -qopt-report from their compilation.

Potential for Incorrect Results Using Certain OpenMP Offload Directives

There is potential for incorrect results using OpenMP pragmas to offload to Intel GPUs where a parallel loop nested inside a TEAM construct is using a variable in a REDUCTION clause and the TEAM construct does not have the same REDUCTION clause. To avoid incorrect results, compile with -mllvm -vpo-paropt-atomic-free-reduction-slm=true to disable global memory buffers.

Using -ipo and mixing ifx with ifort object files.

ifx is binary (.o/.obj) and module (.mod) file compatible; binaries and libraries generated with ifort can be linked with binaries and libraries built with ifx, and .mod files generated with one compiler can be used by the other (64-bit targets only). If you compile with -ipo though, the compatibility between ifort and ifx is broken. 

GPU Driver Hanging Issue

If you have applications with long-running GPU compute workloads in native environments, you must disable the hangcheck timeout period to avoid terminating workloads. See the Installation Guide for your OS for more information.

CMake Information

  • Starting from CMake 3.25, due to limitations in the way CMake tracks linker flags, a CMake project with mixed C/C++ and Fortran code where one of the compilers is LLVM-based (e.g. icx, ifx) and another is the classic version (e.g. icc, ifort) will result in invalid linking flags. As an example, CMake cannot build a project using "icx" as the C/C++ compiler and "ifort" as the Fortran compiler.
    • The workaround is to use only LLVM-based compilers when building mixed language applications. 
  • Starting from CMake 3.27, CMake support for Intel oneAPI DPC++/C++ Compiler and Intel® Fortran Compiler has been updated to use the compiler driver for linking instead of the linker. This change enables use cases for building SYCL applications and libraries and enables Interprocedural Optimization (IPO) on Windows*. 

Configure Script Reports: "linking to Fortran libraries from C fails"

Symptom

When compiling with ifx, a ./configure script generated by GNU Autconf reports an error message similar to:

    checking for Fortran 77 libraries of ifx...  -loopopt=0 -L/lib/../lib64 -L/lib/../lib64/ -L/usr/lib/../lib64 -L/usr/lib/../lib64/ -L/lib64 -L/lib/ -L/usr/lib64 -L/usr/lib -lifport -lifcoremt -limf -lsvml -lm -lipgo -lirc -lpthread -lirc_s -ldl
    configure: WARNING: FLIBS does not work
    checking for ifx flag to add single underscore to external names... none
    checking for dummy main to link with Fortran 77 libraries... unknown
    configure: error: in '/path/to/build/dir':
    configure: error: linking to Fortran libraries from C fails
    See `config.log' for more details
    make: *** [build/config.status] Error 1

Examining the config.log file shows that the error causing ./configure to exit was:

    ld: cannot find -loopopt=0

Problem 

In trying to determine libraries needed to link Fortran code with C or C++ code, GNU Autoconf 2.69 and earlier mistakenly interprets -loopopt=0 in -mllvm -loopopt=0 in verbose compiler output as a linker flag.  GNU Autoconf then adds -loopopt=0 to the FLIBS variable, which is passed to the linker.  The linker then looks for a non-existent library causing the test to fail.

Solution for Users Downloading Source Code

Please inform the maintainers of packages impacted by this error about the problem and refer them to this release note.  Projects vary in how they handle configure scripts, however, some general rules apply.  Users who need a solution before the package maintainer can respond can update the configure  script themselves.  Difficulty of updating depends on how the package is distributed.

To update, first, install GNU Autoconf-2.70 or newer, as described in Solution for Package Maintainers, below.

After installing the updated autoconf in the user's path, packages that distribute the configure.ac  file along with the configure  script can be updated simply by running:

    autoreconf -if

The resulting configure script should complete without the above error in FLIBS.

It is not uncommon for project maintainers to remove the configure.ac file from a source distribution in a tar or zip archive.  In that case, the user usually needs to download the project from its code repository, and build according to the project's instructions.  Sometimes a version of the configure script is committed to version control and not automatically regenerated.  In that case, either running autoreconf -if as described above, or deleting the configure script often trigger it to be regenerated.  Ideally, documentation for the project will describe how to rebuild the configure script.

Solution for Package Maintainers

To prevent users seeing errors, update to GNU Autoconf to version 2.70 or later and re-generate the project configure  script.  GNU Autoconf-2.70 was released December 8, 2020.  Source code is available via git clone http://git.sv.gnu.org/r/autoconf.git.  GNU Autoconf documentation is available through GNU Autoconf Project Page.

How To Install the Intel® Fortran Compiler

The installation guides for the Intel® oneAPI Toolkits are available online. Please check the Intel® oneAPI Toolkits Installation Guide for more information.

How To Use the Intel® Fortran Compiler

Refer to

for details on how to use the Intel® Fortran Compiler for oneAPI.

Documentation

Product documentation is available online

Technical Support

If you have Commercial Support, create a support ticket. Otherwise, access the Intel® Fortran Compiler forum when you need assistance. 

Intel Fortran Compiler Release Notes for Previous Major Releases

 

Notices and Disclaimers

Intel technologies may require enabled hardware, software or service activation.

Intel optimizations, for Intel compilers or other products, may not optimize to the same degree for non-Intel products.

No product or component can be absolutely secure.

Your costs and results may vary.

© Intel Corporation. Intel, the Intel logo, and other Intel marks are trademarks of Intel Corporation or its subsidiaries. Other names and brands may be claimed as the property of others.

No license (express or implied, by estoppel or otherwise) to any intellectual property rights is granted by this document.

The products described may contain design defects or errors known as errata which may cause the product to deviate from published specifications. Current characterized errata are available on request.

Intel disclaims all express and implied warranties, including without limitation, the implied warranties of merchantability, fitness for a particular purpose, and non-infringement, as well as any warranty arising from course of performance, course of dealing, or usage in trade.