There are two different compilers for C and C++ programs on the cluster: the Gnu Compiler Collection (GCC) and the Intel Compiler.
A good starting point for beginning C developers is the tutorial series at cprogramming.com.
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.
The GNU compiler collection (GCC), which also contains C and C++ compilers, 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. The documentation for GNU 9.3.0 can be found here. Other versions may be available and can be displayed with
module avail and
module spider gnu.
The command to call the C compiler is
gcc, the one for C++ is
In addition to the compiler, GCC also encompasses the Gnu Debugger (gdb) which is installed in the version 8.2.12. The command for the debugger is
Here is an example of the GCC module being loaded and the C compiler version being queried:
$ module load gnu9 $ gcc --version gcc (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 Parallel Studio
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 installed versions can be displayed with
module spider intel.
The command for calling the compiler is
icc for the C compiler and
icpc for the C++ compiler. Here is an example of the Intel module being loaded and the C compiler version being queried:
$ module load intel $ icc --version icc (ICC) 220.127.116.114 20200925 Copyright (C) 1985-2020 Intel Corporation. All rights reserved.
In this example the module was loaded without specifying the compiler version. In that case the default setting for this module is used (it is marked with
(D) when doing a
Intel oneAPI Toolkit
The releases 2022.2.0 und 2023.1 are installed.
$ module avail oneapi ------------------------- /cm/shared/omni/modulefiles -------------------------- oneapi/2022.2.0 oneapi/2023.1 (L,D)
The command to call the compiler is
$ module load oneapi $ icx --version Intel(R) oneAPI DPC++/C++ Compiler 2023.1.0 (2023.1.0.20230320) Target: x86_64-unknown-linux-gnu Thread model: posix InstalledDir: /cm/shared/omni/apps/oneapi/2023.1/compiler/2023.1.0/linux/bin-llvm Configuration file: /cm/shared/omni/apps/oneapi/2023.1/compiler/2023.1.0/linux/bin-llvm/../bin/icx.cfg