alexxy/gromacs.git
3 years agoDisable FPE for SYCL builds
Andrey Alekseenko [Fri, 18 Dec 2020 13:39:51 +0000 (13:39 +0000)]
Disable FPE for SYCL builds

Intel Graphics Compiler triggers FPEs inside its JIT. We can more
selectively call gmx_fedisableexcept only iff we are running on
Intel's GPU, but, to me, a more predictable approach seems friendlier.

Also, refactored the two complex PP conditions into a separate function.
It's only called once at program launch, so function call overhead
should not be an issue.

3 years agoFix clang-tidy-11 for trajectoryanalysis
Paul Bauer [Mon, 8 Feb 2021 12:23:12 +0000 (12:23 +0000)]
Fix clang-tidy-11 for trajectoryanalysis

Make sure the module conforms to clang-tidy-11.

Refs #3897

3 years agoRemoved "math.h" included from clang-tidy
Paul Bauer [Mon, 8 Feb 2021 07:49:04 +0000 (08:49 +0100)]
Removed "math.h" included from clang-tidy

Version 11 seems to include those in the code without need.

3 years agoParametrize constraints test over the test systems
Artem Zhmurov [Mon, 8 Feb 2021 06:25:49 +0000 (06:25 +0000)]
Parametrize constraints test over the test systems

Use a pre-define set of constant test systems to prevent repetition of logic
in different tests when latter are instintiated.

3 years agoFix clang-tidy 11 warning in nbnxm ocl kernels
Szilárd Páll [Fri, 5 Feb 2021 22:00:07 +0000 (23:00 +0100)]
Fix clang-tidy 11 warning in nbnxm ocl kernels

3 years agoReplace custom implementations of GCD with std::gcd
Andrey Alekseenko [Fri, 5 Feb 2021 16:29:45 +0000 (19:29 +0300)]
Replace custom implementations of GCD with std::gcd

There is a minor implementation difference:
When any of the arguments is 0, old `lgc` functions return 1,
while std::gcd returns max of both arguments.

However, in the two cases changed here, the function is never
called with zeroes.

3 years agoAdd style code for function static variables
Mark Abraham [Sat, 6 Feb 2021 09:15:27 +0000 (09:15 +0000)]
Add style code for function static variables

These should be prefixed with `s_` just like class variables, because
the reason is the same: the reader knows immediately the scope and
lifetime.

3 years agoClean up domdec again after clang-tidy-11 fixes
Paul Bauer [Fri, 5 Feb 2021 15:37:11 +0000 (16:37 +0100)]
Clean up domdec again after clang-tidy-11 fixes

Previous fixes have been incomplete and introduced a bug.

3 years agoClang-tidy-11 fixes for utility
Paul Bauer [Fri, 5 Feb 2021 15:58:27 +0000 (15:58 +0000)]
Clang-tidy-11 fixes for utility

Fixes have been missing from previous fixes.

Refs #3897

3 years agoFix clang-tidy-11 for domdec and utility
Paul Bauer [Fri, 5 Feb 2021 13:01:43 +0000 (13:01 +0000)]
Fix clang-tidy-11 for domdec and utility

Part of updates needed to conform to clang-tidy-11. Split into several
commits as it is impossible to have all changes together.

Refs #3897

3 years agoUse raw strings instead of format in docker build script
Joe Jordan [Fri, 5 Feb 2021 12:21:29 +0000 (12:21 +0000)]
Use raw strings instead of format in docker build script

Removes all instances of .format() from strings in docker build
script in favor of the more modern raw strings.

3 years agoRemove VMX SIMD
Mark Abraham [Fri, 5 Feb 2021 10:06:20 +0000 (10:06 +0000)]
Remove VMX SIMD

This catered for POWER6 architectures, which are not used in HPC.

Part of #3891

3 years agoRemove support for ARMv7 and NEON
Mark Abraham [Tue, 2 Feb 2021 09:52:59 +0000 (10:52 +0100)]
Remove support for ARMv7 and NEON

Note that ARMv8 and NEON ASIMD are unaffected.

The implementation of the SIMD library for NEON ASIMD formerly
included content from that for NEON, and sometimes then overrode it
based on preprocessor defines. This has been consolidated manually so
that there is neither duplication nor additional preprocessing needed.

Part of #3891

3 years agoRemove no longer needed macro define
Paul Bauer [Wed, 3 Feb 2021 15:18:56 +0000 (16:18 +0100)]
Remove no longer needed macro define

The __STDC_LIMIT_MACROS and __STDC_FORMAT_MACROS definitions
should no longer be necessary.

3 years agoMake LJ combination rule enum into an enum class
Artem Zhmurov [Thu, 4 Feb 2021 09:56:25 +0000 (09:56 +0000)]
Make LJ combination rule enum into an enum class

To introduce type-safety, the combination rule for LJ is madde into
enum class. This also fixes:
1. Out-of-order string assignment to enum values
2. Unsafe utilization of the enum for LJ PME combination rule
   (the values of this enum coincided so no bug by luck)

