GROMACS version: 2021+
GROMACS modification: No
Compiler version:
$ icpc --version
icpc (ICC) 19.1.3.304 20200925
Copyright (C) 1985-2020 Intel Corporation. All rights reserved.
Build steps:
$ cmake -DCMAKE_C_COMPILER=icc -DCMAKE_CXX_COMPILER=icpc \
-DCMAKE_INSTALL_PREFIX=/usr/local -DGMX_FFT_LIBRARY=mkl \
-DGMX_MPI=OFF -DGMX_THREAD_MPI=ON -DGMX_GPU=CUDA \
-DGMX_HWLOC=ON -DCMAKE_VERBOSE_MAKEFILE=ON -DCUDA_VERBOSE_BUILD=ON ../
$ cmake --build .
When trying to compile src/gromacs/applied_forces/awh/biasstate.cpp
the following error occurs:
In file included from /usr/local/src/gromacs-2021/src/gromacs/applied_forces/awh/biasgrid.h(61),
from /usr/local/src/gromacs-2021/src/gromacs/applied_forces/awh/bias.h(62),
from /usr/local/src/gromacs-2021/src/gromacs/applied_forces/awh/awh.cpp(78):
/usr/local/src/gromacs-2021/src/gromacs/applied_forces/awh/dimparams.h(114): error: no instance of constructor "gmx::DimParams::DimParams" matches the argument list
argument types are: (double, gmx::DimParams::PullDimParams)
return DimParams(conversionFactor, pullDimParams);
^
/usr/local/src/gromacs-2021/src/gromacs/applied_forces/awh/dimparams.h(72): note: this candidate was rejected because mismatch in count of arguments
struct DimParams
^
/usr/local/src/gromacs-2021/src/gromacs/applied_forces/awh/dimparams.h(72): note: this candidate was rejected because mismatch in count of arguments
struct DimParams
^
/usr/local/src/gromacs-2021/src/gromacs/applied_forces/awh/dimparams.h(95): note: this candidate was rejected because arguments do not match
DimParams(double conversionFactor, std::variant<PullDimParams, FepDimParams> dimParams) :
gcc and clang both compile this fine as does icc 2021.1+ . So it seems likely that this is a bug with intel compiler 19.1. Minimal-ish example to reproduce the issue with awh/dimparams.h with icc 19.1
Just thought I’d report this here incase it helps anyone else stumbling across the same problem in future.