alexxy/gromacs.git
5 years agoRename gmx Variant to Any
Roland Schulz [Mon, 21 Jan 2019 19:15:38 +0000 (11:15 -0800)]
Rename gmx Variant to Any

Aligns much better with the C++17 naming given that gmx::Any has
similar functionality as std::any and is different from std::variant.

Change-Id: Id81f402c91197a62ce8ae6212b863aabd9952f6f

5 years agoMultidimensional data in canonical layout.
Christian Blau [Sat, 5 Jan 2019 07:45:57 +0000 (08:45 +0100)]
Multidimensional data in canonical layout.

Introduces a multidimensional array that holds its own data and makes it
accessible via the canonical right-aligned layout for indexing the data.

refs: #2282

Change-Id: I883cdb6a41d7277669e100320e230904856d1318

5 years agoIntroduce string comparison function
Paul Bauer [Mon, 21 Jan 2019 09:07:33 +0000 (10:07 +0100)]
Introduce string comparison function

Added function to perform case insensitive string
comparison on std::string as input. Used some places in preprocessing as
showcases for the new function.

Change-Id: Ie128949883c05d0e7f951687bb4d51eca1d6f9d2

5 years agoTurn SystemAtomIterator into proper iterator
Roland Schulz [Fri, 18 Jan 2019 00:29:41 +0000 (16:29 -0800)]
Turn SystemAtomIterator into proper iterator

Enables range based for loop. Also renamed to AtomIterator.

Change-Id: I87e0ef50c4e0899a8954d584d5200bb6f5c8dd29

5 years agoMove QMMM charge setting to grompp
Paul Bauer [Thu, 20 Dec 2018 13:03:21 +0000 (14:03 +0100)]
Move QMMM charge setting to grompp

Also made sure that the const gmx_mtop_t does not get changed during
QMMM initialization.

Change-Id: I9bec4bbdb22ea6043019e887f8dbe44e7512ced5

5 years agoAdd utility method to NbnxnPairlistGpu
Berk Hess [Fri, 4 Jan 2019 22:09:47 +0000 (23:09 +0100)]
Add utility method to NbnxnPairlistGpu

Change-Id: Ia862c8f719649d1e409f3c433a87b438d248aead

5 years agoRemove now usused GPU alloc/free functions
Berk Hess [Fri, 4 Jan 2019 21:57:35 +0000 (22:57 +0100)]
Remove now usused GPU alloc/free functions

Change-Id: Ifbb424162dd642ecca662ac6a5cb476c24649f0f

5 years agoConvert NbnxnPairlistGpu to C++
Berk Hess [Fri, 4 Jan 2019 17:17:01 +0000 (18:17 +0100)]
Convert NbnxnPairlistGpu to C++

Converted all arrays in NbnxnPairlistGpu to std::vector. There is now
a small initialization overhead when merging lists over threads.
We should recover this by using default initialization.
This change is only refactoring.

Change-Id: Ia811ec1b09ffb9e35ba1a8cf2ef0e64d4006898c

5 years agoRemove init_md and improve init_em
Mark Abraham [Mon, 21 Jan 2019 05:05:09 +0000 (06:05 +0100)]
Remove init_md and improve init_em

These setup functions are adding more complexity in object creation
than they save in avoiding duplication.

Made dedicated simulated annealing setup function. Made dedicated
function for asking for coupling algorithm citations.

Change-Id: Icb3250bf481d430fb76216ef2ed2aec640eaa9a0

5 years agoClean up initialize_lambdas
Mark Abraham [Mon, 21 Jan 2019 05:11:15 +0000 (06:11 +0100)]
Clean up initialize_lambdas

With a little internal cleanup, the calling logic could be made much
simpler, e.g. as lam0 was always provided. Also improved const
correctness and used const inputrec as reference.

Change-Id: I255842b4d0c3cd2c8c648d3ebedc35013992118e

5 years agoConvert gmx_update_t to C++
Kevin Boyd [Sat, 22 Dec 2018 15:21:07 +0000 (10:21 -0500)]
Convert gmx_update_t to C++

gmx_update_t replaced with Update class with pImpled
implementation class

Fixes an end of mdrun leak

Put Update on the stack in mdrun

Moved Update construction out of init_md

Removed unused deform parameters

Change-Id: I1fc98ac1ab7630461a75a8aee1a4af07afa58794

5 years agoConvert nbnxn_atomdata_t to C++
Berk Hess [Fri, 21 Dec 2018 20:49:29 +0000 (21:49 +0100)]
Convert nbnxn_atomdata_t to C++

Changed all manually managed pointer to std::vector.
Split of a Params and a SimdMasks struct.
Changed some data members to be private, more to be done.

This change is ony refactoring, no functional changes.

Note: minor, negligible performance impact of the nbnxn gridding
due to (unnecessary) initialization of std::vector during resize().

Change-Id: I9c70a1f8f272c80a7cf335fcbd867bd79c4102a2

5 years agoRefactor ResidueTypes
Paul Bauer [Mon, 7 Jan 2019 14:46:06 +0000 (15:46 +0100)]
Refactor ResidueTypes

