There are two different Fortran compilers on the cluster: one is gfortran
which is part of the Gnu Compiler Collection (GCC) and the other is the Intel Fortran Compiler.
There are other tools available for software development that are not listed on this page. For example, Totalview can be used for parallel debugging. Various Intel tools are available for performance measurement and optimization.
GCC Fortran compiler (gfortran)
The GNU Compiler Collection (GCC), which also contains the Fortran compiler gfortran
, is installed in multiple versions. We recommend using the version 9.3.0 which is installed as part of OpenHPC, however the version 8.3.1 is also available as part of the operating system. The former is part of the gnu9
module which is loaded by default. Its documentation is here. Other versions may be available and can be displayed with module avail
and module spider gnu
.
The command to call the Fortran compiler is gfortran
.
In addition to the compiler, GCC also encompasses the Gnu Debugger (gdb) which is installed in the version 8.2.12 and can debug Fortran. The command for the debugger it is gdb
.
Here is an example of the GCC module being loaded and the C compiler version being queried:
$ module load gnu9
$ gfortran --version
GNU Fortran (GCC) 9.3.0
Copyright (C) 2019 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
Intel Fortran compiler
The software suite Intel Parallel Studio is installed on the cluster, it includes the Intel compiler version 19.1.3. Additionally, the older version 19.0.5 is installed. The intalled versions can be displayed with module spider intel
.
The command for calling the Fortran compiler is ifort
. Here is an example of the Intel module being loaded and the Fortran compiler version being queried:
$ module load intel
$ ifort --version
ifort (IFORT) 19.1.3.304 20200925
Copyright (C) 1985-2020 Intel Corporation. All rights reserved.
In this example, the module was loaded without specifying a version. In that case, the default setting for the module is used (it is marked with (D)
on a module avail
).