alexxy/gromacs.git
3 years agoRemove TODO regarding AWH cover threshold along lambda axis.
Magnus Lundborg [Mon, 2 Nov 2020 15:53:15 +0000 (16:53 +0100)]
Remove TODO regarding AWH cover threshold along lambda axis.

The 1.0 factor should be OK for a FEP lambda axis. It should be OK
in theory and tests show it works.

Change-Id: Iafe39ab0663ec227e96e40f1b2073818610e93ae
Closes: #3634

3 years agoMake the message why GPU bondeds are not available more clear
Artem Zhmurov [Tue, 3 Nov 2020 07:43:32 +0000 (07:43 +0000)]
Make the message why GPU bondeds are not available more clear

Closes #3728

3 years agoAdd Clang CUDA build to CI
Paul Bauer [Fri, 30 Oct 2020 18:15:17 +0000 (19:15 +0100)]
Add Clang CUDA build to CI

Runs tests during post-merge acceptance, but compiled for all merge
requests.

3 years agoUpdate to nblib non-bonded backend
ejjordan [Mon, 2 Nov 2020 11:05:11 +0000 (12:05 +0100)]
Update to nblib non-bonded backend

* added more documentation
* more consistent naming
* cleaner, more consistent interfaces
* add more checks
* expand test coverage
* fix bugs

3 years agoRemove an unnecessary transitive dependency of imported CMake target.
M. Eric Irrgang [Thu, 29 Oct 2020 20:48:06 +0000 (21:48 +0100)]
Remove an unnecessary transitive dependency of imported CMake target.

Refs #3777

3 years agoFix unused variable warnings
Paul Bauer [Fri, 30 Oct 2020 17:26:33 +0000 (17:26 +0000)]
Fix unused variable warnings

3 years agoAdd missing fix for Clang CUDA
Paul Bauer [Fri, 30 Oct 2020 12:58:59 +0000 (13:58 +0100)]
Add missing fix for Clang CUDA

Was missing from the previous list of fixes (don't know how that
happened).

3 years agoFix build issues with Clang CUDA
Paul Bauer [Fri, 30 Oct 2020 12:38:29 +0000 (12:38 +0000)]
Fix build issues with Clang CUDA

Fixed missing changes in CMake property name
Apply properties correctly for test library.
Fix wrongly attributed gpu_utils test file.

3 years agoIntroduce nblib versioning
Joe Jordan [Fri, 30 Oct 2020 11:36:34 +0000 (11:36 +0000)]
Introduce nblib versioning

3 years agoRework handling of PATH-like variables in GMXRC.bash/zsh
Andrey Alekseenko [Thu, 29 Oct 2020 18:21:16 +0000 (19:21 +0100)]
Rework handling of PATH-like variables in GMXRC.bash/zsh

Old version was not robust to various kinds of trailing colons, as
exerienced in, e.g., #3219.

To make it all safer, a single function, that removes the
old path and adds the new one to the beginning, is introduced.

Tested with:
- GNU bash 4.4.20
- GNU bash 5.0.17
- zsh 5.8
- dash 0.5.8

```
$ replace_in_path ":" "/new" "/old"
/new:
$ replace_in_path "" "/new" "/old"
/new
$ replace_in_path "/old" "/new" "/old"
/new
$ replace_in_path "/old:" "/new" "/old"
/new:
$ replace_in_path "/old:/other" "/new" "/old"
/new:/other
$ replace_in_path ":/other" "/new" "/old"
/new::/other
$ replace_in_path "/other:" "/new" "/old"
/new:/other:
$ replace_in_path "/other:/old" "/new" "/old"
/new:/other
```

Full test:

```
$ bash -c 'MANPATH=''; . scripts/GMXRC.bash; echo $MANPATH;'
/usr/local/gromacs/share/man
$ bash -c 'MANPATH=':'; . scripts/GMXRC.bash; echo $MANPATH;'
/usr/local/gromacs/share/man:
$ bash -c 'MANPATH='/abc'; . scripts/GMXRC.bash; echo $MANPATH;'
/usr/local/gromacs/share/man:/abc
$ bash -c 'MANPATH='/abc:'; . scripts/GMXRC.bash; echo $MANPATH;'
/usr/local/gromacs/share/man:/abc:

$ bash -c 'MANPATH=':'; . scripts/GMXRC.bash; . scripts/GMXRC.bash; . scripts/GMXRC.bash; echo $MANPATH;'
/usr/local/gromacs/share/man:
$ bash -c 'MANPATH=''; . scripts/GMXRC.bash; . scripts/GMXRC.bash; . scripts/GMXRC.bash; echo $MANPATH;'
/usr/local/gromacs/share/man
$ bash -c 'MANPATH='/abc'; . scripts/GMXRC.bash; . scripts/GMXRC.bash; . scripts/GMXRC.bash; echo $MANPATH;'
/usr/local/gromacs/share/man:/abc
$ bash -c 'MANPATH='/abc:'; . scripts/GMXRC.bash; . scripts/GMXRC.bash; . scripts/GMXRC.bash; echo $MANPATH;'
/usr/local/gromacs/share/man:/abc:
```