Changed datastructures to C++.
Replaced raw pointers with std::vector and std::string.
Removed unused function in residuetypes.h.

Change-Id: Idb4a5a879545a5de26b13bb8b484cd3debd6fba2

5 years agoAdd tests for gmx mindist
Kevin Boyd [Tue, 15 Jan 2019 02:18:49 +0000 (21:18 -0500)]
Add tests for gmx mindist

Freed up some memory in gmx_mindist

Changed some static variables to normal variables, as
their values were propagating between tests and messing
with the options

Change-Id: Ideb0341659ad2d8a66769e671e1fafadd6ea8d02

5 years agoChange one gmx_mtop_t atom loop to C++
Paul Bauer [Tue, 15 Jan 2019 07:10:24 +0000 (08:10 +0100)]
Change one gmx_mtop_t atom loop to C++

Changed C style struct to C++ class.
Preparation for modernizing atoms datastructure.

Removed a useless gmxassert.h

Refs #2833

Change-Id: I22cfa27bfefc8469b4100a9fef8c11da4d304657

5 years agoMove non-analysis tools from gmxana to gmxpreprocess
Kevin Boyd [Thu, 17 Jan 2019 00:30:15 +0000 (19:30 -0500)]
Move non-analysis tools from gmxana to gmxpreprocess

Renamed genpr to genrestr to align with actual gmx <tool> call

refs #2727

Change-Id: I83a1dc6b39915372c4178768354d334c7e911ae2

5 years agoRemove ctest section called simple
Mark Abraham [Fri, 18 Jan 2019 05:14:28 +0000 (06:14 +0100)]
Remove ctest section called simple

Now that the regressiontests no longer has such a category, we should
not have a ctest section for it.

Refs #1587

Change-Id: I6ea4fea10e01079bf9779b4127faa3f23a8d81d5

5 years agoRemove .travis.yml Travis-CI config file.
M. Eric Irrgang [Thu, 17 Jan 2019 11:31:31 +0000 (14:31 +0300)]
Remove .travis.yml Travis-CI config file.

Fixes #2836

Change-Id: Id413c51596dddb230c4b41f4a66673da21322543

5 years agoChange ResidueTypes to class
Paul Bauer [Fri, 11 Jan 2019 15:21:59 +0000 (16:21 +0100)]
Change ResidueTypes to class

Changes implementation to class with private implementation pointer.

Change-Id: Ia623a23e32ca95a00460c536e2868106b32ad7f9

5 years agoAllow multiple coordinate sets in listed_forces test.
David van der Spoel [Mon, 14 Jan 2019 19:41:13 +0000 (20:41 +0100)]
Allow multiple coordinate sets in listed_forces test.

Part of #2795

Change-Id: Idb1a0ec4e8c304d2f2d865f6feac5d026b1f2393

5 years agoMoved one regressiontest to core gromacs.
David van der Spoel [Sun, 9 Dec 2018 08:56:30 +0000 (09:56 +0100)]
Moved one regressiontest to core gromacs.

Added an md-vv test one.

Part of #2795

Change-Id: Icd33655abca39c47b6735f2d3a1b185e7eff2edb

5 years agoRemove several unnecessary things
Mark Abraham [Tue, 15 Jan 2019 19:37:41 +0000 (20:37 +0100)]
Remove several unnecessary things

More modern cmake requirements mean we don't need to
include some files.

Some TODO comments cannot be addressed in the forecast manner

Simplified some code

Refs #2505, #2831

Change-Id: I3593a072da0ece9b993c7f531ae43fd9fff4afc2

5 years agoRename HostVector to PaddedHostVector
Berk Hess [Tue, 15 Jan 2019 09:17:57 +0000 (10:17 +0100)]
Rename HostVector to PaddedHostVector

Also renamed HostStdVector to HostVector. This change is done because
we now need the unpadded type more often and this naming is more
consistent.
This change is only renaming, except for gmx_pme_pp.x which is now
without padding as it remained of type HostVector.

Change-Id: If3ba78554dd1ad7ed93d286ced343986690096c1

5 years agoReverted standard ExternalProject for FFTW download
Mark Abraham [Tue, 15 Jan 2019 19:12:49 +0000 (20:12 +0100)]
Reverted standard ExternalProject for FFTW download

Now that our cmake is modern enough, we can use the
simpler code again.

This partly reverts commit dc75f6f.

Change-Id: Ifc1800beba88fc342ac7b8490a51610a035d60c8

5 years agoRequire cmake 3.9.6
Roland Schulz [Sun, 13 May 2018 05:02:19 +0000 (22:02 -0700)]
Require cmake 3.9.6

Allows to use modern OpenMP support. The change will permit further
simplifications and modernization, particularly for CUDA.

Also bump release matrices to conform to new requirements.

Fixes #2505

Change-Id: Ibe92639ac4a0bc9ac615826637aeb6e86af0c6d4

5 years agoRemove raw pointers in index handling
Paul Bauer [Tue, 8 Jan 2019 09:46:50 +0000 (10:46 +0100)]
Remove raw pointers in index handling

Change-Id: I60f841e12e99bd0bd61b4dec176d24f5d2803f1a

