Teemu Murtola [Thu, 7 May 2015 03:59:26 +0000 (06:59 +0300)]
Improve build system for Sphinx
If one switches between various commits that add .rst files to the
documentation, the old ones get left in the sphinx-input/ directory in
the build tree and generate spurious warnings when building the
documentation after switching to a commit where the file no longer
exists.
Make CMake remove the obsolete files. There are still issues if someone
removes or renames a 'gmx' subcommand, but those cases should be rarer
than reorganizing or adding to the manually maintained .rst files.
Use a more reasonable logic for REGRESSIONTEST_MD5SUM.
Change-Id: If3fcef162af1936217ee36238aa1876a110473be
Teemu Murtola [Tue, 28 Apr 2015 18:39:59 +0000 (21:39 +0300)]
Convert developer manual to rst
Convert all of docs/dev-manual/ to reStructuredText and generate the
documentation with Sphinx. Also convert docs/doxygen/lib/doxygen.md and
example files related to that.
The actual text or content has mostly not changed, but some
reindentation and other formatting changes are quite extensive.
The only textual changes are in the top-level pages where the text and
presentation has been altered slightly to make them appear better with
Sphinx. More work is still necessary to get the best possible
organization under Sphinx, but this should be a reasonable first step.
Change-Id: I9c322aca1f39dd3f54f1a6035b06ec298fc95e43
Berk Hess [Thu, 7 May 2015 08:01:26 +0000 (10:01 +0200)]
Removed non-ff atomtypes from oplsaa and charmm27
Removed atom types Cu2+, Fe2+ and SI from oplsaa and charmm27,
since they are not part of the official force fields.
Refs #957.
Change-Id: Ic8ebdbee62b4441184a54a580b83849ba21ca978
Mark Abraham [Fri, 12 Dec 2014 15:56:27 +0000 (16:56 +0100)]
Move GPU implementation to new interface
This prepares for OpenCL implementation by updating the existing
preprocessor-based interface for GPU functions (that has real
implementations with a GPU build and null implementations without).
Some related changes to identifier names, comments and docs.
Renamed
s/ncuda_dev/n_dev/g
s/cuda_dev/dev/g
s/nb_cuda/nb_gpu/g
s/cu_nb/nb/g
s/cu_nbv/gpu_nbv/g
s/cuda_dev_info/gmx_device_info/g
so they were more generic, for when an OpenCL implementation wants to
share the same identifiers. Related, some _gpu_ had to become
_cuda_gpu_ because it will only have a CUDA implementation, other
_cuda_gpu_ had to become just _gpu_, some _cuda_ had to become _gpu_
or _cuda_gpu_. Some CUDA became GPU.
Several CUDA header files are moved from mdlib/nbnxn_cuda to files of
more generic names in mdlib. This is not great either, but
reorganizing the whole nbnxn code into a proper module, perhaps with
submodules is not within the scope of this change.
Updated naming of some data types to be struct gmx_name_t, per
style in Redmine #1490. Used some explicit forward declarations
instead of including files to get them. Removed typedefs for
opaque pointers.
Moved gpu_timing struct from
legacyheaders/types/nbnxn_cuda_types_ext.h to timing/gpu_timing.h, and
the remaining content to mdlib/nbnxn_gpu_types.h. So we no longer
install this internal-use-only header.
The last part of init_interaction_const() in forcrec.cpp is split off,
so that the construction phase can be moved to occur before
init_nb_verlet(), so that the "constants" are known before any JIT
compilation of GPU kernels takes place. Future work will address the
question of handling JIT compilation more flexibly, or in more than
one place (e.g. when things become compile-time constants after PME
tuning).
Converted some Doxygen style to new guidelines, added basic file-level
documentation, updated include guards.
Introduced gpu_set_host_malloc_and_free so the implementation-specific
details can be handled in the implementations.
Change-Id: I888722c92daeccc7f32987d9b6cb15544351b68d
Mark Abraham [Fri, 24 Apr 2015 12:50:35 +0000 (14:50 +0200)]
Add application-clock NVML-based support for Quadro GPUs
Also minor refactoring to eliminate a small amount of duplication that
would have become larger and harder to understand.
Change-Id: I14fe411eff549216e71c684d4743a36ff3bd576a
Mark Abraham [Sun, 19 Apr 2015 12:15:06 +0000 (14:15 +0200)]
Clean up remnants in mdrun
nstlist < 0 is now impossible after the removal of group-scheme
heuristic neighbour-list updates, so remove some output that can no
longer be triggered.
Iterated constraints are no longer implemented, but some things got
left behind in the removal. Removed ekind_save variable from do_md,
and some comments. Removed some brace pairs that made reviewing the
removal of iterative integrators easy, because uncrustify would not
re-indent that patch. It now does that re-indent, but there's no
potential for bugs here.
deviceOptions was used for OpenMM support, but is now unused, so
removed.
GMX_WRITELASTSTEP has never had a way to be defined, so removed the
check for that.
Change-Id: If547b86a5ec05dce3bb591b8d4c6dd052c07c04e
Mark Abraham [Fri, 13 Feb 2015 14:16:02 +0000 (15:16 +0100)]
Add developer docs for new documentation infrastructure
Fix some existing docs to match current implementation.
Change-Id: I5aef6f3127558169a85b4f577f4d4b54ef92c9f0
Teemu Murtola [Thu, 18 Sep 2014 04:57:34 +0000 (07:57 +0300)]
Add section on naming conventions to dev manual
Move content from the wiki, and expand it a bit. There have been no
comments to the contents of the wiki page in the time it has existed, so
just convert all discussion items to direct guidelines, describing the
current state of the code. Add some additional guidelines based on
discussion during review.
Change-Id: I548f907214bb5ca659207aea42b137dd4480cd3d
Mark Abraham [Wed, 18 Mar 2015 16:02:41 +0000 (17:02 +0100)]
First beta release of 5.1
Extended automatic versioning machinery so that a tarball can be built
from the repo without having "-dev" appended to the version string.
Introduced new advanced cache variable to make that work.
Fixed webpage build so that it refers to the real locations of
tarballs for users to download. With that done, simplified the rest of
the webpage build, which was too complex for no real advantage - the
webpage build + download page can be tested without needing sample
tarballs and their md5sums available. Changed md5sum variables to be
advanced/internal cache variables with doc strings. Consolidated the
use of md5sum of regressiontest tarball with that of
tests/CMakeLists.txt, which was set up in cmake/gmxVersionInfo.cmake.
Bumped LIBRARY_SOVERSION and updated policy for related issues.
Fixed other minor documentation issues, including referring readers to
the website for alternative source-code downloads. Not sure why the
checks did not report problems before this patch!
Removed references to tools documentation pages from
install-guide/index.rst because they are not very useful and generate
warning messages from sphinx-build about missing references, and ugly
"*gmx mdrun*" output for the INSTALL file for the tarball.
Fixed setting of GMX_API_VERSION (broken in
643944e7 after the 5.0
fork).
Change-Id: I03ea4abbbfe71afe3bf5d5e489af28cb03bd1f53
Berk Hess [Wed, 22 Apr 2015 08:57:49 +0000 (10:57 +0200)]
Merge branch 'release-5-0'
Trivial conflict resolved in runner.cpp.
Change-Id: I5bf8d6672246938f498fff609a7b0943505d2afb
Szilárd Páll [Sun, 9 Nov 2014 02:33:38 +0000 (03:33 +0100)]
Allow manually setting target GPU architectures
The cmake variables GMX_CUDA_TARGET_SM and GMX_CUDA_TARGET_COMPUTE
allow setting the GPU architectures and virtual architectures,
respectively. If any of these is specified, instead of generating code
for all supported architectures, the compiler will emit binary/PTX code
only for the requested architectures.
This change also reorganizes the gmxManageNvccConfig cmake module
allowing it to handle changes of GMX_CUDA_TARGET's as well as host
compiler changes by regenerating the nvcc flags.
The new variables have been documented in the install guide.
Note that the host compiler consistency checks have not been extended
for >v2.8.10 cmake (which sets it itself), but this could be considered
later.
Change-Id: Iae663f0bffe4342ed17bbdbcd77f4429e6c0a9bd
Magnus Lundborg [Tue, 9 Dec 2014 12:43:16 +0000 (13:43 +0100)]
TNG version 1.7.3
Corresponds to commit
e862ebe8 in the TNG repository.
Large parts of the TNG code have been rewritten to avoid code duplication. Some functions have been combined.
Summary of additional changes (see git log for full details):
Bug fixes:
Fixed bug reading last frame and time of last frame.
Fix MingW build
Fixed bug reading non-particle data.
Check that ZLib is available before using it.
Fixed bug when appending to trajectory.
New functions:
tng_util_num_frames_with_data_of_block_id_get()
Fixed compiler warnings
Improved testing suite
Change-Id: I97334b1d93f21646fe1625e65e5fcdf38a0450d9
Mark Abraham [Tue, 21 Apr 2015 06:48:57 +0000 (08:48 +0200)]
Merge "Merge branch release-5-0"
Berk Hess [Tue, 2 Dec 2014 11:16:59 +0000 (12:16 +0100)]
Add value_ref and value to pull_coord_t
This is only code refactoring.
Change-Id: I64b4cb05f69325a1dd1e17f269894cb538663817
Szilárd Páll [Fri, 23 Jan 2015 14:59:04 +0000 (15:59 +0100)]
define CUDA version and texobj support in config.h
CUDA_VERSION from cuda.h has been used to check CUDA runtime API feature
compatibility which is technically incorrect as this macro represents
the driver API version - although this is identical to the runtime API
version (CUDART_VERSION in cuda_runtime_api.h) in all existing toolkit
releases.
To fix this inconsistency and remove the explicit dependency on a CUDA
header, this change replaces all occurrences of CUDA_VERSION with the
GMX_CUDA_VERSION macro. This is generated from the FindCUDA-detected
major+minor version numbers (nvcc version). This should be equal to the
CUDART_VERSION macro's content. This we now ensure through a consistency
check at cmake-time. Implicitly, this check also ensures that FindCUDA
detected a consistent set of CUDA components (compiler and headers).
Additionally, also moved the declaration of the (former)
TEXOBJ_SUPPORTED macro to config.h
The advantage of moving these macros to config.h is that it eliminates
the risk of missing include or wrong include order.
Also removed some deprecated code used with CUDA <v4.0.
Change-Id: I933bccd48540ba618db2b959764e5ac566e7e12e
Mark Abraham [Thu, 9 Apr 2015 08:55:20 +0000 (10:55 +0200)]
Add comment about Andersen themostat and constraints
Per Michael's request at https://gerrit.gromacs.org/#/c/4479/
Refs #1695
Change-Id: Ibdd0de0e05b6d6be3fba8ba1d29f904b75c4d3c4
Berk Hess [Thu, 16 Apr 2015 16:07:49 +0000 (18:07 +0200)]
Correct -ntmpi auto for intel nehalem and older
With thread MPI mdrun would automatically choose 1 MPI rank with up to
16 OpenMP threads on all Intel family 6 CPUs, whereas this was only
intended for Sandy Bridge and later.
Change-Id: I29882375c8569497b3e309de7cc66a2af4d6fa40
David van der Spoel [Thu, 8 Jan 2015 10:16:27 +0000 (11:16 +0100)]
Updated exponential fitting to make it robust.
The exponential fitting code was not robust under different
data. This is improved by ensuring that e.g. time constants
are always positive. For multi-exponential fits the time constants
are guaranteed to be in increasing order. Rewrote test code.
Added test for error estimation that reproduces 5.0 behavior.
Added new manual section "Curve fitting in GROMACS" (8.6).
General cleanups of the code were done.
Change-Id: Ib72fccf7f85742afeeb3fc0fd6fbd44c1c47795a
Mark Abraham [Thu, 9 Apr 2015 08:41:01 +0000 (10:41 +0200)]
Merge branch release-5-0
Change-Id: Ice890f6d9b0235bc2f07e5c73ee2264a32f18a86
David van der Spoel [Thu, 9 Apr 2015 06:48:59 +0000 (08:48 +0200)]
Clarified comments for time-dependent electric fields.
Change-Id: Id5644a14d6a41ca3d9c634dc0eaefe4069c0b618
David van der Spoel [Wed, 8 Apr 2015 14:13:37 +0000 (16:13 +0200)]
Fixed incorrect output of gb_algorith as sa_algorithm.
Change-Id: I96e51e7c9ac931b7635573a38cd700c61bc596e4
Berk Hess [Wed, 18 Feb 2015 13:37:18 +0000 (14:37 +0100)]
Added pull geometry direction-relative
The new pull geometry direction-relative enables to pull along
a vector defines by two (additional) pull groups.
Change-Id: I210f6bfbd29dcb69664298bab6472919ca88091d
Mark Abraham [Tue, 20 Jan 2015 18:26:20 +0000 (19:26 +0100)]
Update mdrun Doxygen
Define module_mdrun. Added suppression for the observation by make
check-source that this is not consistent with other module naming - we
haven't made a final decision yet.
Move integration test Doxygen to module_mdrun_integration_tests.
Change-Id: I817488a67d37d5edeaf34b7c29067c6b36436aa8
Mark Abraham [Wed, 25 Feb 2015 00:24:09 +0000 (01:24 +0100)]
Made pme_work_t opaque
Introduced pme_init/free_all_work to act on the newly opaque data,
and moved the helper functions that they call to pme-solve.c.
Renamed data type to pme_solve_work_t and field in gmx_pme_t to
solve_work, to help differentiate between the different "work"
structs.
Moved declaration of PME_SIMD_SOLVE to pme-solve.c, since it
is used nowhere else.
The PME work arrays are now allocated by their respective thread.
Change-Id: I02467ac2a4c2e8e6a9c45731ccec248b766609ff
Mark Abraham [Fri, 13 Mar 2015 17:35:42 +0000 (18:35 +0100)]
Initialize n_tricvec field of t_pbc always
Otherwise dump_pbc can segfault when code makes a struct t_pbc on the
stack that coincidentally has n_tricvec > 0.
Change-Id: I3c87b1d006d8ebdab991f20b36690b4b216107f5
Berk Hess [Mon, 29 Sep 2014 14:17:40 +0000 (16:17 +0200)]
Corrected force-switch manual section
There was a factor alpha missing in the formulas for parameter A and B
for the force switch function (the code was correct).
Also removed the introduction and formulas for switching the Coulomb
function, since that's a bad thing to do.
Change-Id: I9739112fc991710199035facde01a1dd2b745703
Erik Lindahl [Wed, 18 Mar 2015 21:38:31 +0000 (14:38 -0700)]
Quote from Szilard's talk at GTC2015
Change-Id: Ib9fe88eb6806204176be057880bbbed122a87296
Mark Abraham [Wed, 18 Mar 2015 16:03:10 +0000 (17:03 +0100)]
Improved man-page machinery
Simplified management of MAN_PAGE_DIR, and reordered code in
docs/CMakeLists.txt to keep similar content together.
Added some comments.
Defaulted to not building help when cross compiling.
Fixes #1700
Change-Id: Ia4c648cbdd38db2881c834c6dd39a500754dec89
Erik Lindahl [Tue, 17 Mar 2015 17:42:20 +0000 (10:42 -0700)]
Quote from Jen-Hsun at the NVIDIA GTC conference 2015
Change-Id: I6b9c1932f451045c269118a494bff6aa6ba35cff
Berk Hess [Mon, 9 Mar 2015 14:45:46 +0000 (15:45 +0100)]
Removed reduction of dH/dl without FE
Removed call to sum_dhdl when not doing free-energy calculations.
This call could take measurable time at high parallelization.
Refs #1694
Change-Id: I268ffea8ea008f20e192c7ce683ce8f6bee9e759
Mark Abraham [Wed, 18 Mar 2015 09:17:43 +0000 (10:17 +0100)]
Made error message more generic
Fixes #1708
Change-Id: Ib246dbd26a158fc7f672a4289fff1a70a46c26db
Mark Abraham [Mon, 16 Feb 2015 18:50:30 +0000 (19:50 +0100)]
Extend Force sub-counters
Need more data for understanding performance variation
Implemented subcounter "restart" and used it for accumulating
position-restraints time with FEP to the position-restraints
subcounter.
Noted TODOs for some future extensions not currently possible.
Also added logfile output from GMX_CYCLE_BARRIER where people
analyzing the performance will see it.
Refs #1686
Change-Id: I9d60d0a683f56549879bb739269e9466c96572c4
Roland Schulz [Tue, 17 Mar 2015 03:27:01 +0000 (20:27 -0700)]
Fix linking with static libxml2
static libxml2 can have a dependency on libz. This uses the same approach
as we did prior for fftw. Always add libz to required libraries (even for
dynamic when not needed) when libz is found.
Change-Id: I75291508d7f36921793e01f920fab644e0324369
Mark Abraham [Sun, 15 Feb 2015 10:08:38 +0000 (11:08 +0100)]
Made GPU warning messages more user friendly
Resolved one of the TODOs
Change-Id: Ia0f1cbe577815e4ca1a92cea81bed98f7f4da5a2
Berk Hess [Wed, 4 Mar 2015 13:57:29 +0000 (14:57 +0100)]
Fixed mdrun fp exception with -debug
A debug printf printed div by 0, which terminated debug builds.
Change-Id: Ia02fded6dac000abece57a138b7b9b1dbc99b63a
Berk Hess [Mon, 9 Mar 2015 16:27:34 +0000 (17:27 +0100)]
Added update x copy-back to update timer
Change-Id: I0f5c17722512e21bbb3cbddd022b1a8769b08595
Berk Hess [Mon, 9 Mar 2015 14:47:49 +0000 (15:47 +0100)]
Reduced cost of Berendsen pressure coupling
The coordinate and box scaling for Berendsen pressure coupling is now
done only every nstpcouple steps. It now also uses OpenMP threading.
Partially solves #1694
Change-Id: Id6abbb7f60960076e683707277ebbe5ff8e75453
Berk Hess [Fri, 14 Nov 2014 14:22:05 +0000 (15:22 +0100)]
Improve threading of bondeds
To reduce the cost of the force reduction, with more than 4 OpenMP
threads the bondeds are now distributed over the threads using
atom indices instead of uniformly.
Moved the bonded thread data initialization to manage-threading.cpp.
Change-Id: Ica5d6fcfb6db1d85058ef9825d0d515a205ee257
Mark Abraham [Fri, 27 Feb 2015 14:02:04 +0000 (15:02 +0100)]
Restore wallcycle subcounter name to "Bonded F"
This makes it easier to check for performance behaviour
Change-Id: Icb67bd75ee58fe280beb9f1cb123d0eeca229f09
Mark Abraham [Tue, 3 Mar 2015 12:29:52 +0000 (13:29 +0100)]
Fix Andersen thermostats
The logic for which type of Andersen thermostat has which
implementation got inverted while implementing support for Random123.
Fixes #1695
Change-Id: Ibb7663160bab0ffbb41e23e0d1e97a151940f47b
Berk Hess [Fri, 20 Feb 2015 15:47:05 +0000 (16:47 +0100)]
Made DD exclusion processing more efficient
With the Verlet scheme exclusions no longer need to be assigned only
once and there are no charge groups. This means the global to local
exclusion conversion can be more than twice as fast.
Change-Id: I80e1213715f051864d2989389212510428896cb8
Berk Hess [Tue, 13 Jan 2015 20:15:21 +0000 (21:15 +0100)]
SIMD acceleration for LINCS
Added SIMD acceleration for the LINCS PBC distance calculation and
the right-hand side of the LINCS matrix equation. The sparse matrix
multiplication and atom updates are not suited for SIMD acceleration.
This uses the SIMD PBC routines that were in bonded.cpp, which have
now been moved to pbcutil/pbc-simd.
SIMD for bondeds can now be switched off at runtime by the usual SIMD
env.vars.
Change-Id: I90b1ca303fc0cfd000cc7b6148f4882e0b4471b6
Berk Hess [Sun, 1 Mar 2015 20:38:07 +0000 (21:38 +0100)]
Allow pull groups of 1 atom with mass 0
Unless constraint pulling is used, a pull group consisting of 1 atom
can have mass 0, since the mass of the COM is irrelevant. This is
useful for pulling on a virtual site.
Also reorganized conditional and loop orders in the COM calculation
code and made many variables local to the scope they are used in.
Change-Id: Ic2950d2db19df8673c0d2e5090ce6e121e45bf2d
Berk Hess [Tue, 26 Aug 2014 12:56:09 +0000 (14:56 +0200)]
COM pulling options per coord, improved cylinder
The COM pull type (potential/constraint), geometry, dimensions
and pull-start can now be set differently for each pull coordinate.
Also added a flat-bottom potential.
Cylinder geometry now uses a smooth radial weight function and
adds radial forces so it now conserves energy.
Fixes #1590.
There is now also an option for printing the COM of the second group,
as well as the reference value for all pull coordinates.
Writing the distance components to the pull coordinate output is now
optional (off by default).
gmx wham currently only supports input with the old restrictions
(and it checks for this). These restrctions should be removed.
Change-Id: I86e443b225accb85cc7fe0aa6c23d937f15b2efb
Roland Schulz [Sat, 28 Feb 2015 21:51:32 +0000 (16:51 -0500)]
Fix GCC5 warnings
Change-Id: I61d2a1f427b12dc2530dd8929d8b90646c1faefc
Mark Abraham [Tue, 20 Jan 2015 11:09:21 +0000 (12:09 +0100)]
Re-implement gmx tune_pme -cpi
The previous implementation just copied mdrun, but that implementation
does things that are more complicated than tune_pme needs, and in turn
slightly complicated the implementation for mdrun.
Change-Id: Idab32148bc04f3a1c62ab78de8f77179e43317aa
Erik Lindahl [Thu, 31 Jul 2014 09:54:55 +0000 (11:54 +0200)]
Added single-accuracy SIMD double math functions
Apart from double SIMD variables typically being
half the width of single, the math functions are
considerably more expensive due to higher-order
polynomials, which can drop the throughput to 25%
of single. In some cases we do not need the full
double precision in SIMD operations, so these
new math functions use double precision
SIMD variables but only target single precision
accuracy, which can improve performance twofold.
The patch also makes the target precision in
single and double SIMD an advanced CMake variable,
and the unit test tolerance is set based on these
variables. This can be used (decided by the user)
for a few platforms where the rsqrt/inv table
lookups provide one bit too little to get by
with a single N-R iteration based on our default
target accuracy of 22 bits.
Change-Id: Id4b1c7800e16cb0eb3d564e89a368b4db6eede3e
Roland Schulz [Thu, 5 Feb 2015 07:14:36 +0000 (02:14 -0500)]
nbnxn utils performance improvement for Phi
Also remove usage of unpack to load half/quarter aligned data, because
in case of misaligned data, instead of SegF it only loaded partial data.
Change-Id: Ib0f7807986e6fcbe998bd6ee41ce104666446321
Berk Hess [Thu, 12 Feb 2015 14:58:11 +0000 (15:58 +0100)]
Fix div by zero in PP/PME ratio
Since we have floating pointing exceptions by default with debug
builds, these no longer ran with separate PME ranks.
Change-Id: I8b15a93901495dbde5dff959001c52ada7414008
Mark Abraham [Tue, 25 Nov 2014 20:23:37 +0000 (21:23 +0100)]
Move mdrun signalling code
No functionality changes here, I just put some related functionality
into functions in their own source file to
* simplify later removing inter-simulation signalling, and
* prepare for further encapsulation later.
Updated struct name and usage for new style. Updated include guards.
Removed now-useless C++-compilation guard from header file. Added
basic Doxygen.
Change-Id: I3ea1e2f77a1cdb6608bba38f08a430cc3b8d7c9a
Mark Abraham [Mon, 5 Jan 2015 08:45:04 +0000 (09:45 +0100)]
Add test that plain multi-simulation works
Refactored replica-exchange tests so that we can test
multi-simulation and replica-exchange separately with
little duplication.
Noted TODO that mdrun -multidir is not tested
Change-Id: Ib531d81103adc2a5b1757ef685c0e23960febdb2
David van der Spoel [Sun, 15 Feb 2015 20:04:48 +0000 (21:04 +0100)]
Updated documentation for electric fields.
Simulations with alternating electric fields have been possible for
8 years without this being documented. Now it is documented.
A please cite call has been added as well.
Change-Id: Iec60972622af3b2f9c7f1009e54e24bbd5600cd2
Berk Hess [Thu, 29 Jan 2015 10:21:18 +0000 (11:21 +0100)]
Added parentheses for casts in SIMD macros
Change-Id: I7b7a2346ad59b19d25be502cfb1c6c82c81a409f
Roland Schulz [Wed, 18 Feb 2015 05:50:21 +0000 (00:50 -0500)]
Don't search installation prefix if binary is not found
It is possible that the binary isn't accessible (e.g. Cray launcher) and it
is not valid to call isEquivalent if the path is invalid.
Change-Id: Idf82a8c951fdc91a2de15d310843d54961ba74eb
Mark Abraham [Sun, 4 Jan 2015 12:32:16 +0000 (13:32 +0100)]
Run replica-exchange tests with MPI enabled
Replica exchange only works with real MPI and at least two ranks. This
can now be handled by ctest, so we can run such tests automatically.
The other integration tests run in MPI mode, but do not place any
requirements upon the number of ranks, so they continue to run in the
usual way.
Fixed the replica-exchange integration tests so that they actually do
run. Changed tests to use mdrun -multi because it is easier to write
the tests that way. (Using mdrun -multidir is problematic, because
grompp needs to write the .tpr file in the subdirectories. When using
mdrun -multi, the only issue is that the name of the .tpr file for
grompp and mdrun is different, because the latter will append the MPI
rank.)
Fixed member variables to conform to naming convention.
Refs #1587
Change-Id: I11dc06f3aac81a80d679b036aef24762e9eec819
Mark Abraham [Sun, 4 Jan 2015 12:27:34 +0000 (13:27 +0100)]
Add infrastructure for running MPI integration tests
Some algorithms need a minimum number of ranks to run meaningfully.
With this patch, ctest acquires the necessary logic that "make tests"
can do the right thing if the MPIEXEC_* variables are set correctly
for the excecution environment.
Added machinery so that integration tests can be written to use
the new logic, but no tests actually do so yet.
Updated install-guide section for the new (and some old)
functionality.
Minor fix to the ordering of mdrun integration test files so that they
match the comments.
Refs #1587
Change-Id: I01b419c10db42e98be708d1d4deffeba34a6d22d
Roland Schulz [Mon, 27 Oct 2014 17:35:46 +0000 (13:35 -0400)]
C++ conversion for PME spread/gather
Noted TODO for future refactoring
Change-Id: Ib130a59a26f124645a3da0fe168d2125e05ac824
Mark Abraham [Tue, 15 Jul 2014 14:40:19 +0000 (16:40 +0200)]
New and reorganized documentation
Covers more mdrun options, moves a bit of "practical" content from the
reference manual to the user guide.
Imported and updated information from wiki page on cutoff
schemes. Consolidated with information from reference manual.
Updated some use of "atom" to "particle" in both guides.
We could update the performance numbers, but with the impending
removal of the group scheme, I don't think that's worth bothering
about. e.g. on Haswell, Erik already tested performance of group is a
bit slower than Verlet, even for unbuffered water systems.
Change-Id: I6410ba9fc08bb133ec8669e14dba11bcbd454fe3
Mark Abraham [Fri, 16 Jan 2015 13:58:24 +0000 (14:58 +0100)]
Add content to user guide
Converted sections on environment variables, mdrun features, mdrun
performance to reStructuredText.
Change-Id: I2a18528729dc6756be093e52e6f87f9df9fe3b94
Mark Abraham [Wed, 8 Oct 2014 17:38:59 +0000 (19:38 +0200)]
Split pme.c into multiple files
Hopefully, this will guide the way for some more internal structure,
so that more structs can become opaque, etc.
Made pme_spline_work_t into opaque struct pme_spline_work. Changed
usage of gmx_pme_t to struct gmx_pme_t, per policy.
Renamed parameters of reuse_pmegrids to avoid "new" being interpreted
by uncrustify as a C++ symbol (also needed for subsequent C++ use).
Noted a TODO for possible future consolidation of serial and threaded
implementations.
Change-Id: I833b8d3e1ec746435de44ba93518e13eb3d5c76b
Mark Abraham [Thu, 15 Jan 2015 23:06:10 +0000 (00:06 +0100)]
Add mdp-options to user guide
Formating changes to create hyperlink targets and index entries using
custom reStructuredText directives. There are likely many
opportunities for cross-references that are not yet implemented.
With some extra effort (not using the convenient add_object_type()), it
should also be possible to remove the integrator= part from references
to mdp values and add customized index entries for them, but with the
current directive and role syntax, that can be done independently from
writing the documentation.
Fixes #1180
Change-Id: Id43cdbe9d3c2faab76fb12ac07abfd88a688dcd6
Berk Hess [Tue, 24 Feb 2015 14:52:06 +0000 (15:52 +0100)]
Fixed parallel distribution and thread count reporting
The domain decomposition no longer prints the atom count for all ranks
(which gets far too long at high parallelization), but rather av,
stddev, min and max.
Corrected the OpenMP thread count print, which often printed 0 thread
for (non-existent) PME ranks.
Fixes #1681, #1685.
Change-Id: Ia0e01c1c458e464ba2469d45c94d9e8c6b85d128
Ake Sandgren [Wed, 18 Feb 2015 12:58:21 +0000 (13:58 +0100)]
The test for HAVE_CXX11_REGEX fails since it doesn't use any -std=c++11 flag.
Moving the test for HAVE_CXX11_REGEX after the gmx_test_cxx11 test makes
this work (if the fix for #1691 is in place)
Fixes #1692
Change-Id: Ic86c17d970c464d6fa287de7bec5fc7616871087
Ake Sandgren [Wed, 18 Feb 2015 12:40:56 +0000 (13:40 +0100)]
Checks should use correct CMAKE_REQUIRED_ variables
CMAKE_REQUIRED_DEFINITIONS is for preprocessor defines,
CMAKE_REQUIRED_FLAGS is for compiler flags. Some of
these have been inherited from CMake; the same fixes
have been applied to CMake trunk.
Fixes #1691
Change-Id: I82def95a3378b12a47a5929774ef076c76d336d7
Erik Lindahl [Wed, 9 Jul 2014 16:37:06 +0000 (18:37 +0200)]
Added AVX-512ER SIMD support
This SIMD architecture adds 28-bit
accuracy table lookups for 1/x and
1/sqrt(x), as well as a 23-bit accurate
version of exp(x). This is likely to
be the first architecture of the Knight's
landing MIC, while standard AVX-512F is
reserved for future Xeon x86 processors.
Just as for the other low-level implementations,
this does not include any kernels and will
not be enabled automatically yet.
Change-Id: I895beda369c1e6aa7d0a08944283036423873a2b
Erik Lindahl [Wed, 9 Jul 2014 13:16:50 +0000 (15:16 +0200)]
Add AVX-512F SIMD support
This adds cpuid detection for AVX-512F and the
low-level SIMD implementation. It is not yet present
in any shipping hardware, but the knights landing
version of Intel MIC will be the first CPU to support
it, as well as future generations of their normal
x86 CPUs (i.e., it merges MIC and x86 SIMD). The
implementation currently only works with icc, and
passes unit tests in the Intel SDE emulator. Some kernel
kernel support functions are not yet implemented, and
the instruction set will not be enabled automatically yet.
Change-Id: I2afa7ac2c1cf29577041c9dfefeb323b86f540c3
Erik Lindahl [Fri, 20 Feb 2015 21:30:32 +0000 (22:30 +0100)]
Famous quote from Colleen McCullough
Change-Id: I951d01208d15deccdeed48d044bebd07dde87a07
Erik Lindahl [Fri, 20 Feb 2015 20:47:57 +0000 (21:47 +0100)]
Added two pop-culture quotes from Andy Warhol.
Change-Id: I94a165f913de821438310e21858d92fa0d2806e2
Mark Abraham [Sun, 15 Feb 2015 18:24:50 +0000 (19:24 +0100)]
Reenable SIMD for R-B dihedrals
Fixes #1686
Change-Id: If612a5afde4bcfd55319d2b6e38b521aa43a9973
Erik Marklund [Tue, 6 Jan 2015 22:48:29 +0000 (22:48 +0000)]
gmx hbond no longer removes PBC when none is present
Fixes #1662
Change-Id: Ice934285784ac8b8fd95942a089fb1b65b9ecb51
Mark Abraham [Fri, 13 Feb 2015 18:13:02 +0000 (18:13 +0000)]
Fix mdrun-only build
The GMX_BUILD_ONLY_MDRUN build now does not include
the gmxpreprocess module. Some Verlet-scheme code moved
to mdlib because it it used in mdrun and grompp.
gmx membed uses a utility function otherwise used only in
gmxpreprocess, but the error message it gives is wrong for the gmx
membed context, so I duplicated the function definition for now. Noted
TODOs for future clean up.
Fixes #1683
Change-Id: Ibc1291e88151f8d5befac2b1840a41402272a05f
Teemu Murtola [Tue, 10 Feb 2015 18:48:15 +0000 (20:48 +0200)]
Replace more [BR] with rst bullet lists
Make the console output format rst-style bullet lists nicely, and use
these instead of [BR] tags to create proper bullet lists in program help
texts. The produced output looks much nicer in all the output formats
(including the console) compared to what it was before any rst changes.
Now the number of [BR] tags remaining is relatively low, and can fixed
at some later time.
Change-Id: I8d74f1a8f3a338202ab901d28f608a8c25794f19
Teemu Murtola [Mon, 9 Feb 2015 16:08:24 +0000 (18:08 +0200)]
Replace some [BR] in help texts with rst literals
[BR] cannot really be implemented in rst, so replace those [BR]
instances that were used to implement literal blocks with rst literal
blocks. Refactor the help output formatting such that line breaks in
the input string get transfered literally to rst output, and make the
console output aware of the line breaks in the input string so that it
can do wrapping as required. Fix cases that do not produce valid rst
now that leading whitespaces are no longer stripped.
As a side effect of this change, remaining [BR] instances in the help
are now somewhat uglier in the console output, but that can hopefully be
fixed in the future. On the other hand, the literal blocks look much
nicer on the html and man pages.
Change-Id: If67106c74f84de04d55a2e8c300949c5a297f909
Teemu Murtola [Sun, 8 Feb 2015 05:22:20 +0000 (07:22 +0200)]
Move flow chart from old-html to Sphinx
Get rid of the remaining HTML page generated from old-html/, and all the
machinery that was there just to generate and link to these pages.
The images used by the flowchart still remain in old-html/ and there is
a target to copy them to the output, but this is significantly simpler
than what it was.
For now, replace the flow chart with raw HTML within rst; using
something like sphinx.ext.graphviz could probably work better.
<td align=...> did not work when embedded into a Sphinx-generate page;
replaced with <td style="text-align:...">.
Change-Id: Icbcccd36a9cc157a5a8efe1e9054d6a6741c83ca
Teemu Murtola [Sat, 7 Feb 2015 18:37:13 +0000 (20:37 +0200)]
Make (most) HTML links to file formats work again
Now most generated program HTML pages again link to file formats where
the file format is mentioned in the help text. With the current
replacement mechanism, it is tricky to get it to work exactly like it
used to before, so now all places that should become links are enclosed
in [REF]/[ref] pairs instead of silently turning any matching text into
a link. This means that some text may no longer be converted into a
link where it should be, but on the other hand, log() in formulas is no
longer converted into a link to the log file format...
This patch only mechanically converted places where [TT].???[tt] was
mentioned into a link (there were no instances of [TT]???[tt]). So any
place where a file format was mentioned without [TT]/[tt] is no longer a
link, but those can be fixed when noticed.
Change-Id: I119d6c0f69ed8c1ecfb12cf1f219a62148ab01e5
Teemu Murtola [Sat, 7 Feb 2015 05:11:25 +0000 (07:11 +0200)]
Convert file format descriptions to rst
Convert the old HTML files about file formats to reStructuredText, and
merge them on a single page. This is more or less a blind conversion.
No attempt is made to make them appear particularly nice, or to fix
outdated information. But this works towards the goal of reducing the
number of distinct document generation mechanisms, and should make it
easier to restore functionality of linking to file formats from
generated pages for programs.
Now the only thing that remains in the old-html directory is the
flowchart.
Change-Id: I88bfbdf48f3ba870c9501ef933c03a947ea43635
Teemu Murtola [Sun, 1 Feb 2015 20:29:40 +0000 (22:29 +0200)]
Generate man pages through Sphinx
Instead of writing direct nroff markup from 'gmx help -export man',
generate the man pages using Sphinx from the same source that is used
for the HTML help. This makes the code a lot more maintainable, and
enables using the same markup everywhere; where necessary for more
flexible formatting, the code can now be simply changed to emit direct
reStructuredText, and that get reasonably formatted in both contexts.
This should allow actually improving the man page contents in the
future.
For man pages, GMX_BUILD_HELP now only controls whether the installation
tries to install man pages or not; they are never built automatically,
as it now takes a substantial amount of time and requires Sphinx that
most people will not have available.
Currently the layout of the man pages (in particular gromacs.7) is not
very nice, but the situation is comparable to what it was earlier.
Change-Id: I3b581933369e573af5cbd614950c2a667a1c6fa4
Teemu Murtola [Sun, 1 Feb 2015 05:25:41 +0000 (07:25 +0200)]
Replace tool HTML help with Sphinx-generated docs
Instead of generating HTML pages directly, make 'gmx help -export rst'
export reStructuredText that is used as input for Sphinx to generate the
help pages as part of the Sphinx documentation. Make other docs refer
to these with a native Sphinx construct :ref:`gmx something`, as it
seems not possible to make `gmx something`_ really work.
:doc:`/programs/gmx-something` works even nicer, but is a bit too much
typing.
Make various minor corrections to existing help documentation so that
they can be converted to rst without errors; the output is still very
ugly in several places (but it wasn't any better in the old HTML...).
This change does not aim to fix all problems; it will probably be easier
once we have more freedom in using different rst constructs.
Links to file formats do not work, but those should be easier to fix
once the file format descriptions are also in rst.
Remove installation of the old share/html/ pages, as there is very
little stuff left there.
Change-Id: Ie9d7f1435656d9cf1f60a7e1c4c3c2e440af227d
Mark Abraham [Fri, 16 Jan 2015 16:37:13 +0000 (17:37 +0100)]
Implemented documentation with sphinx
Added sections for install guide, main file of old online reference,
and stubs, tools and getting-started sections of user guide.
Removed corresponding parts of old documentation.
Remaining markdown files in the user guide will be converted
to rst in other patches.
Refs #1242
Change-Id: I798f57e39eea47301fb51750099d7988d81fc72d
Roland Schulz [Thu, 12 Feb 2015 18:38:31 +0000 (13:38 -0500)]
Merge release-5-0 into master
Change-Id: I23579c289b8a057a94cf64b142759934b9402ee5
Vedran Miletić [Sun, 1 Feb 2015 19:43:19 +0000 (20:43 +0100)]
Fix removal of symlinks created during installation
Installation of gromacs creates 2 symlinks for libgromacs.so, which become
broken once library is removed. During uninstall, CMake macro EXISTS will follow
symlink and conclude files do not have to be removed.
This patch adds IS_SYMLINK checking in addition to EXISTS.
Change-Id: Id7ef6768549a6fc09fb017e5be9ac286e4f7a026
Roland Schulz [Thu, 12 Feb 2015 10:10:31 +0000 (05:10 -0500)]
Merge release-4-6 into release-5-0
Conflicts:
src/gromacs/mdlib/pme.c (just copyright)
Change-Id: I419b260004806229c6eb9f993413b480041f20cc
Berk Hess [Fri, 6 Feb 2015 13:05:44 +0000 (14:05 +0100)]
Re-fixed PME bug with high OpenMP thread count
PME energies and forces could be incorrect with combined MPI+OpenMP
parallelization. This would, only, happen when
pmegrids->nthread_comm[YY] >= 2, which can only occur with high OpenMP
thread count with multiple prime factors that are large wrt the grid.
It's unlikely that this issue affected production runs.
This bug was fixed in
27189bba, but
6ba80a26 broke it again.
Fixes #1572.
Change-Id: Ic01bed4193062f8ca885fcb6bf347f2ef0de909f
Roland Schulz [Wed, 22 Oct 2014 01:23:29 +0000 (21:23 -0400)]
Don't set CFLAGS for Phi in toolchain
The recommended way to set those flags is with CMAKE_*_FLAGS_INIT but
that is only passible in a platform file because those set in a toolchain
file get overwritten.
This fixes that extra CFLAGS passed on the command line don't get ignored.
Also move setting of fftw out of platform file because those should
be project independent.
Change-Id: I5f4d70efd8369bdef5f5060959e3568026d6820c
Roland Schulz [Thu, 5 Feb 2015 06:28:51 +0000 (01:28 -0500)]
Work-around for ICC 15 on Phi
Change-Id: Id72e6fb124974f0d8572a1715bc1f25e536f7c69
Roland Schulz [Thu, 29 Jan 2015 18:04:52 +0000 (13:04 -0500)]
Make FindBoost quite
Prevent boost from printing version on each cmake run. Makes
it consistent with other Find usage (xml, z, ...)
Change-Id: Ic1f99865c68222683b993b13b6e545e66bd7f536
Teemu Murtola [Wed, 28 Jan 2015 20:06:26 +0000 (22:06 +0200)]
Support more complex fixed position selections
Make it possible to create selections like
[0,0,0] plus [0,1,0]
to specify a fixed set of positions. This can be useful at least for
'gmx gangle' to calculate angles from a fixed reference vector.
Such selections were already understood properly by the parser, but
caused various crashes elsewhere in the code. Fixed those crashes by
consistently managing the memory for the involved t_block structures
(always allocate one value in the index array, even if the block is
empty), and by not assuming that a plus-like keyword always has a child
element in the evaluation tree.
Fixes #1619.
Change-Id: I513cddbe882f269ad867c726a54583ee48b41b4d
Berk Hess [Fri, 16 Jan 2015 09:05:14 +0000 (10:05 +0100)]
Re-enabled SIMD for angles and dihedrals
The SIMD acceleration for angles and dihedrals was accidentally
disabled recently during code reorganization, since the SIMD header
file was not includes and thus the SIMD macro was not set.
Fixes #1673
Change-Id: I04ddde71c9dd1a846ecf088a5c973e9a23846a52
Mark Abraham [Thu, 10 Jul 2014 13:06:49 +0000 (15:06 +0200)]
Implement user guide
Renamed former user manual to reference manual.
The content for the new user guide has mostly migrated in from the
wiki, install guide, and mdrun -h, and updated as appropriate. This
guide is intended for documenting practical use, whereas the reference
manual should document algorithms and high-level implementations, etc.
Established references.md to do automatic linking of frequently
used things. This can be automatically concatenated by pandoc
onto any Markdown file to do easy link generation.
Section on mdrun and performance imported and enhanced from the
Acceleration and Parallelization wiki page.
Added section on mdrun features, e.g. rerun and multi-simulation.
Section on getting started imported from online/getting_started.html
and updated - there used to be a tutorial here, but there isn't any
more. Linked to more up-to-date tutorials.
Added TNG to docs/manual/files.tex.
Removed gmx options, now that its content is in the user guide (in
tools.md).
Moved old mdp_opt.html to docs/mdp-options.html, for now. Removed from
reference manual, left pointer to new location. This is not an ideal
format or location either, but it's a step closer to being able to
generate it from the code. Some trivial fixes to content. Generating
links and references to follow in a future commit.
Moved environment-variable section from reference manual to user guide.
Minor fixes here.
Removed superseded reference manual sections on running in parallel or
with GPUs. Renamed install.tex as technical-details.tex, because that
is all that is left there. Moved section on use of floating-point
precision to chapter on definitions and units, and thus eliminated the
former Appendix A.
Cross-references from user-guide.pdf don't work well yet, but that
should be dealt with when we decide on the final publishing platform.
Some TODO comments for documentation sections remain for work in
future patches, but please note the other new content in existing
child patches, so we don't duplicate any work.
Change-Id: I026d67353863ae069c6c45b840a61fcaf205a377
Berk Hess [Mon, 2 Feb 2015 14:11:11 +0000 (15:11 +0100)]
Correct CUDA kernel energy flag
The CUDA kernels calculated energies based on the GMX_FORCE_VIRIAL
flag. This did not cause errors, since (currently) GMX_FORCE_ENERGY
is always set when the virial flag is set. But using the latter flag
gives a small performance improvement when using pressure coupling.
Change-Id: If874e651058dc06c464f0fa810b17ba83146c9a3
Mark Abraham [Mon, 2 Feb 2015 16:06:08 +0000 (17:06 +0100)]
Merge branch release-5-0
Implemented usingGpu() for use by md.cpp in the new rerun behaviour,
because nonbonded_verlet_t is now opaque in master
branch. Unfortunately there is not yet a good home for its
implementation, so it's next to the "constructor" in forcerec.cpp.
Fixed typo in copyright header of gmx_detect_hardware.cpp
Conflicts:
src/gromacs/mdlib/forcerec.cpp
Added gromacs/simd/simd.h to the right place, per fix in release-5-0
src/gromacs/mdlib/tpi.cpp
Added gromacs/simd/simd.h to the right place, per fix in release-5-0
src/programs/mdrun/runner.cpp
Trivial conflict from introducing GPU-usage variables
on line before removal of time variables.
Change-Id: I6157d962d183fae4e6874057da01f44ce10e733c
Mark Abraham [Fri, 23 Jan 2015 14:28:01 +0000 (15:28 +0100)]
Avoid near-silent generation of zero energies
There is note printed about this case for Verlet+GPU+energy groups,
and this is OK for normal simulations because the decomposition of the
energy into groups is unimportant. However, a user doing such a rerun
is probably seeking the energy decomposition, and in that case getting
zeroes is unexpected behaviour.
Instead, default to not using GPUs with mdrun -rerun -nb auto and more
than one energy group. In that case with mdrun -rerun -nb gpu, give a
fatal error and suggest the probable solutions.
Change-Id: I3006ed3ded31620d4faf4fc4a24cc85e9322c5c2
Roland Schulz [Mon, 26 Jan 2015 08:29:13 +0000 (03:29 -0500)]
Fix FP exception in FE
Part of #1677
Change-Id: I212d52a232763e3f3b3652ea488ba5e05683aab1
Mark Abraham [Mon, 19 Jan 2015 10:55:35 +0000 (11:55 +0100)]
Fix use of simd.h
TPI correctness check was inactive.
Use of SIMD preprocessor symbols in forcerec.c was OK because it got
simd.h from nbnxn_simd.h, but also fixed the erroneous use of
transitive inclusion of simd.h just in case that helps someone.
Fixes #1673
Change-Id: Iaf42a4ec420139485de3e509662ca0892fa662c5
Teemu Murtola [Fri, 16 Jan 2015 20:26:44 +0000 (22:26 +0200)]
Add input file options that accept missing files
Add a flag to t_filenm and to FileNameOption that makes input options
not fail when the user-provided file does not exist. Add tests for the
functionality. Use the flag for -cpi option to support using the same
command line for initial and continuation runs.
Fixes #1672.
Change-Id: I62945266ff15449fb153d5153cd550b3a257df69
John Baxter [Thu, 22 Jan 2015 21:33:45 +0000 (14:33 -0700)]
Removes some unnecessary ternary conditionals
In .../src/gromacs/mdlib/minimize.cpp calls to
the evaluate_energy() function.
Details:
The gmx_global_stat_t type argument in calls to
evaluate_energy() use this ternary expression:
evaluate_energy(..., gstat ? gstat : NULL, ...);
However, .../src/gromacs/legacyheaders/sim_util.h
shows gmx_global_stat_t is a typedef equivalent
to struct gmx_global_stat*, a pointer type; since
a pointer is TRUE if and only if it is not NULL,
the following is equivalent:
evaluate_energy(..., gstat, ...);
This patch performs this substitution.
Change-Id: I5bfc50dd8927fe1e797e06144535f61731fb7eb1
Roland Schulz [Fri, 16 May 2014 20:23:11 +0000 (16:23 -0400)]
Workaround for MemorySanitizer
MSan has false positives in qsort (Issue 54) and getlogin_r (83).
Change-Id: Ia63e918b59570e8dfb03222174bf83da24c6e219
Roland Schulz [Tue, 27 Jan 2015 07:04:39 +0000 (02:04 -0500)]
Fix unitlized memory read in checkpoint
Older versions didn't prefix the version string
with VERSION and thus the scanf isn't returning
two fields for those.
Change-Id: I0c8734bd18a62ca5fd6841f2c57fa5a9698bc88c
Teemu Murtola [Sat, 8 Nov 2014 10:39:28 +0000 (12:39 +0200)]
Remove old selection parser error handling code
Now that the parser fully uses exceptions for error handling, the old
mechanism can go, simplifying the code in a few places.
Clean-up for #655.
Change-Id: I92c472a5298e89dce80e022d1e2101d822d90045
Teemu Murtola [Sat, 8 Nov 2014 10:20:25 +0000 (12:20 +0200)]
Improve selection error messages (use exceptions)
Make all selection parsing error handling use exceptions for error
reporting, and improve the understandability and context-sensitivity of
the messages. Make the code in params.cpp exception-safe.
Resolves #655 (except for some pending cleanup of now-unused code).
Change-Id: If7bc1da91041232db23389c660cc2cd9c50addda