Closes #2628, #3219

3 years agoClang format
Szilárd Páll [Tue, 27 Oct 2020 10:49:58 +0000 (11:49 +0100)]
Clang format

3 years agoAdd fvec doxygen
Szilárd Páll [Tue, 27 Oct 2020 10:49:24 +0000 (11:49 +0100)]
Add fvec doxygen

3 years agoFix AMD OpenCL float3 array optimization bug
Szilárd Páll [Thu, 6 Feb 2020 23:40:12 +0000 (00:40 +0100)]
Fix AMD OpenCL float3 array optimization bug

Because float3 by OpenCL spec is 16-byte, when used as an array type
the allocation needs to optimized to avoid unnecessary register use.
The nbnxm kernels use a float3 i-force accumulator array in registers.

Starting with ROCm 2.3 the AMD OpenCL compiler regressed and lost
its ability to effectively optimize code that uses float3 register
arrays. The large amount of extra registers used limits the kernel
occupancy and significantly impacts performance.
Only the AMD platform is affected, other vendors' compilers are able to
do the necessary transformations to avoid the extra register use.

This change converts the float3 array to a float[3] saving 8*4 bytes
register space. This improves nonbonded kernel performance
on an AMD Vega GPU by 25% and 40% for the most common flavor of the
Ewald and RF force-only kernels, respectively.

Note that eliminating the rest of the non-array use of float3 has no
significant impact.

3 years agoFix CUDA code issues
Paul Bauer [Thu, 29 Oct 2020 16:47:33 +0000 (17:47 +0100)]
Fix CUDA code issues

Remove unused template.
Fix variable initialization order and remove obsolete variable.
Fix missing newline.

3 years agoDefault initialize pull datastructures
Paul Bauer [Thu, 29 Oct 2020 09:29:05 +0000 (10:29 +0100)]
Default initialize pull datastructures

Avoids warnings with gcc-9 about potential use of uninitialized
variables.

Fixes #3772

3 years agoMake dispatchTemplatedFunction compatible with MSVC
Andrey Alekseenko [Wed, 28 Oct 2020 12:34:20 +0000 (13:34 +0100)]
Make dispatchTemplatedFunction compatible with MSVC

MR !730 introduced a new function, dispatchTemplatedFunction, which
broke build with MSVC 19.27. Looks like a compiler problem, but the fix
is easy enough (and, arguably, makes the code a bit easier to read).

3 years agoCorrect AWH initial histogram size
Berk Hess [Wed, 28 Oct 2020 10:47:49 +0000 (10:47 +0000)]
Correct AWH initial histogram size

The initial histogram size for AWH incorrectly contained
a Gaussian geometry factor and also treated higher dimensional
cases incorrectly. The formula has now been simplified and
described more accurately in the manual.

Fixes #3751

3 years agooptions: add the eftCSV OptionFileType
Gilles Gouaillardet [Thu, 22 Oct 2020 08:22:01 +0000 (17:22 +0900)]
options: add the eftCSV OptionFileType

3 years agoAdd dispatchTemplatedFunction
Andrey Alekseenko [Mon, 19 Oct 2020 15:05:18 +0000 (17:05 +0200)]
Add dispatchTemplatedFunction

A helper function to select a templated function in runtime based on Enum value.

3 years agoFix remaining clang tidy issues with OpenCL
Paul Bauer [Tue, 27 Oct 2020 15:29:24 +0000 (16:29 +0100)]
Fix remaining clang tidy issues with OpenCL

Some code blocks still needed cleaning from clang-tidy.

Came up during manual run in preparation for CI job.

3 years agoMix minor clang-tidy warning in double
Paul Bauer [Tue, 27 Oct 2020 14:18:37 +0000 (15:18 +0100)]
Mix minor clang-tidy warning in double

One cast was using C-style, changed to C++ static_cast.

3 years agoUse the correct CI script for sample_restraint jobs.
M. Eric Irrgang [Tue, 27 Oct 2020 14:31:45 +0000 (14:31 +0000)]
Use the correct CI script for sample_restraint jobs.

release-2021 should use the CI script that applies
the pytest `--threads` option.