5 years agoFix tiny leak in pleasecite.cpp
Kevin Boyd [Sun, 13 Jan 2019 16:04:55 +0000 (11:04 -0500)]
Fix tiny leak in pleasecite.cpp

Change-Id: Iee2846d42a8b843c2e70de2b7f4e33e889fad90a

5 years agoRemove ctest section called kernel
Mark Abraham [Mon, 14 Jan 2019 08:21:02 +0000 (09:21 +0100)]
Remove ctest section called kernel

Now that the regressiontests no longer has such a category, we should
not have a ctest section for it.

Refs #1587
Change-Id: I9871e32dfbde329ca4eceb718a94a7c8a418282a

5 years agoPartial conversion of gmx msd to std::vector
Kevin Boyd [Sun, 7 Oct 2018 16:05:32 +0000 (12:05 -0400)]
Partial conversion of gmx msd to std::vector

Changed raw arrays in the primary struct to vector,
with the exception of Matrix - an STL friendly version
of this is still in the gerrit pipeline

refs #2368

Change-Id: Ic41e6a1f78d53c2d5134e5831536a714b0a38a5b

5 years agoMigrate TPI testing to Verlet scheme
Mark Abraham [Wed, 9 Jan 2019 16:09:50 +0000 (17:09 +0100)]
Migrate TPI testing to Verlet scheme

For now, this also disables TPI testing, since TPI does not yet
support the Verlet scheme. If that gets fixed before this change gets
incorporated, the test should not be disabled.

Refs #2391

Change-Id: I83483bd23a03e9175571f2194dae0df96960e6c7

5 years agoRefactor AtomProperties into C++
Paul Bauer [Tue, 8 Jan 2019 08:59:29 +0000 (09:59 +0100)]
Refactor AtomProperties into C++

Replaced raw pointers with vectors.

Change-Id: Ib1bdfcda9b618a70b5ce06beae1d3e9240e59ef8

5 years agoMSD tests for the -mol option.
David van der Spoel [Sat, 22 Dec 2018 21:33:36 +0000 (22:33 +0100)]
MSD tests for the -mol option.

Had to free some memory as well to make tests pass.
Added basic code for running grompp.

Renamed spc5 files in simulationdatabase that are used
in src/programs/mdrun/tests to tip3p5 since they were
in fact using tip3p and in this manner a conflict with
the gmx_msd tests is avoided.

TODO: re-use the grompp code in moduletest.cpp
from src/programs/mdrun/tests

Part of #2815

Change-Id: I5d5d33f431f1d3089ebaef54b6388348d47ce6e2

5 years agoImprove use of gmxpreprocess headers
Mark Abraham [Wed, 2 Jan 2019 14:02:14 +0000 (15:02 +0100)]
Improve use of gmxpreprocess headers

Less use of typedef struct so that we can have more use of forward
declarations of types.

Less inclusion of headers from headers

Updated stdio.h to cstdio

Localized definition of t_nbparam to the single file it needs to be
in.

Change-Id: I92d2d4e1a9a1bc8062627af45dc606903254803c

5 years agoFix small leak in constraints
Kevin Boyd [Sun, 13 Jan 2019 16:01:38 +0000 (11:01 -0500)]
Fix small leak in constraints

Change-Id: I68370a3cec7d39846c26c46f293fd8855540252d

5 years agoAdd grompp check for usage of "define" field in mdp
Kevin Boyd [Mon, 24 Dec 2018 20:53:17 +0000 (15:53 -0500)]
Add grompp check for usage of "define" field in mdp

Users can misspell the strings specified with -D in the topology. This  now
check that every -D field has a corresponding #ifdef and/or #ifndef and/or
C macro-style text replacement in the topology.

Fixed one unit test with unnecessary define field

refs #1975

Change-Id: Ie6329b234a60dde8efc34fb788e6296f241651ed

5 years agoMake AtomProperties class with Impl
Paul Bauer [Thu, 10 Jan 2019 12:33:34 +0000 (13:33 +0100)]
Make AtomProperties class with Impl

Moved the atomprop structure to a class with the underlying arrays
implementation detail. Changed names to be more descriptive. Changed
functions to be class methods where appropriate.

Change-Id: Iffee0635008567735798d0ad5ac560d0cb1e582a

5 years agoUse enum class for grompp directives
Mark Abraham [Wed, 2 Jan 2019 11:44:40 +0000 (12:44 +0100)]
Use enum class for grompp directives

Now the enum class can be forward declared in header files, so we
lower compilation coupling in a few places. Also moved the enum
definition to a less generic header file, to help get rid of
grompp-impl.h file completely.

Made use of new enumeration helpers. Added a test so that the
enumeration can't be extended without extending the matching name array.

Removed commented code for d_blocktype, which hasn't existed for ages.

Change-Id: If3fdc87f87f95f1a5ee61ae2f9f22218105a49a5

5 years agoAdd helper functionality for safer enumerations
Mark Abraham [Wed, 2 Jan 2019 14:02:39 +0000 (15:02 +0100)]
Add helper functionality for safer enumerations

Also unit tests.

