GNU Compiler

From HPC users
Jump to navigationJump to search

The GNU Compilers are available as module and as part of the operating system. The compiler of the operating system is GNU 4.4.7. To see the other available versions of the GNU Compilers type

 module av gcc

which currently shows

 -------------------- /cm/shared/uniol/modulefiles/COMPILER ---------------------
 gcc/4.8.1

To load the module of your choice type e.g.

 module load gcc/4.8.1

The commands for the available languages are

Name Description
gcc C compiler
g++ C++ compiler
gfortran Fortran compiler


Advantages

  • high availability, open source (free)
  • new standards implemented
  • fast compilation
  • performance of resulting C++ usually good
  • most open source software tested with GNU


Disadvantages

  • optimization of code is moderate: performance of C, Fortran code can be moderate