3 years agoFix clang-tidy v10 warnigns in OpenCL kernels
Szilárd Páll [Tue, 27 Oct 2020 14:13:45 +0000 (14:13 +0000)]
Fix clang-tidy v10 warnigns in OpenCL kernels

Also made convert_sigma_epsilon_to_c6_c12() return a float2 with c6 and
c12 instead of returning results in pointers.

3 years agoNormalize FindMPI hints.
M. Eric Irrgang [Mon, 26 Oct 2020 16:50:12 +0000 (17:50 +0100)]
Normalize FindMPI hints.

Let gmxapi target use the MPI C component instead of CXX for consistency
with gmxManageMPI.cmake.

Refs #3671
Refs #3672

3 years agoClarify behavior of LegacyMdrunOptions.
M. Eric Irrgang [Sat, 26 Sep 2020 14:21:00 +0000 (17:21 +0300)]
Clarify behavior of LegacyMdrunOptions.

Make notes about the lifetime management of LegacyMdrunOptions and its
members. Note effects on the way it must be used by gmxapi::ContextImpl.
Clarify how gmxapi::ContextImpl could be updated in the future if data
scope details of LegacyMdrunOptions evolve.

Relates to #3644, #3688, #3718

3 years agoUpdate image names in job definitions.
M. Eric Irrgang [Tue, 27 Oct 2020 08:53:46 +0000 (08:53 +0000)]
Update image names in job definitions.

Use explicit CMake versions, as appropriate.

Refs #3621

3 years agoRemove unused velocity scaling enum value
Artem Zhmurov [Tue, 27 Oct 2020 05:55:20 +0000 (08:55 +0300)]
Remove unused velocity scaling enum value

The velocities are never scaled by a full matrix, hence
the extra value in the enumeration is not needed. Having
extra possible value in the templated parameter may
hurt the compilation time.

3 years agoDon't deploy nightly webpages
Paul Bauer [Mon, 26 Oct 2020 06:14:07 +0000 (07:14 +0100)]
Don't deploy nightly webpages

Removed code used to deploy nightly master webpage from nightly builds.

3 years agoTell gmxapi to look for MPI, when appropriate.
M. Eric Irrgang [Mon, 26 Oct 2020 14:07:21 +0000 (15:07 +0100)]
Tell gmxapi to look for MPI, when appropriate.

The recommended CMake configuration for MPI-enabled GROMACS does not
provide MPI compiler wrappers for regular compiler variables. However,
the MPI toolchain details do not get conveyed transitively through the
libgromacs target. This should be easily resolved by checking whether
libgromacs is built with MPI library support and, if so, using the
CMake FindMPI module.

This may not be robust and should be revisited in the context of issue
#3672.

Meanwhile, this change should reduce errors for users following the
documentation updated under #3671.

3 years agoMake install-guide MPI consistent
Roland Schulz [Fri, 23 Oct 2020 18:12:47 +0000 (11:12 -0700)]
Make install-guide MPI consistent

Fixes #3671

3 years agoClear constraints RMSD values upon domains reset
Artem Zhmurov [Mon, 26 Oct 2020 06:34:11 +0000 (06:34 +0000)]
Clear constraints RMSD values upon domains reset

When atoms migrate from one domain to another, some domains can be
left without constraints assigned to them. In this case, old RMSD
data can contaminate the output and lead to arithmetic exceptions.

Also match conditinal when constraints RMSD values are collected
and when printed.

Fixes #3742, related to #3305.

3 years agoDisallow OpenMP on Windows in CI
Paul Bauer [Fri, 23 Oct 2020 11:44:15 +0000 (13:44 +0200)]
Disallow OpenMP on Windows in CI

The builds with MSVC and OpenMP fail too many unit tests, so we need to
disable this combination in CI.

Builds now can pass testing on Github.

Refs #3752

3 years agoExclude CUDA 10.2 as well from C++17 compilation
Szilárd Páll [Sat, 24 Oct 2020 12:05:08 +0000 (12:05 +0000)]
Exclude CUDA 10.2 as well from C++17 compilation

This commit corrects compilation with CUDA 10.2, which does not support
C++17, by changing the condition to pass -std=c++14 to nvcc added by
commit b6172240bfb5daf80d32150924bcdc46a4b07e10.

3 years agoFix warning with OneAPI compiler and AVX512
Roland Schulz [Fri, 23 Oct 2020 17:59:00 +0000 (10:59 -0700)]
Fix warning with OneAPI compiler and AVX512

Also improves consistentcy because other SIMD functions
are declared as `static inline`.