3 years agoEnsure no UB in writing forces
Mark Abraham [Thu, 4 Feb 2021 08:26:29 +0000 (09:26 +0100)]
Ensure no UB in writing forces

UBSan observed that on non-master ranks we added an offset to a null
pointer in of->f_global. That pointer was never used, so there was no
bug, but we can improve the code by expressing that more clearly.

Ref #3897

3 years agoUpdate llvm docker build
Paul Bauer [Wed, 3 Feb 2021 16:40:13 +0000 (16:40 +0000)]
Update llvm docker build

The LLVM project changed their repository organisation, so we have to
adjust our docker build script to take that into account.

Container for llvm 11 tested locally.

Refs #3897

3 years agoFix test of not_null
Mark Abraham [Wed, 3 Feb 2021 12:28:19 +0000 (13:28 +0100)]
Fix test of not_null

Inadvertently removed too much code

Refs #3893

3 years agoFix issues found by static analyzer
Paul Bauer [Wed, 3 Feb 2021 12:07:33 +0000 (13:07 +0100)]
Fix issues found by static analyzer

Update to version 11 found a few issues that need fixes.

Refs #3897

3 years agoRemove support for Intel classic compiler
Mark Abraham [Wed, 3 Feb 2021 10:44:20 +0000 (10:44 +0000)]
Remove support for Intel classic compiler

This compiler has sometimes generated the fastest code, but also most
often generated the wrong code of any supported compiler. Since Intel
now has another clang-based compiler that they are targetting for GPU
support in oneAPI, we've chosen to support it. Our resources are
limited so something else has to go.

Minor improvements to the install guide while I was there.

Added a fatal error to CMake as otherwise we will get bug reports that
icc doesn't work.

Added release notes

Fixes #3893

3 years agoRemove deprecated env. vars GMX_OCL_NB_ANA_EWALD etc
Andrey Alekseenko [Tue, 2 Feb 2021 13:33:20 +0000 (14:33 +0100)]
Remove deprecated env. vars GMX_OCL_NB_ANA_EWALD etc

The following environment variables were deprecated in 2021, and are
being removed:

GMX_CUDA_NB_ANA_EWALD
GMX_OCL_NB_ANA_EWALD
GMX_CUDA_NB_TAB_EWALD
GMX_OCL_NB_TAB_EWALD
GMX_CUDA_NB_EWALD_TWINCUT
GMX_OCL_NB_EWALD_TWINCUT

Closes #3803

3 years agoUse make_unique instead of reset when private implementations are constructed
Artem Zhmurov [Tue, 2 Feb 2021 05:06:55 +0000 (08:06 +0300)]
Use make_unique instead of reset when private implementations are constructed

Using std::unique_ptr instead of our own implementation in PImpl classes made
compiler more aware of the code and clang-tidy started to complain about
using reset function(...) for PImpl construction.

3 years agoRemove support for Fujitsu Sparc64 HPC-ACE
Mark Abraham [Tue, 2 Feb 2021 09:44:40 +0000 (09:44 +0000)]
Remove support for Fujitsu Sparc64 HPC-ACE

The K computer is turned off, so this architecture is effectively
dead. Note that the NBNXM scheme never supported its SIMD, so even the
SIMD support in other modules was only of modest value.

Part of #3891

3 years agoRemove x86 MIC support
Mark Abraham [Mon, 1 Feb 2021 12:16:44 +0000 (12:16 +0000)]
Remove x86 MIC support

This platform is basically dead, so code and SIMD layer that supports
it should be removed.

There is no need to preserve a stub in the SIMD support enumeration,
because we never need to be consistent with old code. That's different
for other enums that affect e.g. reading old tpr files.

Note that this does not affect KNL support or
SIMD.

Part of #3891

3 years agoReplace gmx::Mutex with std::mutex
Mark Abraham [Fri, 29 Jan 2021 15:24:39 +0000 (16:24 +0100)]
Replace gmx::Mutex with std::mutex

We use no mutexes during the MD loop, so performance is not a serious
consideration and we should simplify by using std components.
Eliminated components of thread-MPI that are now unused.

In particular, this reduces the cross-dependencies between the
libgromacs and threadMPI libraries.

Minor style improvements around set_over_alloc_dd.

Part of #3892

3 years agoFix clang-tidy
Paul Bauer [Sun, 31 Jan 2021 09:30:07 +0000 (10:30 +0100)]
Fix clang-tidy

Code used old unique_ptr handling that needed fixing.

3 years agoRequire MPI 2.0
Mark Abraham [Sun, 31 Jan 2021 19:05:44 +0000 (19:05 +0000)]
Require MPI 2.0

Remove MPI_IN_PLACE_EXISTS, since that can now be assumed. We weren't
testing the fallback path in CI, either.

Simplified MPI install guide. We don't need to maintain
recommendations about MPI library versions.