Based on the public-domain code from Guilherme R. Lampert, found on
GitHub at https://github.com/glampert/enum_helpers

Change-Id: I344184fc1852efa9d22a15800e7fb1d6c876aef0

5 years agoAdded low-level tests for improper dihedrals.
David van der Spoel [Wed, 2 Jan 2019 22:11:27 +0000 (23:11 +0100)]
Added low-level tests for improper dihedrals.

Also first try at implementing tests of the free
energy calculations.

Part of #2034

Change-Id: Ie8f244059fcf914d860f57e5f66dc76997904638

5 years agoSplit nbnxn_atomdata_init()
Berk Hess [Wed, 26 Dec 2018 15:21:54 +0000 (16:21 +0100)]
Split nbnxn_atomdata_init()

Extracted the parameter initialization from nbnxn_atomdata_init()
in preparation of extracting the parameters from the struct.
This change is only code motion.

Change-Id: I0cf2dd6e54406f095b7568c8dd92b31d0bc58f74

5 years agoChange grid pointers in nbnxn search to references
Berk Hess [Thu, 20 Dec 2018 20:51:55 +0000 (21:51 +0100)]
Change grid pointers in nbnxn search to references

While modifying the makeClusterList function arguments,
also unified the diagonal exclusion handling so the logic
is in one place instead of 10.

Change-Id: Ia35d56540968843e10f1e9d43f13a8b116b7b759

5 years agoAdd more checks for division by zero
Mark Abraham [Thu, 10 Jan 2019 09:59:31 +0000 (10:59 +0100)]
Add more checks for division by zero

The rotation code was still vulnerable to numerical coincidences of
atom positions and slab centers.

Refs #1587
Refs #1431

Change-Id: If7928825d74226a5b25ed3441e6b6dbdf004115a

5 years agoSplit nbnxn_list_work_t and change to C++
Berk Hess [Thu, 20 Dec 2018 15:00:48 +0000 (16:00 +0100)]
Split nbnxn_list_work_t and change to C++

Split the nbnxn pairlist struct into a CPU and GPU version.
Change most pointers to std::vector. The remaining pointer will be
converted when DefaultInitializationAllocator is available and
NbnxnPairlistGpu is converted to C++.

Change-Id: Idd4c89fc81eef58d78d2431a39b9b547eaf615a2

5 years agoFix string handling in vmdio
Paul Bauer [Wed, 2 Jan 2019 13:35:21 +0000 (14:35 +0100)]
Fix string handling in vmdio

Found another instance of string handling issues reported by gcc-8.

Change-Id: I4d3a63b616e9e327bc2ac199c9c16f379618447f

5 years agoAdd mtop comparison function
Paul Bauer [Wed, 5 Dec 2018 15:33:31 +0000 (16:33 +0100)]
Add mtop comparison function

Added a function to directly compare gmx_mtop_t datastructures and not
go through the conversion to t_topology first when comparing tpr files.

Removed the old function.

Changed some const pointers to const references.

Refs #1862

Change-Id: I3d8c4a1274dee221231b2d4bf2719717c8a6379d

5 years agoUse std::vector in NbnxnPairlistCpu
Berk Hess [Fri, 14 Dec 2018 09:59:26 +0000 (10:59 +0100)]
Use std::vector in NbnxnPairlistCpu

All pointers in NbnxnPairlistCpu have been replaced by std::vector.
This change is only refactoring. The only, local, functionality change
is that during list creation and entry is added to the later and later
removed when empty instead of operating on an entry that is located
one beyond the list size.

Change-Id: I984e879d1f2fa52d74aafc5c4da09c7eefbb99fb

5 years agoFix eioNames
Mark Abraham [Wed, 9 Jan 2019 14:55:33 +0000 (15:55 +0100)]
Fix eioNames

These strings must match the enumeration values

Change-Id: I25e87c2e889c69ee16383b866ed78dcca0c8934c

5 years agoFix uncrustify complaining about files
Paul Bauer [Wed, 9 Jan 2019 10:26:24 +0000 (11:26 +0100)]
Fix uncrustify complaining about files

Change-Id: Id536a42c2f5cf043a48baa5ee2d7822b48353e27

5 years agoClean up thread teardown
Kevin Boyd [Mon, 7 Jan 2019 22:41:24 +0000 (17:41 -0500)]
Clean up thread teardown

Struct freeing had been incomplete

Change-Id: If48f495f64bf880714b26241aa5571f5d487521b

5 years agoAdded DefaultInitializationAllocator
Berk Hess [Tue, 18 Dec 2018 11:00:42 +0000 (12:00 +0100)]
Added DefaultInitializationAllocator

Added an allocator that can be used to default initialize elements
of a std::vector on resize(). This is useful to avoid initialization
in performance critical code.

Change-Id: I65bd52a760c68c73555e8bb9e017de353a6e9a81

5 years agoClean up PME load balancing struct
Kevin Boyd [Mon, 31 Dec 2018 19:46:55 +0000 (14:46 -0500)]
Clean up PME load balancing struct

Changed a c array to vector and removed associated size tracker

Deleted struct when done

Change-Id: I50db40f43c41e36c62f47acd91ced70911591a7e

