GNU compilers¶
DelftBlue has multiple versions of GNU compilers installed.
GNU 8.5¶
By default, GNU 8.5 is available. This does not require loading any modules:
[<netid>@login02 ~]$ gcc --version
gcc (GCC) 8.5.0 20210514 (Red Hat 8.5.0-10)
Copyright (C) 2018 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.
[<netid>@login02 ~]$ gfortran --version
GNU Fortran (GCC) 8.5.0 20210514 (Red Hat 8.5.0-10)
Copyright (C) 2018 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.
GNU 11.2.0¶
GNU 11.2.0 is also available, in particular the g++ compiler may support more recent language features. Note that there is no compatible MPI module available so far, though. For a workaround, see the note on Intel MPI below.
This will bring you the following:
[<netid>@login02 ~]$ gcc --version
gcc (Spack GCC) 11.2.0
Copyright (C) 2021 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.
[<netid>@login02 ~]$ gfortran --version
GNU Fortran (Spack GCC) 11.2.0
Copyright (C) 2021 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.
MPI wrappers¶
GNU 8.5 with OpenMPI¶
If you want to use GNU 8.5 compilers with MPI, you have to load the openmpi
module:
This will enable the MPI wrappers:
[<netid>@login02 ~]$ mpirun --version
mpirun (Open MPI) 4.1.1
Report bugs to http://www.open-mpi.org/community/help/
[<netid>@login02 ~]$ mpicc --version
gcc (GCC) 8.5.0 20210514 (Red Hat 8.5.0-10)
Copyright (C) 2018 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.
[<netid>@login02 ~]$ mpif90 --version
GNU Fortran (GCC) 8.5.0 20210514 (Red Hat 8.5.0-10)
Copyright (C) 2018 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.
GNU 11 with Intel MPI¶
If you want to use GNU 11 with MPI, you can use the Intel MPI implementation, it provides suitable libraries and headers. Unfortunately, the versions supported don't match exactly, for instance, Intel MPI supports GCC 11.1, not 11.2. As a consequence, Fortran modules are not compatible with our gfortran compiler, so Intel MPI is not a solution for Fortran users who use MPI modules rather than the more old-fashioned C-like header 'mpif.h'.
For GNU 11, you have to load the following modules:
Then you will get:
[<netid>@login02 ~]$ mpicc --version
gcc (Spack GCC) 11.2.0
Copyright (C) 2021 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.
[<netid>@login02 ~]$ mpif90 --version
GNU Fortran (Spack GCC) 11.2.0
Copyright (C) 2021 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.