Fixes #3591

3 years agoRmove dependency on Constraints object from compute_globals(...)
Artem Zhmurov [Fri, 29 Jan 2021 18:37:07 +0000 (18:37 +0000)]
Rmove dependency on Constraints object from compute_globals(...)

Compute globals only uses RMSD data from constraints. This replaces
the Constraints object by the optional argument with RMSD data in
compute_globals(...) function signature.

Refs. #3754

3 years agoAllow MdModules to access the topology during simulation setup.
Hubert Santuz [Fri, 29 Jan 2021 18:08:25 +0000 (18:08 +0000)]
Allow MdModules to access the topology during simulation setup.

3 years agoUse cxx mpi
Roland Schulz [Fri, 29 Jan 2021 15:20:25 +0000 (15:20 +0000)]
Use cxx mpi

3 years agoRemove PrivateImplPointer in favour of std::unique_ptr
Mark Abraham [Fri, 29 Jan 2021 12:11:02 +0000 (13:11 +0100)]
Remove PrivateImplPointer in favour of std::unique_ptr

The single remaining advantage (help with const correctness in an
unlikely corner case) is outweighed by the disadvantages of
using a custom solution where a generic one would do.

Fixes #3684

3 years agoAdded functionality that allows MdModules to disable PME-only ranks during simulation...
Dmitry Morozov [Fri, 29 Jan 2021 10:33:16 +0000 (10:33 +0000)]
Added functionality that allows MdModules to disable PME-only ranks during simulation setup

3 years agoMerge branch release-2021
Mark Abraham [Fri, 29 Jan 2021 07:57:31 +0000 (08:57 +0100)]
Merge branch release-2021

Resolved conflicts:

        admin/gitlab-ci/gromacs.gitlab-ci.yml
        admin/gitlab-ci/python-gmxapi01.gitlab-ci.yml
        api/nblib/gmxsetup.cpp
        api/nblib/listed_forces/gmxcalculator.cpp
        api/nblib/listed_forces/tests/calculator.cpp
        api/nblib/molecules.cpp
        api/nblib/molecules.h
        api/nblib/ppmap.h
        api/nblib/tests/integrator.cpp
        api/nblib/topologyhelpers.cpp
        docs/install-guide/index.rst
        python_packaging/src/setup.py
        src/gromacs/gmxpreprocess/pdb2gmx.cpp
        src/gromacs/gmxpreprocess/readir.cpp
        src/gromacs/gmxpreprocess/topdirs.cpp
        src/gromacs/math/densityfit.cpp
        src/gromacs/mdrun/md.cpp
        src/gromacs/mdrunutility/handlerestart.cpp
        src/gromacs/modularsimulator/simulatoralgorithm.cpp
        src/gromacs/nbnxm/cuda/nbnxm_cuda_data_mgmt.cu
        src/gromacs/nbnxm/nbnxm_gpu_data_mgmt.cpp
        src/gromacs/nbnxm/nbnxm_gpu_data_mgmt.h
        src/gromacs/nbnxm/opencl/nbnxm_ocl_data_mgmt.cpp
        src/gromacs/pulling/pull.cpp

Mostly from refactoring in master that clashed with fixes in
release-2021. Preserved the functionality from the latter in the form
of the former.

Some changes are simply due to the change to clang-format
configuration.

One CI configuration change for mdrun-only build is adapted, since
mdrun-only build has been removed.

3 years agoPrepare for first 2021 patch release
Paul Bauer [Fri, 29 Jan 2021 07:34:26 +0000 (07:34 +0000)]
Prepare for first 2021 patch release

Reset DOI strings

3 years agoMove initiation of local CPU force H2D transfer to producer
Alan Gray [Wed, 27 Jan 2021 14:51:06 +0000 (06:51 -0800)]
Move initiation of local CPU force H2D transfer to producer

For GPU DD cases that include CPU force calculations, a host to device
transfer of local force data is required before the GPU halo
exchange. The initiation of the transfer was previously immediately
before the consumer (GPU halo exchange). This change moves the
initiation to immediately after the last possible producer (the
special force calculation, noting that the CPU force contributions can
also come from preceeding bonded or PME calculations).

Addresses #3082

3 years agoGROMACS 2021 release
Paul Bauer [Thu, 28 Jan 2021 13:35:05 +0000 (13:35 +0000)]
GROMACS 2021 release

Updated regressiontest hash.
Set doi strings.
Set correct release date.

3 years agoFix NB-LIB copyright
Paul Bauer [Thu, 28 Jan 2021 12:12:57 +0000 (13:12 +0100)]
Fix NB-LIB copyright

Was missing some updates and had a wrongly formatted header.

3 years agoFix formatting in random/seed.cpp
Paul Bauer [Thu, 28 Jan 2021 11:07:42 +0000 (12:07 +0100)]
Fix formatting in random/seed.cpp

This was left over after merging release-2020 into 2021.