3 years agoUpdate Docker image build scripts.
M. Eric Irrgang [Fri, 23 Oct 2020 14:09:50 +0000 (14:09 +0000)]
Update Docker image build scripts.

Adopt new naming scheme and conventions for Docker image contents.

Jobs will be updated to use the new images in a follow-up change.

Refs #3621

3 years agoFix propagating flags for Intel + Windows
Paul Bauer [Thu, 22 Oct 2020 12:04:06 +0000 (14:04 +0200)]
Fix propagating flags for Intel + Windows

Flag would only be set in local scope and not for global one.

3 years agoUse updated CI pipeline rules for Python package tests.
M. Eric Irrgang [Tue, 20 Oct 2020 16:44:35 +0000 (18:44 +0200)]
Use updated CI pipeline rules for Python package tests.

Refs #3744

3 years agoIntroduce intermediate variable so that compiler will not complain
Artem Zhmurov [Thu, 22 Oct 2020 13:39:03 +0000 (16:39 +0300)]
Introduce intermediate variable so that compiler will not complain

Some compilers complain about the shift being larger than the shifted
variable, even though it is never executed in this case. This introduces
an intermediate shift variable that is explicitely set to zero in this case.

Issue #3752.

3 years agoFix static linking with MSVC
Paul Bauer [Thu, 22 Oct 2020 14:34:23 +0000 (14:34 +0000)]
Fix static linking with MSVC

The C and CXX flags are now properly propagated to allow static linking.

Also fixed unrelated issue with Intel where settings didn't propagate
correctly.

3 years agoFix formatting of the authors list
Artem Zhmurov [Thu, 22 Oct 2020 08:13:42 +0000 (11:13 +0300)]
Fix formatting of the authors list

Previously defined length of 18 chars per name was not enough for
some of us and the authors list become poorly aligned. This changes
the format to have only three authors per line, thus allowing for
up to 26 characters per name. And we are hiring!

3 years agoCompile host code with c++14 where needed
Mark Abraham [Thu, 22 Oct 2020 13:09:30 +0000 (15:09 +0200)]
Compile host code with c++14 where needed

CUDA doesn't support C++17 compilation before 10.2

3 years agoAdd missing GPU force reduction cycle counting
Szilárd Páll [Thu, 22 Oct 2020 09:02:58 +0000 (09:02 +0000)]
Add missing GPU force reduction cycle counting

Launch timing was missing in the GPU reduction refactoring added in
257d80. This change adds back the cycle counting reducing the time
leaking into the rest timer.

3 years agoTrajectoryElement: initialize and rename logWritingStep_
Andrey Alekseenko [Thu, 22 Oct 2020 06:49:25 +0000 (06:49 +0000)]
TrajectoryElement: initialize and rename logWritingStep_

3 years agoSuppress warnings from clang with nvcc more widely
Mark Abraham [Wed, 21 Oct 2020 12:45:57 +0000 (14:45 +0200)]
Suppress warnings from clang with nvcc more widely

The original fix wasn't applied widely enough, probably because of
caching of compiler flags when I tested more recent CUDA versions.
This now fixes the issue of !644 more widely.

3 years agoAdd missing cycle counting for GPU halo exchange calls
Szilárd Páll [Tue, 20 Oct 2020 22:41:59 +0000 (00:41 +0200)]
Add missing cycle counting for GPU halo exchange calls

Calls lesft un-timed that were leaking into the "Rest" timer are now
accounted for.

3 years agoFix C++ language flag propagation to nvcc
Mark Abraham [Wed, 21 Oct 2020 08:50:33 +0000 (10:50 +0200)]
Fix C++ language flag propagation to nvcc

Without this, the host code is compiled with the default language
level of the compiler, which varies by compiler and version. GROMACS
should specify the version being targeted.

This mostly reverts commit 33c239bee76444e82184c0c5685a543b8b141535.

Fixes #3749

3 years agoOnly build nblib tests when requested
Paul Bauer [Wed, 21 Oct 2020 13:15:03 +0000 (13:15 +0000)]
Only build nblib tests when requested

Was missing a check for GMX_DEVELOPER_BUILD being set.

Fixes #3739

Change-Id: I27d2b174cca8b16a1aa54c6a78c75cdd458d590d

3 years agoRevert "densityfit: Fix inconsistent use of iterators"
Andrey Alekseenko [Wed, 21 Oct 2020 10:39:15 +0000 (12:39 +0200)]
Revert "densityfit: Fix inconsistent use of iterators"

This reverts commit a96e538b04cf6ff1e983d62fa58fb6150ab0c97f.

