Peptide example fails with USER-INTEL package

Hello,

When I build LAMMPS with the USER-INTEL package I find that the peptide example in lammps-stable_7Aug2019/examples/peptide only runs for 152 steps before producing “Out of range atoms - cannot compute PPPM”.

This would seem to be a case where (mostly) single-precision calculations would be sufficient for solving for the dynamics. What am I missing?

Interestingly, the same build works for the pure water example (https://lammps.sandia.gov/bench/bench_spce.tar.gz). It gives the same average pressure as the double-precision build over 10k steps.

=== Build Procedure (serial and debug for testing) ===

LAMMPS: Stable version (7 Aug 2019)

OS: RHEL 7.7

CPU: Intel Broadwell

Compiler: Intel 19.0.5

module load intel intel-mkl

cmake3 -D ENABLE_TESTING=yes \

-D BUILD_MPI=no -D BUILD_OMP=no -D CMAKE_CXX_COMPILER=icpc \

-D CMAKE_BUILD_TYPE=Debug -D CMAKE_CXX_FLAGS_DEBUG="-g -O0" \

-D PKG_KSPACE=yes -D FFT=MKL -D FFT_SINGLE=yes \

-D PKG_MOLECULE=yes -D PKG_RIGID=yes \

-D PKG_USER-INTEL=yes -D INTEL_ARCH=cpu -D INTEL_LRT_MODE=threads …/cmake

make

make test # all tests pass

make install

Hello,

When I build LAMMPS with the USER-INTEL package I find that the peptide example in lammps-stable_7Aug2019/examples/peptide only runs for 152 steps before producing “Out of range atoms - cannot compute PPPM”.

This would seem to be a case where (mostly) single-precision calculations would be sufficient for solving for the dynamics. What am I missing?

The version 19 compilers from Intel have some known problems with certain optimization flags leading to miscompiled code. This has been addressed in the code and in the suggested compiler flags in the Makefiles for the conventional make build process, but it looks like it has not been addressed in CMake. There were also some bugfixes to USER-INTEL code since the 7Aug2019 release that may be relevant.

The way to make this work correctly would be to a) use the latest patch release (4 Feb 2020), and either b) switch to an older version of the intel compilers or c) make certain, that the -std=c++11 flag is set and the -fno-alias flag is not set (not sure how easy that will be with CMake, you may have to edit the cmake/Modules/Packages/USER-INTEL.cmake file).

I will make a check with CMake, when I get an opportunity and this will hopefully be addressed in the next release.

Axel.