3 years agoFix failing listed-forces test
kanduri [Thu, 28 Jan 2021 11:37:56 +0000 (11:37 +0000)]
Fix failing listed-forces test

3 years agoReintroduce CI job descriptions
Andrey Alekseenko [Thu, 28 Jan 2021 08:48:27 +0000 (08:48 +0000)]
Reintroduce CI job descriptions

GitLab does not allow adding custom fields to YAML files, so comments
were used. I tried to make the descriptions grep'able (not for the
wqhole matrix, but at least for individual settings), human-readable,
and possibly machine-parseable at the same time.

3 years agoRemove constant acceleration groups
Pascal Merz [Wed, 27 Jan 2021 22:06:00 +0000 (22:06 +0000)]
Remove constant acceleration groups

Per Redmine discussion, this has been broken for about 10
years. Simplifying the update and global energy code is nice, and some
integrators will now be a trifle faster.

The value of SimulationAtomGroupType::Count can't change because reading old .tpr files relies
on it, but the enumeration value has a new name so that any relevant
code rebasing over this change can't silently still compile. This does
mean that loops over egcNR are now slightly less efficient than they
could be, and some of those are in the per-step update code. But that
is likely not worth changing in the current form of the code.

Originally authored by Mark Abraham at
https://gerrit.gromacs.org/c/gromacs/+/8944.

Fixes #1354

3 years agoSYCL: fix typo in a test and clean-up non-standard-compliant code
Andrey Alekseenko [Wed, 27 Jan 2021 12:01:07 +0000 (15:01 +0300)]
SYCL: fix typo in a test and clean-up non-standard-compliant code

Discovered when trying to compile with hipSYCL. Although not an issue
for Intel compiler, better keep things clean.

The change of `write` to `read` in the test code is intended. Not sure
how it worked before, but it should be `read` there.

Also fixed namespace qualifiers, implicit ctors.

3 years agoTest python 3.9.1
Mark Abraham [Wed, 27 Jan 2021 07:43:26 +0000 (08:43 +0100)]
Test python 3.9.1

Extends the image-building infrastructure to also include
python 3.9.1 into images.

Fixes #3479

3 years agoClarify lambda vector usage with figure in manual
Christian Blau [Tue, 2 Jun 2020 12:54:33 +0000 (14:54 +0200)]
Clarify lambda vector usage with figure in manual

Add a figure that clarifies the effect of different lambda values.

3 years agoAdd new sample script for listed forces
Paul Bauer [Tue, 26 Jan 2021 18:34:29 +0000 (19:34 +0100)]
Add new sample script for listed forces

Adds a sample script that demonstrated the use of
listed forces calculator.

3 years agoChange default Ewald kernel to tabulated on NVIDIA CC 7.0
Szilárd Páll [Tue, 26 Jan 2021 16:33:16 +0000 (16:33 +0000)]
Change default Ewald kernel to tabulated on NVIDIA CC 7.0

Partially addressed #3845

3 years agoFix default for xpm2gmx tick-mark spacings
Mark Abraham [Tue, 26 Jan 2021 08:52:07 +0000 (09:52 +0100)]
Fix default for xpm2gmx tick-mark spacings

Inadvertently broken ages ago in 027ae34187f8

Fixes #3881

3 years agoEnable grompp to read virtual_site1
Pascal Merz [Tue, 26 Jan 2021 15:53:54 +0000 (15:53 +0000)]
Enable grompp to read virtual_site1

In !306, a virtual site with one constructing atom was introduced.
grompp was, however, not updated to understand the new topology entry.
This updates the topology format in grompp and the manual. It also adds
a missing example for virtual site type 2fd to the manual.

Found while investigating #3866, but not directly connected.

3 years agoAdd necessary dependence of sample test on check-nblib
ejjordan [Tue, 26 Jan 2021 13:28:45 +0000 (14:28 +0100)]
Add necessary dependence of sample test on check-nblib

This change adds the argon-forces-integration sample script
as a dependency for check-nblib. Without this, the sample script
is not correctly tested.

3 years agoStop installing NB-LIB argon-forces-integration binary
Mark Abraham [Mon, 25 Jan 2021 16:56:57 +0000 (17:56 +0100)]
Stop installing NB-LIB argon-forces-integration binary

This binary should not be installed alongside gmx. For example, the
GROMACS analysis-tool template in share folder is not installed by
default.

There's value to testing that the sample code compiles, but not
everybody needs to install it.

3 years agoUse ctest better to run NB-LIB sample code as a test
Mark Abraham [Mon, 25 Jan 2021 16:41:26 +0000 (17:41 +0100)]
Use ctest better to run NB-LIB sample code as a test

The return code of the sample binary does what a test needs to do.
There's no need to create issues by shoehorning it into a GoogleTest.

Refs #3821