5 years agoReuse Sphinx environment again
Paul Bauer [Wed, 2 Jan 2019 13:13:55 +0000 (14:13 +0100)]
Reuse Sphinx environment again

Enabled the reuse of the sphinx environment again.
Fixed issue with build order for webpage and manual, and fixed minor
link error in user-guide.

Change-Id: I12c7fa1c2e93c3bcb92db85ba526c8cd65dd6339

5 years agoClean up ekind struct
Kevin Boyd [Mon, 31 Dec 2018 20:07:32 +0000 (15:07 -0500)]
Clean up ekind struct

Changed to unique_ptr in mdrun, rerun, mimic

Changed pointer arrays to vector where possible

Used ArrayRef to refer to vectors in functions

Freed remaining memory leaks in ekind destructor

Change-Id: Ida1ab594334009a9fe22f4bd8d5bc8d9050811e3

5 years agoFinish removing group-scheme all-vs-all support
Mark Abraham [Mon, 7 Jan 2019 01:19:46 +0000 (02:19 +0100)]
Finish removing group-scheme all-vs-all support

These kernels haven't been callable since before GROMACS 4.6

No release notes entry as no functionality is actually changed with
this commit.

Fixes #1095

Change-Id: I3de3b9bbabaafae70fee4e9845880c973e8dc352

5 years agoConvert t_vcm to C++, plugging a memory leak
Kevin Boyd [Sun, 23 Dec 2018 01:13:26 +0000 (20:13 -0500)]
Convert t_vcm to C++, plugging a memory leak

Change init function to constructor

Extract COM log file writing from init to a function

Make do_md owner of t_vcm with unique_ptr

Move initialization of t_vcm out of init_md

Change pointer arrays to vectors where possible. Where not
possible, we now free dynamically allocated resources in destructor.

Change-Id: I711a8d81ec0343969dcb437d9a3b8a474d291e87

5 years agoSplit nbnxn pairlist types for CPU and GPU
Berk Hess [Wed, 31 Oct 2018 22:21:56 +0000 (23:21 +0100)]
Split nbnxn pairlist types for CPU and GPU

Split nbnxn_pairlist_t into NbnxnPairlistCpu and NbnxnPairlistGpu.
Now all members are used in each struct in the respective code paths.
Templated make_nbnxn_pairlist_part on pairlist type.
This change is only refactoring, except for changing an assert
to a release assert.

Note that currently the two list types have some members in common,
but most of those will dissappear in followup changes.

Change-Id: Ic53585066874c4a42539a1b1bc68b756dda3f19e

5 years agoReplace NBNXN_CPU_CLUSTER_I_SIZE by c_nbnxnCpuIClusterSize
Berk Hess [Mon, 17 Dec 2018 14:32:36 +0000 (15:32 +0100)]
Replace NBNXN_CPU_CLUSTER_I_SIZE by c_nbnxnCpuIClusterSize

Change-Id: Id144a1d6bc28f753a2eca055b4f24a1e4239cd2e

5 years agoChange gmx_localtop_t to C++
Paul Bauer [Thu, 13 Sep 2018 12:19:40 +0000 (14:19 +0200)]
Change gmx_localtop_t to C++

Changes the localtop topology structure to C++.

Cases where the object could be allocated on the stack have
been changed in that way. In other places, unique_ptr is now
used for the allocation.

Changed callers that returned a pointer to a new gmx_localtop_t
to instead take a pointer to the datastructure that will be
populated.

gmx_localtop_t is by default managing its own memory, but can be changed
to not do this. This is needed for the domain decomposition as it is not
expected to free memory owned by mtop there.

This is part of the larger aim of modernizing the topology
datastructures to C++.

Changed const pointers to const references where encountered during the
change.

Change-Id: I619533f5dc332332f1652afb24266bc2dae67d4c

5 years agoFix clang 6 warning
Szilárd Páll [Wed, 2 Jan 2019 18:34:28 +0000 (19:34 +0100)]
Fix clang 6 warning

Change-Id: If90d02a5eb93abf2b687f5449f4201138da17ab0

5 years agoFree topology in non-DD simulations
Kevin Boyd [Wed, 2 Jan 2019 01:22:59 +0000 (20:22 -0500)]
Free topology in non-DD simulations

Followup to commit 0926c8a6

Without DD, a number of fields in the localtop are dynamically
allocated and not freed, but functionality existed to free them
that hadn't been called.

Change-Id: I82b8d08234722dfd8d8d3f948512458ee105c5ad

5 years agoMerge branch release-2019
Mark Abraham [Wed, 2 Jan 2019 10:56:32 +0000 (11:56 +0100)]
Merge branch release-2019

Change-Id: I71d9bc751e14f821392f802ee9222b864f1e69b6

5 years agoPrepare for 2019.1
Paul Bauer [Mon, 31 Dec 2018 11:26:26 +0000 (12:26 +0100)]
Prepare for 2019.1

Change-Id: Ibdf643605a1fb6e7054d39a35f1a90b794bd5c3e

5 years agoGROMACS 2019 release
Paul Bauer [Fri, 14 Dec 2018 13:43:01 +0000 (14:43 +0100)]
GROMACS 2019 release