3 years agodensityfit: Fix inconsistent use of iterators
Andrey Alekseenko [Tue, 20 Oct 2020 16:19:34 +0000 (18:19 +0200)]
densityfit: Fix inconsistent use of iterators

and some typos

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

3 years agoUpdate gmxapi version details.
M. Eric Irrgang [Tue, 20 Oct 2020 12:25:58 +0000 (14:25 +0200)]
Update gmxapi version details.

The bump from gmxapi 0.1 to 0.2 was overlooked for the C++ API.

Currently, the Python bindings require C++ API version 0.2,
but this requirement can probably be relaxed before the final version
of the 0.2 Python package.

3 years agoMerge branch 'origin/release-2020' into merge-release-2020
Paul Bauer [Tue, 20 Oct 2020 14:50:31 +0000 (16:50 +0200)]
Merge branch 'origin/release-2020' into merge-release-2020

3 years agoAllow gcc-9 on Power 9
Szilárd Páll [Tue, 20 Oct 2020 14:42:50 +0000 (14:42 +0000)]
Allow gcc-9 on Power 9

Previous restriction ended up blacklisting gcc 9 and later whereas the
intent was to only do so for version 10 and later. Worked around the
version comparison quirk (and lack of >= operator).

Refs #3380

Change-Id: If9f45fe77459c3d873eab3856126f1653efe8cdb

3 years agoUpdate CI rules for release-2021
Paul Bauer [Tue, 20 Oct 2020 14:09:51 +0000 (14:09 +0000)]
Update CI rules for release-2021

Changes rules to target release-2021 branch instead of master.
Update regressiontest download branch.

3 years agoGROMACS 2021 first beta release
Paul Bauer [Tue, 20 Oct 2020 09:57:41 +0000 (09:57 +0000)]
GROMACS 2021 first beta release

Needs branch from master in a follow-up

Change-Id: Ic8a26bd11d07278bc048023597ecfef602b4feb6

3 years agoRevert "GROMACS 2021 first beta release"
Paul Bauer [Tue, 20 Oct 2020 07:15:59 +0000 (09:15 +0200)]
Revert "GROMACS 2021 first beta release"

This reverts commit 6e84b715331a92750bdb2c697e6d810262a5ffb5.

Version string is not correct.

3 years agoGROMACS 2021 first beta release
Paul Bauer [Tue, 20 Oct 2020 06:41:02 +0000 (06:41 +0000)]
GROMACS 2021 first beta release

Needs branch from master in a follow-up

Change-Id: Iae03d2228dc5ce8380dfb491ee11b6aff81d9796

3 years agoAdd release highlights
Paul Bauer [Mon, 19 Oct 2020 15:07:02 +0000 (15:07 +0000)]
Add release highlights

Change-Id: I08d3f93dc28a8bc18ce193ccfcf781ed6e19ee80

3 years agoRevert "Add muparser and CMake handling"
Paul Bauer [Mon, 19 Oct 2020 08:49:38 +0000 (10:49 +0200)]
Revert "Add muparser and CMake handling"

This reverts commit b06ac54659006d4071564c18f7abcc17d359e9c4.

Not needed as we won't have the dependent code in yet.

Change-Id: If4a7a29e3288d1ab5e0716862a636be6a1fb8d9a

3 years agoFix random doxygen warnings and typos
Andrey Alekseenko [Fri, 16 Oct 2020 14:16:04 +0000 (16:16 +0200)]
Fix random doxygen warnings and typos

Silence annoying
"/builds/gromacs/gromacs/src/gromacs/math/vectypes.h:87: error:
gmx::BasicVector: is in library file(s), but appears in public
documentation" from source-check pipeline (appears to be false-positive
due to a forward-declaration in a random file). I was not able to come
up with a quick fix for the underlying problem in check-source, and,
from my understanding, there are plans for refactoring it soon anyway;
so I went with a suppression here.

Fix a bunch of random typos throughout the code.

Fix some unbalanced Doxygen's \{ and \}. And one widowed @}.

Fix some \copydocs (not all).

Remove a nasty non-breakable-space that was messing up block
indentation in Sphinx docs.

3 years agoNew Twitter-based quote
Erik Lindahl [Sat, 17 Oct 2020 17:14:18 +0000 (19:14 +0200)]
New Twitter-based quote

3 years agoHalo exchange unit test for pre-existing CPU codepath
Alan Gray [Mon, 19 Oct 2020 11:46:37 +0000 (11:46 +0000)]
Halo exchange unit test for pre-existing CPU codepath