3 years agoUpdate self-documentation in admin/git-pre-commit
Andrey Alekseenko [Mon, 25 Jan 2021 15:43:40 +0000 (15:43 +0000)]
Update self-documentation in admin/git-pre-commit

3 years agoLog progress from gmx msd better
Mark Abraham [Mon, 25 Jan 2021 10:39:56 +0000 (11:39 +0100)]
Log progress from gmx msd better

Refs #3284

3 years agoCheck availability of compile flags at cmake time
Joe Jordan [Mon, 25 Jan 2021 12:48:56 +0000 (12:48 +0000)]
Check availability of compile flags at cmake time

Fixes #3821

Ensures that compile flag can be used before using it. Gives a
message if flag cannot be used.

3 years agoRename DefaultAngle to HarmonicAngleType in nblib listed forces
ejjordan [Mon, 25 Jan 2021 09:53:33 +0000 (10:53 +0100)]
Rename DefaultAngle to HarmonicAngleType in nblib listed forces

This change renames the type corresponding to harmonic angles
in nblib from DefaultAngle to HarmonicAngleType. This is both
more descriptive, and more similar to other listed forces
types in nblib.

Additionaly, one failing test is disabled. This disabling
is needed so that all tests can pass to allow this MR to
be merged. A subsequent MR fixes the test issues.

3 years agoMTS release note
Berk Hess [Mon, 25 Jan 2021 08:29:03 +0000 (08:29 +0000)]
MTS release note

3 years agoUpdate Dockerfiles for Python subpackages.
M. Eric Irrgang [Sun, 24 Jan 2021 17:01:21 +0000 (20:01 +0300)]
Update Dockerfiles for Python subpackages.

Some appropriate adjustments were discovered while
investigating computing environments for an upcoming workshop.

* Bump the base Linux distribution.
* Refine the inline documentation.
* Adjust the package list and build options.

3 years agoFinalize gmxapi Python package version 0.2.
M. Eric Irrgang [Sun, 24 Jan 2021 16:57:36 +0000 (19:57 +0300)]
Finalize gmxapi Python package version 0.2.

3 years agoDisable CUDA textures also on NVIDIA Ampere A100
Szilárd Páll [Fri, 22 Jan 2021 15:11:30 +0000 (16:11 +0100)]
Disable CUDA textures also on NVIDIA Ampere A100

The same benefits have been shown as those observed with V100.

Partially addresses #3845

3 years agoEnsure residue name used by pdb2gmx matches rtp name
Mark Abraham [Thu, 21 Jan 2021 12:11:36 +0000 (12:11 +0000)]
Ensure residue name used by pdb2gmx matches rtp name

The default for GLU/GLUH and ASP/ASPH is the unprotonated form. The
help text pdb2gmx specifically states this, and there is no attempt to
use the residue name to infer the protonation.

The old code set the rtp name to the unprotonated form without
changing the residue name read from the configuration file. The
original residue name was then used in the output configuration and
topology file. That name indicated the wrong protonation if the user
input tried to specify the protonated form via the residue name. Now
it changes the residue name to match the rtp name.

This has been surprising, so whenever pdb2gmx implements its default by
changing the residue name, it now reports that.

The same problem occurs when using pdb2gmx -asp if the input
configuration had the name of the protonated form and the interactive
choice was for the unprotonated form. However, in that case there is
no need to inform the user that the input residue naming is being
overridden. Tested manually.

Updated the tests to handle this case.

Added some release notes, Doxygen, added some comments, and updated some code style
so the review is easier.

Fixes #2480

3 years agoKeep the number of tMPI ranks consistent with the number of GPUs
Andrey Alekseenko [Thu, 21 Jan 2021 09:39:13 +0000 (09:39 +0000)]
Keep the number of tMPI ranks consistent with the number of GPUs

When the number of atoms in a system is small, and the automatic resource
assignment is used (i.e., a user just runs gmx mdrun), the number of ranks
chosen by get_nthreads_mpi might be incompatible with the expectations of
GpuTaskAssignmentsBuilder, namely that the number of ranks must be
divisible by the number of threads.

If the user did not supply the -ntmpi value, and we have to limit the
number of ranks due to small system size, we round it down down to the
nearest value divisible by the number of GPUs to use (or 1, whichever is
greater).

Fixes #3874

3 years agoMinor naming fix in OpenCL nbnxm kernels
Szilárd Páll [Thu, 21 Jan 2021 05:17:55 +0000 (05:17 +0000)]
Minor naming fix in OpenCL nbnxm kernels

OpenCL images are not used and when cleaning up host code the kernel
variables were left with the outdated/wrong naming. This change removes
the suffix to eliminate crust and potential for confusion.

3 years agoSuggest a workaround for pulling with -deffnm
Mark Abraham [Wed, 20 Jan 2021 10:56:38 +0000 (11:56 +0100)]
Suggest a workaround for pulling with -deffnm

Also fixed use of settings, use settings to do the line wrapping,
and wrote some newlines to make the output more readable.

Refs #3875
Fixes #3442