Updated regressiontest hash and added release information in docs.

Change-Id: I69baae6982b58b73161166f9d2c3a397b7efa8b0

5 years agoFix release notes typo
Szilárd Páll [Mon, 31 Dec 2018 15:24:46 +0000 (16:24 +0100)]
Fix release notes typo

Change-Id: Ib8c390f643512e30299db2319b12bb0bdb78815d

5 years agoAdd CUDA CC 7.5 (Turing) support with nvcc
Szilárd Páll [Fri, 21 Dec 2018 19:17:33 +0000 (20:17 +0100)]
Add CUDA CC 7.5 (Turing) support with nvcc

Left commented out code for clang native CUDA build flag generation as
current clang (7.0) does not support sm_75.

Fixes #2814

Change-Id: Ie59c8c887e9d81d7a65136e0445291fd718c88dc

5 years agoOnly report intra-sim communication with multiple ranks
Kevin Boyd [Tue, 25 Dec 2018 01:46:48 +0000 (20:46 -0500)]
Only report intra-sim communication with multiple ranks

Fixes #2807

Change-Id: I01bec8cf9983dc37cd5ad8f29031073c31b2a384

5 years agoMerge branch release-2018 into release-2019
Paul Bauer [Mon, 31 Dec 2018 09:53:50 +0000 (10:53 +0100)]
Merge branch release-2018 into release-2019

Final merge before release of 2019.

Change-Id: I19963b7248095b2f9b6f6425e756218eb82afb93

5 years agoMoved generic simulationdatabase code to testutils.
David van der Spoel [Sun, 30 Dec 2018 16:25:50 +0000 (17:25 +0100)]
Moved generic simulationdatabase code to testutils.

Change-Id: Ib10473efd727d9eb7e296a7d75cdb2a28ad31cce

5 years agoFree more memory in constraints cleanup
Kevin Boyd [Sun, 30 Dec 2018 00:31:52 +0000 (19:31 -0500)]
Free more memory in constraints cleanup

Plug several end-of-MD memory leaks

Change-Id: I54c73723b0b4618eb3747be36ae848fcaa015551

5 years agoMoved input files for tests to simulation database.
David van der Spoel [Sun, 30 Dec 2018 13:16:35 +0000 (14:16 +0100)]
Moved input files for tests to simulation database.

Removed three duplicate files.

Change-Id: I750ce3875d11b5ecd098c58288df9d33c926432f

5 years agoImplemented native normal mode analysis tests.
David van der Spoel [Sat, 8 Dec 2018 17:35:39 +0000 (18:35 +0100)]
Implemented native normal mode analysis tests.

Moved the normal mode analysis tests from the regression
test set to core gromacs.

In order to do so the tests were converted to use the
Verlet scheme which leads to minor changes in the eigenvalues
produced by the normal modes analysis.

Part of #2771

Change-Id: Ice2e4423d8f48f1656aaa296e9207fda3bc4d233

5 years agoChange t_extmass pointers to std::vector
Kevin Boyd [Tue, 18 Dec 2018 03:18:16 +0000 (22:18 -0500)]
Change t_extmass pointers to std::vector

Using std::vector in t_extmass fixes a leak in do_md.

Used arrayRefs to view arrays in NHC_trotter

Refs #2693

Change-Id: I6bd84952fb7a470879ddd665183680c865e22fc2

5 years agoConvert gmx_stochd_t to C++
Kevin Boyd [Thu, 20 Dec 2018 14:43:30 +0000 (09:43 -0500)]
Convert gmx_stochd_t to C++

Changed raw arrays to std::vector

Moved init functionality into constructor

Made owning gmx_update_t use a unique_ptr

Changed functions using struct to take constant references

Change-Id: I3664d9cc2b7e89eba57ad36a89e9c44b7895a7ef

5 years agoUse std::swap in LINCS
Szilárd Páll [Thu, 13 Dec 2018 15:22:19 +0000 (16:22 +0100)]
Use std::swap in LINCS

Change-Id: I1604183ec39cd4f4ff6fdc7b6aecd90dd5efb02e

5 years agoDocument OpenCL timer issue.
Paul Bauer [Fri, 21 Dec 2018 15:04:34 +0000 (16:04 +0100)]
Document OpenCL timer issue.

Refs #2689

Change-Id: I03964cc239aa423713793f5bd0e38d8afe19b0da

5 years agoUse AtomPair for LINCS indexing
Berk Hess [Thu, 13 Dec 2018 11:17:48 +0000 (12:17 +0100)]
Use AtomPair for LINCS indexing

Cleaned up the LINCS atom indexing by adding an AtomPair struct.
Changes name of atom list from bla to atoms.
Also added more variable scope localization.

Change-Id: If665864dc40d4bb039b4806b4a54fe3aeebd98fc

5 years agoThe tests for LINCS and SHAKE constraints.
Artem Zhmurov [Fri, 7 Dec 2018 14:24:30 +0000 (15:24 +0100)]
The tests for LINCS and SHAKE constraints.

The tests for LINCS are first introduced,
SHAKE tests are migrated here from a separate
file.

