Benchmark LAMMPS

Posted on Thu 28 December 2023 by Pavlo Khmel

LAMMPS is a classical molecular dynamics code with a focus on materials modeling.

I'm using a module from EasyBuild for compilers.

Or build with GCC compiler (OpenMPI)

module purge
module load foss/2023a
module load CMake/3.26.3-GCCcore-12.3.0

Or build with Intel compiler (IntelMPI)

module purge
module load intel/2022a
module load CMake/3.23.1-GCCcore-11.3.0

Build

curl -O https://download.lammps.org/tars/lammps-stable.tar.gz
tar -xzf lammps-stable.tar.gz
cd lammps-2Aug2023
mkdir build
cd build
cmake ../cmake -D PKG_DRUDE=yes -D PKG_EXTRA-COMPUTE=yes -D PKG_EXTRA-DUMP=yes -D PKG_EXTRA-FIX=yes -D PKG_FEP=yes -D PKG_KSPACE=yes -D PKG_MISC=yes -D PKG_MOLECULE=yes -D PKG_RIGID=yes -D PKG_INTEL=yes 
cmake --build . -j
cd ../..

Download benchmark job

curl -O http://www.phoronix-test-suite.com/benchmark-files/lammps-hecbiosim-1.tar.gz
tar -xzf lammps-hecbiosim-1.tar.gz 

Run locally on a single server (20 parallel processes)

cd lammps/20k-atoms/
mpirun -np 20 /lustre/lammps-2Aug2023/build/lmp -in benchmark.in
. . . 
Performance: 8.311 ns/day, 2.888 hours/ns, 48.097 timesteps/s, 942.945 katom-step/s

Run on multiple servers (OpenMPI)

mpirun -np 100 --host server01:20,server02:20,server03:20,server04:20,server05:20 /lustre/lammps-2Aug2023/build/lmp -in benchmark.in
. . .
Performance: 32.094 ns/day, 0.748 hours/ns, 185.726 timesteps/s, 3.641 Matom-step/s

Run on multiple servers (IntelMPI)

mpirun -np 100 --ppn 20 --host server01,server02,server03,server04,server05 /lustre/lammps-2Aug2023/build/lmp -in benchmark.in
. . .
Performance: 33.887 ns/day, 0.708 hours/ns, 196.106 timesteps/s, 3.845 Matom-step/s