3 years agoUse correct python interpreter cmake check
Paul Bauer [Wed, 20 Jan 2021 10:39:02 +0000 (10:39 +0000)]
Use correct python interpreter cmake check

Still needed to complete address checksumming issue.

Fixes #3862

3 years agoDescribe the configured precision correctly for mdrun
Mark Abraham [Tue, 19 Jan 2021 10:46:01 +0000 (11:46 +0100)]
Describe the configured precision correctly for mdrun

We adopted the build configuration naming scheme for GMX_DOUBLE
"mixed" vs "double" some years ago so that people knew we don't reduce
forces in mdrun solely in single. This change improves consistency in
this regard in the cases that are important to users, ie. log files
and messages about checkpoint restarts.

Various file-reading tools still refer to "single" in contexts where
they are reading floats, which is fine.

3 years agoNBLIB: Remove preprocessor macros
Paul Bauer [Wed, 13 Jan 2021 11:23:02 +0000 (12:23 +0100)]
NBLIB: Remove preprocessor macros

Macros used to implement part of the listed forces calculation have been
removed and replaced with a pure C++ template implementation.

Also addresses review comments not fully resolved from previous merge
requests.

3 years agoFix TPR handling for older versions.
Paul Bauer [Wed, 20 Jan 2021 06:10:40 +0000 (06:10 +0000)]
Fix TPR handling for older versions.

Reading in a newer TPR file in a pre-2021 version would fail hard with
symtab errors due to us forgetting to increment the tpr generation when
adding the VSite1 type to ftupd.

This fixes the omission an makes the tpr generation an enum similar to
the tpr version.

Fixes #3867

3 years agoFix checksumming code
Paul Bauer [Tue, 19 Jan 2021 09:17:49 +0000 (10:17 +0100)]
Fix checksumming code

Recent additions to the code to avoid errors with certain IDEs
caused issues by never trying to validate the checksums.

Fixed by properly passing the necessary variables to the script.

Fixes #3862

3 years agoFix PaddedVector move constructor
Mark Abraham [Wed, 20 Jan 2021 04:57:46 +0000 (04:57 +0000)]
Fix PaddedVector move constructor

This could leave the moved-from vector in a state unfit to destruct.

Expanded test coverage, including improving the tests and their
infrastructure, so I could understand my own code.

Fixes #2832

3 years agoReport hwloc 1.x deprecation only when found
Mark Abraham [Tue, 19 Jan 2021 11:06:38 +0000 (12:06 +0100)]
Report hwloc 1.x deprecation only when found

Refs #3818

3 years agoChange default MTS force group selection
Berk Hess [Tue, 19 Jan 2021 16:38:19 +0000 (16:38 +0000)]
Change default MTS force group selection

Because of instabilities of aliphatic protons with the Amber
force fields, the default force group selection for multiple
time stepping has been changed to include longrange-nonbonded only.

Refs #3804

3 years agoDisable CUDA textures on NVIDIA Volta
Szilárd Páll [Tue, 19 Jan 2021 12:09:15 +0000 (12:09 +0000)]
Disable CUDA textures on NVIDIA Volta

This has significant performance benefit for the nbnxm kernels with
tabulated Ewald correction and it has negligible impact on the PME kernels.

Partially addresses #3845

3 years agoDeprecate mdrun -deffnm
Mark Abraham [Wed, 13 Jan 2021 14:49:39 +0000 (15:49 +0100)]
Deprecate mdrun -deffnm

This functionality is more trouble to implement and test well than
we expected. Even though it is convenient in some cases, on balance
we should remove it and encourage users to use standard approaches
for grouping their files.

Refs #3442, #942, #2205, #2154.
Fixes #3818

3 years agoFix modular simulator log writing in fresh simulation starts with nstlog == 0
Pascal Merz [Tue, 19 Jan 2021 09:39:34 +0000 (09:39 +0000)]
Fix modular simulator log writing in fresh simulation starts with nstlog == 0

With nstlog = 0, legacy simulator writes log on the initial step, while
modular simulator wasn't. This adapts modular simulator to the legacy
approach.

3 years agoAdd G. Gouaillardet to the list of contributors
Szilárd Páll [Tue, 19 Jan 2021 09:02:55 +0000 (09:02 +0000)]
Add G. Gouaillardet to the list of contributors

3 years agoMake inputrec const at simulator level (leaves some TODOs)
Pascal Merz [Tue, 12 Jan 2021 09:36:19 +0000 (09:36 +0000)]
Make inputrec const at simulator level (leaves some TODOs)

This does not resolve the last few instances that change inputrec, but it
makes sure that the intent of inputrec being const is clear, and that future
code changes don't easily introduce additional non-const uses of inputrec.
See !46 for a similar change targetting the global topology.

Refs #3854.

3 years agoAvoid NMR restraints calls for MTS levels > 0
Berk Hess [Tue, 12 Jan 2021 07:38:38 +0000 (07:38 +0000)]
Avoid NMR restraints calls for MTS levels > 0