The tests are performed on simple systems of two
to four bonds as well as on the peptide of three
amino acids. The tests ensure that the final length
of each constrain is equal to the target length.
For the peptide tests with HBonds and AllBonds
constrained, there is an additional check that
the final coordinates of all atoms correspond to the
reference set of values.

Free energy evaluation, virial and velocity constraints
are not yet tested.

Change-Id: Ic3a5c73a7e3223c0b7aafde9a0947e89e611f7b8

5 years agoUse arrayref in LINCS
Berk Hess [Thu, 13 Dec 2018 10:18:15 +0000 (11:18 +0100)]
Use arrayref in LINCS

All pointers have been replaced by gmx::ArrayRef, except for those
uses in SIMD code. Also made all variables scope local and replaced
const pointers by const references.

Change-Id: Ia09c51a1035991034dbaa2cc99a90d1316f3521e

5 years agoUse std::vector for trotter_seq
Kevin Boyd [Tue, 18 Dec 2018 02:37:58 +0000 (21:37 -0500)]
Use std::vector for trotter_seq

Fixes an mdrun leak as well

Change-Id: Ib4c708839cc617353b9b038496f10e1b623e4db7

5 years agoMake all thread-mpi threads release cr structure
Kevin Boyd [Fri, 21 Dec 2018 00:10:46 +0000 (19:10 -0500)]
Make all thread-mpi threads release cr structure

done_commrec had only been called on master thread, leading to
potential leaks

Change-Id: I03215880e9ded9c18dc0642357889f9e469f2a4f

5 years agoRemove unused function declarations in update.h
Kevin Boyd [Sat, 22 Dec 2018 00:22:50 +0000 (19:22 -0500)]
Remove unused function declarations in update.h

These were flagged by Pascal as unused. According to
git blame, the last time these declarations were touched
was in 2013

Change-Id: Ic52e8460d2e3867e6c2ddd2aded034501470feff

5 years agoFix small leaks in do_md cleanup
Kevin Boyd [Mon, 17 Dec 2018 21:43:50 +0000 (16:43 -0500)]
Fix small leaks in do_md cleanup

Change-Id: Ia9a8597e07ab0c45320bfc1d036a99d93d6443d9

5 years agomdspan - basic_mdspan and mdspan declaration
Christian Blau [Tue, 4 Dec 2018 11:53:58 +0000 (12:53 +0100)]
mdspan - basic_mdspan and mdspan declaration

basic_mdspan provides the core functionality for multidimensional array
indexing by combining multidimensional index evaluation, and memory
access.

mdspan is defined as basic_mdspan with wrapped indices, basic_accessor
policy and right-aligned memory layout.

Change-Id: I3eacb734e35a977387c5f023afe636f78ee64eac

5 years agoUse label to select doxygen version
Teemu Murtola [Sun, 23 Dec 2018 19:17:19 +0000 (20:17 +0100)]
Use label to select doxygen version

Change-Id: Ic5276e846867e1dd77250500dcb8693946258e0c

5 years agoFix mdrun -nb GPU on non-gpu builds
Paul Bauer [Fri, 21 Dec 2018 13:03:03 +0000 (14:03 +0100)]
Fix mdrun -nb GPU on non-gpu builds

Added function to check if build supports GPU for nonbonded.

Fixes #2812

Change-Id: I7f907d402dcd7c9f8964d42412125c23c0615909

5 years agoRevert "Removed t_topology from gmx msd"
David van der Spoel [Sat, 22 Dec 2018 13:28:55 +0000 (14:28 +0100)]
Revert "Removed t_topology from gmx msd"

This reverts commit b9e0922af7eccbb4b9110dd0ea99cdac0244a27a.

See #2815

Change-Id: Ie0ae90febf1e170b2c1743ef63b36a567fdabff4

5 years agoRuntime check of device OpenCL support
Szilárd Páll [Tue, 13 Mar 2018 21:40:40 +0000 (22:40 +0100)]
Runtime check of device OpenCL support

This change adds a runtime check of the OpenCL device version support
against the minimum requirement along some minor refactoring.

Fixes #2450

Change-Id: I0622d8f93b97d877d40fbaa65194f0db8442ffd5

5 years agoFix unused parameter warning
Mark Abraham [Sat, 22 Dec 2018 05:31:23 +0000 (06:31 +0100)]
Fix unused parameter warning

bs_mac sometimes doesn't find gettimeofday, and in any
case we should never have such a warning.

Change-Id: Ib425495ef05f4c40f920fa8285cb43c2e6292e57

5 years agoAdd a sanity check for OpenCL devices
Aleksei Iupinov [Tue, 27 Feb 2018 11:20:14 +0000 (12:20 +0100)]
Add a sanity check for OpenCL devices

Introduced some type traits to support RAII types for OpenCL handles,
so that we can safely free resources when responding to OpenCL API
error codes, and do so with usefully descriptive error messages.

The new infrastructure is used to implement a check that an OpenCL GPU
can execute a dummy kernel.

Fixed some broken docs, and updated some function naming for new
style.

Fixes #2420

Change-Id: Id99786d24f77b4b56669b5cfcd3a39aa0116cfca

