HPL

Building HPL with Arm Compiler


Overview Before you begin Procedure Related information

Overview

How to build HPL with Arm Compiler for HPC.

HPL is a software package that solves a random, dense linear system in double precision (64 bit) arithmetic on distributed-memory computers. It can be regarded as a portable and freely available implementation of the High Performance Computing LINPACK Benchmark.

The following components are used in this build:

 Component Form
 HPL  Version 2.3
 Arm Compiler for HPC
 Version 19.1
 Arm Performance Libraries
 Version 19.1
 Open MPI
 4.0.0
 Linux distribution
 Ubuntu 16.04
 Hardware
 Cavium ThunderX2

Recipes for other versions of the application are available in the GitLab Packages Wiki.

Before you begin

  • Install Arm Compiler and Arm Performance Libraries. See the install instructions on the Installation page.
  • Set $ARMPL_DIR to your Arm Performance Libraries installation location.

Procedure

  1. Download the HPL source from Netlib, unpack the tarball, and change into the unpacked hpl-2.3 directory:

    wget http://www.netlib.org/benchmark/hpl/hpl-2.3.tar.gz
    tar -zxvf hpl-2.3.tar.gz
    cd hpl-2.3
  2. The setup directory contains a number of config files. To build with the Arm Compiler you must generate an Arm config file. In the setup directory, use the make_generic script to generate a new config for an 'unknown' architecture, Make.UNKNOWN, then rename this to Make.Linux_Arm:

    cd setup
    source make_generic
    mv Make.UNKNOWN Make.Linux_Arm
  3. Make the following changes to Make.Linux_Arm:

    • Set the name for the architecture: ARCH = Linux_Arm.
    • Set  TOPdir to the HPL directory, for example: TOPdir = $(HOME)/hpl-2.3.
    • Unset the LA flags, LAdir, LAinc and LAlib - linking to the Arm Performance Libraries will be handled by the -armpl flag.
    • Ensure that CC = mpicc, LINKER = mpifort, and mpicc -show and mpifort -show show armclang and armflang are being invoked.
    • Set the linker flags: LINKFLAGS = -mcpu=native -armpl.
    • Set optimization flags: CCFLAGS = $(HPL_DEFS) -Ofast -mcpu=native -armpl.
  4. Move to the HPL directory and make a link to, or copy of, setup/Make.Linux_Arm:

    cd ..
    ln -s setup/Make.Linux_Arm Make.Linux_Arm 
  5. Run make, selecting arch=Linux_Arm:

    make arch=Linux_Arm
  6. Run a test.

    To run HPL over $np cores, change to the directory containing the new Linux_Arm executable, and run xhpl:

    cd bin/Linux_Arm
    mpirun -np $np ./xhpl