Distance and orientation restraint code was called for MTS levels > 0
whereas this should not happen.

Fixes #3863

3 years agoRemove mdrun-only build configuration
Mark Abraham [Mon, 11 Jan 2021 11:29:00 +0000 (11:29 +0000)]
Remove mdrun-only build configuration

The existence of this configuration is unnecessary, provides no real
advantages, and was only tested by compiling it (ie not by running
it). Its existence complicates installation, maintenance, testing,
documentation, teaching, and usage. It was deprecated in GROMACS 2021,
and is now removed.

Added a new regressiontests gitlab job now that the build
configuration that used to build with GMX_BUILD_MDRUN_ONLY can run
those tests.

Refs #3808

3 years agoFix copyright year
Pascal Merz [Mon, 11 Jan 2021 03:40:58 +0000 (20:40 -0700)]
Fix copyright year

!972 failed to update the copyright year.

3 years agodensityfit: Fix typo in use of iterators
Andrey Alekseenko [Sat, 9 Jan 2021 19:57:42 +0000 (22:57 +0300)]
densityfit: Fix typo in use of iterators

... and some typos in comments.

While both referenceDensity_ and referenceDensity are views into the same data,
it's clearer to use the same variable for both begin() and end().

This is a remake of MR !740. That MR was reverted (in !748) due to
failed tests. The test failures, however, were caused by an unrelated bug
(issue #3791, fix !827). So, this change is brought back.

3 years agoMake inputrec const everywhere in modular simulator
Pascal Merz [Tue, 17 Nov 2020 19:10:04 +0000 (12:10 -0700)]
Make inputrec const everywhere in modular simulator

3cbf1ecb9a7afa9c4e285bcfd26cab3e52bbc1a5 allows us to make inputrec
const everywhere in the modular simulator.

Refs #3854.

3 years agoARM_SVE: misc fixes
Gilles Gouaillardet [Fri, 8 Jan 2021 07:47:46 +0000 (16:47 +0900)]
ARM_SVE: misc fixes

 - fix a typo
 - remove debug assert()

3 years agoFix periodic actions test
Pascal Merz [Mon, 30 Nov 2020 23:35:46 +0000 (16:35 -0700)]
Fix periodic actions test

The periodic actions test was using `insert` to add options to the
mdp map, but intended to overwrite already present values. This change
replaces the non-overwriting `insert` by a lambda actually overwriting
the default options.

3 years agoAdd new GROMACS logo
Paul Bauer [Wed, 6 Jan 2021 07:55:14 +0000 (08:55 +0100)]
Add new GROMACS logo

Replaces previous logo with new vector graphics one.
Logo (C) by Cathrine Bergh.

3 years agoarm_sve: fix GMX_SIMD_HAVE_4NSIMD_UTIL_{FLOAT,DOUBLE} macro definitions
Gilles Gouaillardet [Thu, 7 Jan 2021 15:24:13 +0000 (15:24 +0000)]
arm_sve: fix GMX_SIMD_HAVE_4NSIMD_UTIL_{FLOAT,DOUBLE} macro definitions

only define these macros in impl_arm_sve_definitions.h when the number of
elements per vector greater than 4

3 years agoMerge branch release-2020 into merge-2020-into-2021
Paul Bauer [Thu, 7 Jan 2021 14:11:04 +0000 (15:11 +0100)]
Merge branch release-2020 into merge-2020-into-2021

Resolved Conflicts:
cmake/gmxVersionInfo.cmake
docs/CMakeLists.txt
docs/conf.cmakein.py
src/gromacs/gmxpreprocess/readir.cpp
src/gromacs/mdlib/expanded.cpp
src/gromacs/mdlib/tests/CMakeLists.txt

3 years agoWrite copyright output files as utf8
Paul Bauer [Thu, 7 Jan 2021 13:08:41 +0000 (13:08 +0000)]
Write copyright output files as utf8

The script could fail otherwise when encodings didn't match.

3 years agoAdd trivial const qualifiers for inputrec
Pascal Merz [Thu, 7 Jan 2021 10:10:27 +0000 (10:10 +0000)]
Add trivial const qualifiers for inputrec

Refs #3854

3 years agoFix nightly webpage upload
Paul Bauer [Wed, 6 Jan 2021 13:47:33 +0000 (14:47 +0100)]
Fix nightly webpage upload

When the server got changed this wasn't changed, so the nightly build
docs have been stale for a while.

3 years agoSimplify test mdp handling
Pascal Merz [Thu, 7 Jan 2021 09:19:34 +0000 (09:19 +0000)]
Simplify test mdp handling

In the current implementation, mdp options are handled in 3 places:
* Defaults for a system are stored in the system database
* General defaults are added to that (using `insert` to avoid overwriting)
  in `prepareDefaultMdpFieldValues`.
* Some more defaults are hardcoded in `prepareMdpFileContents`

`prepareDefaultMdpFieldValues` returns a map of options and option
values.  This allows specific tests to change default options as
needed, but not to add any new options, because
`prepareDefaultMdpFieldValues` only reads a predetermined set of
options. Newly added options are dropped without warning or error. A
specific "other" field in the map allows for additional options - but
users must be careful not to add any option that is already in the map
or that are hardcoded in `prepareMdpFileContents`, which would result
in a grompp error due to having multiple values for the same option.

This makes the functionality hard to use and is prone to errors (case
in point: the periodic actions test is trying to set nstlog, which is
silently ignored, so the test coverage is not what was intended).
Changes to this functionality have previously been stalled in favor of
transition to IMdpOptions, but given that the current road map doesn't
make a full transition in the near future likely, it's likely worth a
small investment to make the current functionality more usable.

This moves all hardcoded values from `prepareMdpFileContents` into the
map returned by `prepareDefaultMdpFieldValues`, and prints all options
present in the map to the mdp string. This allows tests to change or
add any value. The users of the functionality are responsible to fill
the map with valid mdp options - and will get grompp errors if they
fail. This also removes all uses of the "other" keyword (which would
now generate a grompp error, so we're sure we didn't forget any uses).

3 years agoReduce code duplication between Berendsen and c-rescale pressure coupling
Pascal Merz [Thu, 7 Jan 2021 08:59:03 +0000 (08:59 +0000)]
Reduce code duplication between Berendsen and c-rescale pressure coupling

The Berendsen and C-Rescale pressure coupling algorithms are very similar,
yet duplicate a lot of functionality. This unifies the functions using
template parameters to reduce code duplication. This is pure refactoring.

3 years agoRespect user input for nstcomm
Pascal Merz [Thu, 7 Jan 2021 08:39:05 +0000 (08:39 +0000)]
Respect user input for nstcomm

This replaces do_md overwriting ir->nstcomm by a warning at grompp
time. Until now, nstcomm was set to the computed global communication
frequency if nstcomm was smaller. The user is now informed at grompp
time that their choice is not optimal, but the set value is respected.
The criterion for the warning now also encompasses any value for
nstcomm that is not a multiple of the global communication frequency.

Resolves a TODO, and refs #3854.

3 years agoPrepare for GROMACS 2020.6
Christian Blau [Thu, 7 Jan 2021 07:51:56 +0000 (07:51 +0000)]
Prepare for GROMACS 2020.6

Reset DOI strings.
Prepare release note stubs.
Set patch number in build infrastructure.

3 years agoRemove misleading const qualifier for inputrec in expanded ensemble
Pascal Merz [Wed, 6 Jan 2021 15:30:16 +0000 (15:30 +0000)]
Remove misleading const qualifier for inputrec in expanded ensemble

The expanded ensemble functionality took a const pointer to the
inputrec, but might change its references temperature. This is (at the
very least) misleading, so removed the const qualifier.

Refs #3854

3 years agoGROMACS version 2020.5
Christian Blau [Wed, 6 Jan 2021 12:45:31 +0000 (12:45 +0000)]
GROMACS version 2020.5

Set DOI strings.

3 years agoFix lambda printing const qualifier
Pascal Merz [Sun, 6 Dec 2020 01:39:03 +0000 (18:39 -0700)]
Fix lambda printing const qualifier

Use ArrayRef<const real> instead of const ArrayRef<real>.

3 years agoUpdate src/regressiontests URLs to https
Szilárd Páll [Tue, 5 Jan 2021 20:58:23 +0000 (20:58 +0000)]
Update src/regressiontests URLs to https

With the recent server migration we support https downloads and we
should offer those over http.
Also updated the regressiontests URL to point to the ftp server.

3 years agoFix broken random seed generation.
Kevin Boyd [Wed, 30 Dec 2020 17:51:25 +0000 (09:51 -0800)]
Fix broken random seed generation.

On Ryzen 3k CPUs with the RDRAND microcode bug, the
std::mt19937_64 alternate path yields the same seed
on multiple calls that fall within the same second. Changed
the "seed" of the random seed to rescramble each time the
makeRandomSeed() function is called.

Fixes #3859

3 years agoFix broken random seed generation.
Kevin Boyd [Tue, 5 Jan 2021 13:28:26 +0000 (13:28 +0000)]
Fix broken random seed generation.

On Ryzen 3k CPUs with the RDRAND microcode bug, the
std::mt19937_64 alternate path yields the same seed
on multiple calls that fall within the same second. Changed
the "seed" of the random seed to rescramble each time the
makeRandomSeed() function is called.

Fixes #3859

3 years agoFix copyright year
Christian Blau [Tue, 5 Jan 2021 12:29:37 +0000 (13:29 +0100)]
Fix copyright year

Merging !423 on January 1st 2021 causes the pipeline to fail
due to a missed copyright year update.

The copyright year is updated with this patch.