5 years agoMissing factor of 2 in cos-acceleration
Jiannan Liu [Wed, 19 Dec 2018 00:08:19 +0000 (19:08 -0500)]
Missing factor of 2 in cos-acceleration

The bug was introduced in commit 69470fc4e9fd990eb53b22c17dc7a699c583d126

Last working version is 2016.5

Affected 2018 and 2019

Fixes #2572

Change-Id: Ibad31b0d8cec7c5f4b77a73b1fbab0ff114b50b6

5 years agoImprove nbnxn cjFromCi() function
Berk Hess [Mon, 17 Dec 2018 13:44:06 +0000 (14:44 +0100)]
Improve nbnxn cjFromCi() function

When the nbnxn j-cluster size is smaller than the i-cluster size,
a j-subcluster index is needed. This is now added to the cjFromCi()
function instead of handling it in multiple places in the code.

Change-Id: Ia527938e5b6b7bb73ee42f907ca979bca417e89c

5 years agoFree global_stat at end of do_md
Kevin Boyd [Wed, 19 Dec 2018 01:23:28 +0000 (20:23 -0500)]
Free global_stat at end of do_md

Freeing function existed but hadn't been called. Fixes
small leak

Change-Id: I1ee94ffc345beb0089e6aaa070bdcb0371728311

5 years agoCall wallcycle counter cleanup function
Kevin Boyd [Thu, 20 Dec 2018 23:38:56 +0000 (18:38 -0500)]
Call wallcycle counter cleanup function

Cleans leak from unfreed wallcycle at end of mdrunner

Change-Id: I18c9a4eb961c1480230dda98c02f75e3796aa3b4

5 years agoFix leak in legacymdrunoptions
Kevin Boyd [Fri, 21 Dec 2018 00:37:18 +0000 (19:37 -0500)]
Fix leak in legacymdrunoptions

Free gmx_output_env_t in class destructor

Change-Id: I4eb6520ac56a9469c2949893888bcc2db21b647b

5 years agoFix small leak in forcerec
Kevin Boyd [Wed, 19 Dec 2018 02:08:00 +0000 (21:08 -0500)]
Fix small leak in forcerec

Change-Id: I09890bffdd88eaa5d691bd3584735787e2c626ad

5 years agoMake jenkins own-fftw verify use local tarball
Szilárd Páll [Mon, 17 Dec 2018 21:30:07 +0000 (22:30 +0100)]
Make jenkins own-fftw verify use local tarball

We should not bombard the FFTW servers with downloads, plus these can be
relatively slow too, so use our local ftp server instead.

Change-Id: Id6ccebf0ac1ae6410cd4f7f13f2ff76d275af5d2

5 years agomdspan - basic accessor policy
Christian Blau [Thu, 29 Nov 2018 10:07:03 +0000 (11:07 +0100)]
mdspan - basic accessor policy

Executes the canonical memory access, given a linear index, where memory
index positions from an intial pointer is adressed.

Change-Id: Ia44ccf78e8c9d1604220ebb1636099ebae48cc4a

5 years agomdspan - mapping for right layout
Christian Blau [Tue, 4 Dec 2018 11:10:21 +0000 (12:10 +0100)]
mdspan - mapping for right layout

Introduces a mapping from multdimensional integer space [0...N0) x .. x
[0..Nm) to one-dimensional integers N. In the mdspan context, this will
be used in a later patch to evaluate the memory offset to address
elements in multdimensional arrays.

The layout_right for mdspan, indexes multidimensional arrays with the
fastest changing dimension last, i.e., C-style, row-major for
two-dimensional arrays.

Change-Id: I0f9950bd4a40543c2cad6fe5b2bd668bb42d6784

5 years agoFix CUDA compiled target-device compatibility check
Szilárd Páll [Tue, 18 Dec 2018 00:43:10 +0000 (01:43 +0100)]
Fix CUDA compiled target-device compatibility check

The check that should catch cases where the binary does not contain
suitable code for the otherwise supported GPU architecture was
erroneously called from the initialization which is too late to
actually trigger it as the error that is meant to prevent will be
already triggered when the sanity checker tries to launch the dummy
kernel.
This change moves the check in question into the sanity checking and
keeps the fatal error as this is a rare condition that's unexpected
and typically a result of a misconfiguration at GROMACS build time.

Fixes #2811

Change-Id: I3762f51077a7c7c80b533860758bbab385b8a1fe

5 years agoCorrect CUDA compatibility check
Szilárd Páll [Mon, 17 Dec 2018 23:57:25 +0000 (00:57 +0100)]
Correct CUDA compatibility check

The CUDA compatibility check became ineffective after the deprecation of
Fermi as it could not detect and flag these GPUs correctly as
"incompatible" but instead was throwing a kernel execution error when
trying to launch the sanity checker kernel.

This change does the minimal necessary corrections for the now
deprecated Fermi arch to be correctly detected. As expected, CPU
fallback can now automatically selected (unless the user request a GPU).

Minor refactoring was also necessary, but was kept at minimum.

Fixes #2810

Change-Id: I81bf12cca43a2a5e16d48d9faf4b9fc9627e4452