Overview of Free C++ and Fortran Compiler Families
These modern, currently-supported compiler families are free-to-use for C, C++ and Fortran.
Compiler | C | C++ | Fortran |
---|---|---|---|
GNU | gcc: C23 | g++: C++26 | gfortran: F2018 |
Intel oneAPI | icx: C23 | icpx: C++23 | ifx: F2023 |
LLVM | clang: C17 | clang++: C++26 | flang-new: F2018 |
AOCC | clang: C17 | clang++: C++17 | flang: F2008 |
NVIDIA HPC SDK | nvc: C11 | nvc++: C++23 | nvfortran: F2003 |
IBM OpenXL | xlc: C17 | xlc++: C++26 | xlf: F2018 |
GCC
GCC has broad support of modern standards on a very wide range of computing platforms. GCC is competitive in build time and runtime with vendor-specialized compilers. These may offer vendor-specific capabilities not available in general compilers like GCC.
Intel
Intel oneAPI compilers are free to use for any user, supporting Linux and Windows computers with x86-64 CPU including from AMD, Intel, etc. Intel oneAPI components like MKL, IPP, and TBB are available at no cost. Intel MPI Library implements the MPICH specification for massively parallel computation across discrete computing nodes.
LLVM
LLVM Clang C and C++ compilers join with the Flang Fortran compiler using modern C++ internals and robust industry support. LLVM is known for performance, correctness, and prompt implementation of new language standards. LLVM has powerful associated tooling like clang-format, clang-tidy, and sanitizers. It is generally important to ensure that a project builds with both LLVM and GCC for better portability.
AMD
AMD AOCC LLVM compiler is tuned for AMD CPUs. AOCC works on non-AMD CPUs but is generally only useful for those with HPC/AI workloads on AMD CPUs, as it typically uses LLVM releases that are a few versions behind the latest.
AMD GPUs are the focus of the ROCm software stack, which includes the HIP C++ language and ROCm Fortran compiler. Currently the ROCm Fortran Next Gen compiler is in early development and is intended for advanced users who need to use AMD GPUs with Fortran or C/C++ code.
NVIDIA
NVIDIA HPC SDK is free to use and works on a variety of desktop CPUs including x86-64, OpenPOWER, and ARM. A key feature of the NVIDIA compilers is intrinsic support for CUDA Fortran, enabling offloading computationally intensive Fortran code to NVIDIA GPUs. NVIDIA HPC SDK includes specialized tools for NVIDIA Nsight profiling, debugging, and optimizing HPC applications on NVIDIA platforms.
IBM OpenXL
Unlike the other compilers mentioned above, IBM OpenXL LLVM-based compilers are specifically designed for POWER CPUs, such as ppc64le. Consequently, IBM OpenXL compilers do not work with typical x86-based computers.
The IBM OpenXL Fortran compiler features extensive optimization capabilities specifically for POWER CPU architecture. It supports OpenMP for parallel processing and can auto-vectorize code for POWER vector units (VSX, VMX). The compiler includes built-in support for IBM MASS (Mathematical Acceleration Subsystem) libraries and optimization reports to help developers tune code performance. OpenXL compilers include hardware-specific optimizations for POWER CPUs and support for IBM-specific operating systems like AIX.