The test sets up a 2D rank topology and performs a coordinate halo
exchange (using the pre-existing CPU codepath), with 2 pulses in
the first dimension and 1 pulse in the second. Each pulse involves
a few non-contiguous indices. The sending rank, atom number and
spatial 3D index are encoded in the x values, to allow correctness
checking following the halo exchange. Follow-up will port to GPU codepath.

3 years agoEnable MSVC and MacOSX testing on Github
Paul Bauer [Sun, 18 Oct 2020 10:55:14 +0000 (10:55 +0000)]
Enable MSVC and MacOSX testing on Github

Adds files needed to test basic builds using MSVC and MacOSX on Github
using Github actions. The setup has been used with slight modifications
from the example here:
https://cristianadam.eu/20191222/using-github-actions-with-c-plus-plus-and-cmake/

Change-Id: I4f42017b2747d55e01a00f971b140089da5d970c

3 years agoWhen loading AWH user data do not convolve the bias along FEP dims.
Magnus Lundborg [Thu, 15 Oct 2020 10:17:03 +0000 (12:17 +0200)]
When loading AWH user data do not convolve the bias along FEP dims.

Fixes: #3736.

3 years agoFix for force copy dependency of GPU force reduction
Alan Gray [Fri, 16 Oct 2020 11:15:41 +0000 (11:15 +0000)]
Fix for force copy dependency of GPU force reduction

Fixes issue #3729

3 years agoFixes for clang 11
Mark Abraham [Fri, 16 Oct 2020 07:24:56 +0000 (07:24 +0000)]
Fixes for clang 11

Keeps the build free of warnings about the missing commas
that affected the word spacing in the docs.

3 years agoIncrease tolerances for NBlibTest.SpcMethanolForcesAreCorrect test
Andrey Alekseenko [Wed, 14 Oct 2020 15:27:41 +0000 (17:27 +0200)]
Increase tolerances for NBlibTest.SpcMethanolForcesAreCorrect test

3 years agoAdd static constexpr members to naming style guide
Andrey Alekseenko [Wed, 14 Oct 2020 16:06:25 +0000 (16:06 +0000)]
Add static constexpr members to naming style guide

Resolves #3733.

3 years agoFix compilation with MSVC
Mark Abraham [Fri, 9 Oct 2020 15:54:30 +0000 (17:54 +0200)]
Fix compilation with MSVC

3 years agoFix string interpolation error
Mark Abraham [Wed, 14 Oct 2020 12:51:47 +0000 (14:51 +0200)]
Fix string interpolation error

Otherwise the interpolation will overrun the buffer

3 years agoFix bonded tests
Mark Abraham [Wed, 14 Oct 2020 09:58:25 +0000 (09:58 +0000)]
Fix bonded tests

These were not robust enough to pass everywhere (e.g. release
builds). They probably still are not, but fixing that needs more work
than we can do now. A key part of this is that acos implementations
differ, leading to different bond angles being computed, which leads
to different rounding error in accumulating forces and shift forces.
The latter now use different tolerances, because often we compute a shift
force that is zero, modulo rounding error.

Updated required version for reference build type to gcc 7.

Used namespaces better in bonded tests

Added some GoogleTest pretty-printers to see better what was going on.

Added useful strings describing bonded kernel flavors so test failures
had more context.

Used coordinates for butane in tests so that numerical instability was
less of a problem.

Avoided an unnecessary include of vectypes.h and testasserts.h

3 years agoRevert "CUDA nightly fail: Dirty hack"
Andrey Alekseenko [Wed, 14 Oct 2020 08:45:57 +0000 (08:45 +0000)]
Revert "CUDA nightly fail: Dirty hack"

This reverts commit c8b6d3b269730ad613b1810aa255e05395d7e8fe.

3 years agoFix missing copyright and release notes
Paul Bauer [Tue, 13 Oct 2020 12:35:54 +0000 (12:35 +0000)]
Fix missing copyright and release notes

Change-Id: I23153cd393ca8f40bda16871ff25d3285c7fe2ed

3 years agoFix segfault in pull reading
Joe Jordan [Tue, 13 Oct 2020 12:35:33 +0000 (12:35 +0000)]
Fix segfault in pull reading

