Install AMD AOCC C C++ Fortran compiler
The no-cost AMD AOCC compiler is tuned for AMD CPUs, akin to how Intel oneAPI is tuned for Intel CPUs. Install the “.rpm” file after downloading on a RHEL-based Linux like:
dnf install ./aocc-compiler*.x86_64.rpm
Create a source script “~/aocc.sh” like:
root=/opt/AMD/aocc-compiler-4.2.0/
[[ ! -d ${root} ]] && echo "ERROR: ${root} not found" && exit 1
source ${root}/setenv_AOCC.sh
export CC=clang CXX=clang++ FC=flang
export MPI_ROOT=
flang --version
To use the AOCC compiler:
source ~/aocc.sh