Gromacs 2018.3 for LX with GPU support (gcc)
Webpage
Version
2018.3
Build Environment
- Intel Parallel Studio XE 2017 update 4 (to use Intel MPI)
- gcc 6.3.1 (devtoolset-6 Software Collections)
- cuda 9.1.85
- cmake 3.8.2
Files Required
- gromacs-2018.3.tar.gz
- (regressiontests-2018.3.tar.gz; testset)
Build Procedure
(Tests are performed after installation.)#!/bin/sh
VERSION=2018.3
INSTALL_PREFIX=/local/apl/lx/gromacs2018.3-gnu-CUDA
BASEDIR=/home/users/${USER}
GROMACS_TARBALL=${BASEDIR}/gromacs-${VERSION}.tar.gz
WORKDIR=/work/users/${USER}
PARALLEL=12
#---------------------------------------------------------------------
umask 0022
module purge
module load scl/devtoolset-6
module load intel_parallelstudio/2017update4
module load cuda/9.1
module load cmake/3.8.2
cd ${WORKDIR}
if [ -d gromacs-${VERSION} ]; then
mv gromacs-${VERSION} gromacs_erase
rm -rf gromacs_erase &
fi
tar xzf ${GROMACS_TARBALL}
cd gromacs-${VERSION}
# single precision, thread MPI
mkdir rccs-s
cd rccs-s
cmake .. \
-DCMAKE_INSTALL_PREFIX=${INSTALL_PREFIX} \
-DCMAKE_VERBOSE_MAKEFILE=ON \
-DGMX_MPI=OFF \
-DGMX_GPU=ON \
-DGMX_DOUBLE=OFF \
-DGMX_THREAD_MPI=ON \
-DGMX_BUILD_OWN_FFTW=ON \
-DREGRESSIONTEST_DOWNLOAD=OFF
make -j${PARALLEL} && make install
cd ..
# compiler setting for MPI versions
export CC=mpicc
export CXX=mpicxx
export F77=mpif90
export F90=mpif90
export FC=mpif90
# single precision, with MPI
mkdir rccs-mpi-s
cd rccs-mpi-s
cmake .. \
-DCMAKE_INSTALL_PREFIX=${INSTALL_PREFIX} \
-DCMAKE_VERBOSE_MAKEFILE=ON \
-DGMX_MPI=ON \
-DGMX_GPU=ON \
-DGMX_DOUBLE=OFF \
-DGMX_THREAD_MPI=OFF \
-DGMX_BUILD_OWN_FFTW=ON \
-DREGRESSIONTEST_DOWNLOAD=OFF
make -j${PARALLEL} && make install
cd ..
Job script to run tests (12 CPUs + 1 GPU)
#!/bin/sh
#PBS -l select=ncpus=12:mpiprocs=12:ompthreads=1:jobtype=gpu:ngpus=1
#PBS -l walltime=00:30:00if [ -d "${PBS_O_WORKDIR}" ]; then
cd ${PBS_O_WORKDIR}
fimodule purge
module load intel_parallelstudio/2017update4
module load scl/devtoolset-6
module load cuda/9.1GMXBASE=/local/apl/lx/gromacs2018.3-gnu-CUDA
REGRESSIONS=/work/users/${USER}/regressiontests-2018.3
MPIRUN=`which mpirun`cd $REGRESSIONS
. ${GMXBASE}/bin/GMXRC.bash# MPI test
PARALLEL="-np 12"
./gmxtest.pl ${PARALLEL} \
-ntomp 1 \
-mpirun ${MPIRUN} \
all# thread MPI test
PARALLEL="-nt 12"
./gmxtest.pl ${PARALLEL} \
-ntomp 1 \
all