Triggers asserton now later on :(

Change-Id: I08a390de653e8bbdf23288ed8a28b6dc7ad6305d

3 years agoAdd missing header in shake to fix mac clang compilation
Christian Blau [Tue, 13 Oct 2020 07:48:57 +0000 (09:48 +0200)]
Add missing header in shake to fix mac clang compilation

Missing <cstdlib> fails compilation due to usage of qsort
on mac.

Closes #3730

3 years agoDo not validate build for external source management
Paul Bauer [Tue, 13 Oct 2020 07:32:55 +0000 (07:32 +0000)]
Do not validate build for external source management

If git was not found for builds not coming from a tarball,
the source validation script would generate warnings due to the missing
reference checksum file.

Refs #2128

Change-Id: I7a0d0c164e19eb47446b26a039442b57e537375b

3 years agoFix nblib flags
Gilles Gouaillardet [Mon, 12 Oct 2020 14:52:23 +0000 (14:52 +0000)]
Fix nblib flags

add a missing call to gmx_target_compile_options() in CMakeLists.txt

3 years agoFix the seeding of PRNG when it is used instead of RG
Artem Zhmurov [Mon, 12 Oct 2020 08:50:01 +0000 (08:50 +0000)]
Fix the seeding of PRNG when it is used instead of RG

Use the timer value to seed PRNG, also switch to MT generator.

3 years agoFix NBLIB CMake error message
Szilárd Páll [Fri, 9 Oct 2020 16:32:31 +0000 (18:32 +0200)]
Fix NBLIB CMake error message

The recommended CMake syntax was missing the 'D' prefix.

3 years agoapi/nblib/tests/integrator.cpp: Minor changes
Andrey Alekseenko [Fri, 9 Oct 2020 11:29:39 +0000 (13:29 +0200)]
api/nblib/tests/integrator.cpp: Minor changes

- Move integrator.integrate call out of for(atoms) loop, so it is run
once per timestep. We have only one atom, so it was not an actual error,
but was a bit illogical.

- Make starting conditions for the integrator a bit more diverse, as
suggested by Paul Bauer.

3 years agoCool quote picking can freeze when hardware random number generation is not working
Artem Zhmurov [Fri, 9 Oct 2020 15:08:45 +0000 (15:08 +0000)]
Cool quote picking can freeze when hardware random number generation is not working

The bug with hardware random number generation can cause picking of cool quotes to
freeze in an infinite loop on some Ryzen systems. This patch checks the system for
the bug and falls back to PRNGs.

3 years agoTry to fix the nightly clang-tidy-9 build
Andrey Alekseenko [Fri, 9 Oct 2020 14:23:34 +0000 (14:23 +0000)]
Try to fix the nightly clang-tidy-9 build

It appears that some of the `#ifdef __clang_analyzer__` patches in
gtest/gmock are now messing up with clang-tidy.
Probably related to https://reviews.llvm.org/D46325?

Here, we remove some of these special handlings of clang-analyzer, and
add a couple of more gentle NOLINT's. Since apparently we already had
patches in our copy of googletest, I don't feel bad about it.

Appears to work fine locally with clang-tidy-9.

3 years agoAdd MTS support for pull and AWH
Berk Hess [Fri, 9 Oct 2020 13:19:10 +0000 (15:19 +0200)]
Add MTS support for pull and AWH

Also adds a test for pulling with MTS.

3 years agoRemove dysfunctional QMMM interface pt5
Christian Blau [Fri, 9 Oct 2020 12:40:44 +0000 (12:40 +0000)]
Remove dysfunctional QMMM interface pt5

Removing string entries in .mdp files.

Change-Id: Ic2e0c7f78c9b89b6ecef74e7e862d66fa40d423c

3 years agoRemove under the hood editing of pdb files
Paul Bauer [Fri, 9 Oct 2020 08:10:51 +0000 (10:10 +0200)]
Remove under the hood editing of pdb files

The routines in pdbio.cpp would change atom names for hydrogens
without explicit user consent. This could lead to problems interpreting
NMR files. In addition from a software design point of view, reading
and writing data to files is not the same as interpreting it.

Fixes #3649

Change-Id: Id68c39700bfe56800e9e5dd135bc8b98ada77e8b

3 years agoAWH: Remove random term from FEP tests
Magnus Lundborg [Mon, 21 Sep 2020 10:02:18 +0000 (12:02 +0200)]
AWH: Remove random term from FEP tests

Test if it is the random numbers that are making tests fail on
some builds.
Fixes: #3660

Change-Id: I3e189d7770f0089ac5d74128e096461c5b55f44f

3 years agoClarify the GMX_BUILD_MDRUN_ONLY full testing instructions.
M. Eric Irrgang [Thu, 8 Oct 2020 17:47:33 +0000 (17:47 +0000)]
Clarify the GMX_BUILD_MDRUN_ONLY full testing instructions.

For full testing of an MDRUN_ONLY installation, the documentation
suggests installing over a non MDRUN_ONLY installation. This change
attempts to clarify the use case and normalize the important aspects
of the CMake command lines.

Fixes #3723

3 years agoNBlibTest/IntegratorWorks: Initialize x's and v's
Andrey Alekseenko [Thu, 8 Oct 2020 11:14:07 +0000 (13:14 +0200)]
NBlibTest/IntegratorWorks: Initialize x's and v's

The coordinates and velocities of the test atom were left uninitialized.
This, on my machine, occasionally caused NbLibIntegratorTests to
timeout, getting stuck indefinitely inside `put_atoms_in_box` function.

3 years agoAdd explicit types to NB kernel type enums
Andrey Alekseenko [Thu, 8 Oct 2020 10:20:57 +0000 (10:20 +0000)]
Add explicit types to NB kernel type enums

So these enums could be used in template parameters

3 years agoSet CUDA hardware constants for CC 7.5, 8.6
Andrey Alekseenko [Wed, 7 Oct 2020 12:54:22 +0000 (14:54 +0200)]
Set CUDA hardware constants for CC 7.5, 8.6

The devices from CC 7.5 and 8.6 have lower limits on # of threads/blocks
per SM compare to all other CC 5.x+ architectures.

Source: CUDA Occupancy Calculator,
https://docs.nvidia.com/cuda/cuda-occupancy-calculator/CUDA_Occupancy_Calculator.xls,
accessed 2020-10-07.

3 years agoDevice management: Add SYCL GpuEventSynchronizer
Andrey Alekseenko [Thu, 8 Oct 2020 09:24:09 +0000 (09:24 +0000)]
Device management: Add SYCL GpuEventSynchronizer

3 years agoActivate SYCL build on CI
Andrey Alekseenko [Thu, 8 Oct 2020 08:51:36 +0000 (08:51 +0000)]
Activate SYCL build on CI

3 years agoAdd Andrey Alekseenko to the list of authors
Artem Zhmurov [Wed, 7 Oct 2020 20:47:38 +0000 (23:47 +0300)]
Add Andrey Alekseenko to the list of authors

3 years agoAdd GpuRegionTimer for SYCL
Andrey Alekseenko [Thu, 1 Oct 2020 14:54:38 +0000 (16:54 +0200)]
Add GpuRegionTimer for SYCL

3 years agoNew release, new quotes!
Erik Lindahl [Wed, 7 Oct 2020 13:49:36 +0000 (15:49 +0200)]
New release, new quotes!

3 years agoFix excessive hackblock warning output
Paul Bauer [Wed, 7 Oct 2020 15:32:21 +0000 (15:32 +0000)]
Fix excessive hackblock warning output

Used the wrong string comparison when checking if entries are equal in
the hackblock and rtp entries.

Fixes #3722

Change-Id: I6fecf2746a16a1694232b2c0d15c810dc0d67ec2

3 years agoUpdate to oneAPI beta09
Mark Abraham [Wed, 7 Oct 2020 13:51:06 +0000 (13:51 +0000)]
Update to oneAPI beta09

3 years agoImprove gmxPythonDiscovery.cmake
M. Eric Irrgang [Wed, 7 Oct 2020 13:28:58 +0000 (13:28 +0000)]
Improve gmxPythonDiscovery.cmake

* Do a better job of urging CMake 3.15+ to use the requested Python
  installation when a user specifies Python3_ROOT_DIR.
* Adopt another CMake 3.15 feature: Python3_FIND_VIRTUALENV is much more
  readable than the older alternatives.
* Allow FindPython inputs to be set before entering the module (such as
  with `-D` command line arguments) by checking before setting.
* Clarify which parts of this CMake module apply to the main FindPython
  based detection and which parts exist to provide hints to other
  embedded / downstream detection.

Refs #3720

3 years agoMake LeapFrogGpu less tied to CUDA
Andrey Alekseenko [Tue, 6 Oct 2020 16:36:35 +0000 (18:36 +0200)]
Make LeapFrogGpu less tied to CUDA

- Extract common parts of LeapFrogGpu from .cuh into .h

- Make it use DeviceBuffers instead of raw pointers. For CUDA build,
they are the same, so no changes to other parts of the code necessary.

3 years agoFix download location for regressiontests
Paul Bauer [Tue, 6 Oct 2020 14:32:27 +0000 (16:32 +0200)]
Fix download location for regressiontests

Was still pointing to gerrit instead of the ftp server.

Change-Id: Ia49f06dd1438f6484470ea93ee93f4b26c708fb5

3 years agomdlib/tests/leapfrog: Make GPU tests more platform-agnostic
Andrey Alekseenko [Wed, 7 Oct 2020 09:38:35 +0000 (09:38 +0000)]
mdlib/tests/leapfrog: Make GPU tests more platform-agnostic

In preparation for adding SYCL implementation.

Also, clean-up includes a bit.