lattice-benchmarks/Grid
2023-01-25 17:40:48 +00:00
..
systems/tursa working scripts for Tursa 2023-01-24 18:17:43 +00:00
.clang-format renaming and formatting 2023-01-24 18:44:47 +00:00
Benchmark_comms_host_device.cpp renaming and formatting 2023-01-24 18:44:47 +00:00
Benchmark_dwf_fp32.cpp Initial commit 2023-01-13 19:00:20 +00:00
Benchmark_Grid.cpp renaming and formatting 2023-01-24 18:44:47 +00:00
Benchmark_IO.cpp Initial commit 2023-01-13 19:00:20 +00:00
Benchmark_IO.hpp Initial commit 2023-01-13 19:00:20 +00:00
bootstrap.sh Initial commit 2023-01-13 19:00:20 +00:00
build-benchmark.sh Grid benchmark build system fix 2023-01-24 20:08:40 +00:00
build-grid.sh Grid build script 2023-01-24 18:18:32 +00:00
configure.ac Grid benchmark build system fix 2023-01-24 20:08:40 +00:00
LICENSE Initial commit 2023-01-13 19:00:20 +00:00
Makefile.am Grid benchmark build system fix 2023-01-24 20:08:40 +00:00
Readme.md Readmes 2023-01-25 17:40:48 +00:00

Grid benchmarks

This folder contains benchmarks for the Grid library. The benchmarks can be summarised as follows

  • Benchmark_Grid: This benchmark measure floating point performances for various fermion matrices, as well as bandwidth measurement for different operations. Measurements are performed for a fixed range of problem sizes.

TL;DR

Build and install Grid, all dependencies, and the benchmark with

systems/<system>/bootstrap-env.sh <env_dir> # build dependencies, takes a long time
./build-grid.sh <env_dir> <config>          # build Grid
./build-benchmark.sh <env_dir> <config>     # build benchmarks

where <env_dir> is an arbitrary directory where every product will be stored, <system> is a sub-directory of systems containing system-specific scripts (an existing preset or your own), and finally <config> is the name of a build config in systems/<system>/grid-config.json. After a successful execution the benchmark binaries will be in <env_dir>/prefix/gridbench_<config>.

Environment setup

A complete runtime environnement can be deploy using scripts from this repository. System-specific scripts are in the systems directory.

You should first deploy the environment for the specific system you are using, for example

systems/tursa/bootstrap-env.sh ./env

will deploy the relevant environment for the Tursa supercomputer in ./env. This step might compile from source a large set of packages, and might take some time to complete.

After that, the environment directory (./env in the example above) will contain a env.sh file that need to be sourced to activate the environment

source ./env/env.sh

Additional scripts env-*.sh can be sourced after to activate more specific environments, this should be done after sourcing env.sh as above.

Building the benchmarks

The environnement directory contains a grid-config.json file specifying compilation flag configurations for Grid (please see Grid's repository for documentation). All entries have the form

{
  "name": "foo",          // name of the configuration
  "env-script": "bar.sh", // script to source before building 
                          // (path relative to the environment directory)
  "commit": "...",        // Grid commit to use 
                          // (anything that can be an argument of git checkout)
  "config-options": "..." // options to pass to the configure script,
  "env" : {               // environment variables
    "VAR": "value"        // export VAR="value" before building
  }
}

Grid can then be built with

./build-grid.sh <env_dir> <config>

where <env_dir> is the environment directory and <config> is the build config name in grid-config.json. Similarly, the benchmarks can then be built with

./build-grid <env_dir> <config>

Running the benchmarks

After building the benchmarks as above you can find the binaries in <env_dir>/prefix/gridbench_<config>.