alexxy/gromacs.git
11 years agoMerge remote-tracking branch 'origin/release-4-6'
Roland Schulz [Sun, 24 Jun 2012 17:35:21 +0000 (13:35 -0400)]
Merge remote-tracking branch 'origin/release-4-6'

Change-Id: I0c181ad8eb86d0cd130ea27b0cd896f5db581ab5

11 years agoMerge "Fix mdp_opt formatting of expanded ensemble" into release-4-6
Michael Shirts [Sun, 24 Jun 2012 17:27:15 +0000 (19:27 +0200)]
Merge "Fix mdp_opt formatting of expanded ensemble" into release-4-6

11 years agoMerge remote-tracking branch 'gerrit/release-4-6'
Teemu Murtola [Sun, 24 Jun 2012 17:00:12 +0000 (13:00 -0400)]
Merge remote-tracking branch 'gerrit/release-4-6'

Moved files added to include/ to src/gromacs/legacyheaders/ and
files added to src/gmxlib/ to src/gromacs/gmxlib/.

Conflicts:
    CMakeLists.txt
    src/config.h.cmakein

Conflicts for files removed from master:
    cmake/gmxTestInlineASM.cmake (resurrected)
    cmake/TestInlineASM_gcc_x86.c (no conflict, resurrected)
    src/gmxlib/CMakeLists.txt
        (changes applied to src/gromacs/CMakeLists.txt and
        src/gromacs/gmxlib/CMakeLists.txt)

Conflicts for files removed from release-4-6:
    src/gromacs/gmxlib/nonbonded/nb_kernel_ia32_sse/*
    src/gromacs/gmxlib/nonbonded/nb_kernel_ia32_sse2/*
    src/gromacs/gmxlib/nonbonded/nb_kernel_ia64_double/*
    src/gromacs/gmxlib/nonbonded/nb_kernel_ia64_single/*
    src/gromacs/gmxlib/nonbonded/nb_kernel_ppc_altivec/*
    src/gromacs/gmxlib/nonbonded/nb_kernel_x86_64_sse/*
    src/gromacs/gmxlib/nonbonded/nb_kernel_x86_64_sse2/*
    src/gromacs/legacyheaders/gmx_sse2_double.h
    src/gromacs/legacyheaders/gmx_sse2_single.h

Change-Id: I6202a89a802a8fd3e1788df95eac408cf60f3456

11 years agoFix mdp_opt formatting of expanded ensemble
Roland Schulz [Sun, 24 Jun 2012 15:07:04 +0000 (11:07 -0400)]
Fix mdp_opt formatting of expanded ensemble

Was introduced with c7a82654f2e. Broke the build of the manual
because dl tag wasn't closed.

Change-Id: I86afd4a2bdc638fb910cb0afa827b3f56447bb36

11 years agoFix illegal usage of MPI_Comm_create
Roland Schulz [Thu, 21 Jun 2012 16:28:36 +0000 (12:28 -0400)]
Fix illegal usage of MPI_Comm_create

Bug was introduced by 8cd25f0d45567
Illegal to call MPI_Comm_create with different group arguments

Change-Id: Ia70f81862fa50b03ab127e8796226369f6732942

11 years agoMerge "Simple patch for openmm_wrapper.cpp" into release-4-6
Christoph Junghans [Fri, 22 Jun 2012 21:04:20 +0000 (23:04 +0200)]
Merge "Simple patch for openmm_wrapper.cpp" into release-4-6

11 years agoFixed gcc inline assembly issue with PIC and older gcc compilers
Erik Lindahl [Thu, 21 Jun 2012 09:38:12 +0000 (11:38 +0200)]
Fixed gcc inline assembly issue with PIC and older gcc compilers

Some gcc versions had problems with the recently introduced inline
assembly for cpuid (clobbering of ebx register), and since we used
a slightly different inline assembly instruction test in cmake we
did not detect it properly. This patch both makes the inline asm
itself much more portable, and we also test with exactly the same
instruction in cmake so we don't set the flag for supporting inline
asm unless we know this instruction works.

Change-Id: Ib479e2706024abb5e3f66d0249291ce55f1257b1

11 years agogmx_dyecoupl: check selected groups from user
Martin Hoefling [Wed, 13 Jun 2012 12:29:24 +0000 (14:29 +0200)]
gmx_dyecoupl: check selected groups from user

check if the user accidentally selected the same group twice. Abort
with error, since this will not produce any meaningful results.

Change-Id: Iace69c473e5f1b815e35d20a39845533297ad208

11 years agoNew CPU detection & AVX/SSE code, removed raw assembly files.
Erik Lindahl [Mon, 28 May 2012 18:54:17 +0000 (20:54 +0200)]
New CPU detection & AVX/SSE code, removed raw assembly files.

Removed all raw assembly files and deprecated altivec support.
Removed support for NASM and other assemblers, and replaced
previous SSE detection code with a new module using CPUID instead.
Added detection for SSE2, SSE4.1, AVX 128-bit with FMA, and AVX 256-bit.
Added Cmake detection of build platform based on CPUID, and output this
to the log file. The executables now compare the compile-time platform
and selected acceleration with the run-time platform and most suitable
acceleration and warns the user if they do not match. The compiler
detection code has also been reordered slightly to produce more readable
warnings when OpenMP is not available, and correctly disable pragma
warnings.

Added intrinsics code and math functions for SSE2, SSE4.1, AVX128/256
both in single and double precision. All math functions and permutation
code have been tested & verified. Single precision math functions are
correct apart from the least significant bit, and double precision has
roughly twice the accuracy.

This has forced me to temporarily disable the SSE & Fortran acceleration.
SSE will be added back soon based on new intrinsics-only kernels currently
in testing, and we will test if Fortran still makes sense then.

Finally, the patch includes a modification to gmx_rmsdist where
a regression issue was introduced recently by using sqrtf() for
the norm function. This caused the intel compiler to produce slightly
different results at high optimization leves, which got evident here.

Closes #926 - Raw assembly code has been removed.
Refs #923 - Old kernels removed, new will be added shortly.
Fixes #914 - Cmake now does architecture-speficic optimization.
Fixes #912, #913
Fixes #857 - We detect rdtscp support with CPUID and use it if possible.
Fixes #750
Closes #537, #574 - Altivec is now deprecated.

Change-Id: Icfca5a940762f8d82ae67b59c65b2d2ac683256d

11 years agoRemove unnecessary "move" on shared pointer
John Eblen [Fri, 15 Jun 2012 21:45:02 +0000 (17:45 -0400)]
Remove unnecessary "move" on shared pointer

Change-Id: I79d2d01307c014f4d40cfffc9dbd04067ed4f0fc

11 years agoSimple patch for openmm_wrapper.cpp
Justin Lemkul [Thu, 7 Jun 2012 00:11:26 +0000 (20:11 -0400)]
Simple patch for openmm_wrapper.cpp

The naming of several variables is changed to be consistent with the
latest free energy changes.  Allows mdrun-gpu to be compiled, which
otherwise fails (as reported on gmx-developers).

Change-Id: I497ba07ee6883ef78d23022450f6c3d971b2127e

11 years agoMerge "Remove unnecessary *-impl.h files."
Christoph Junghans [Fri, 15 Jun 2012 00:29:18 +0000 (02:29 +0200)]
Merge "Remove unnecessary *-impl.h files."

11 years agoUpdates to selection online help.
Teemu Murtola [Fri, 8 Jun 2012 15:44:56 +0000 (18:44 +0300)]
Updates to selection online help.

Some of the help topics were outdated after changes introduced by the
linked Redmine issues (some of them even before that).  Improved the
situation a bit and also did some misc. other documentation fixes.

Related to #656 and #666.

Change-Id: I7f18ca4ad8ce2aa5cd808281bab044253ca77f56

11 years agoRemove unnecessary *-impl.h files.
Teemu Murtola [Thu, 31 May 2012 09:34:02 +0000 (12:34 +0300)]
Remove unnecessary *-impl.h files.

Originally, I put all class declarations in headers, but for private
implementation classes used only from one source file, it just leads to
additional maintenance without much benefit.  Moved such class
declarations to the source files (quite a few private implementation
classes are already declared in the source files).

Removed some unnecessary destructors, and had to adjust some includes,
otherwise this change just copy-pastes code around.

Change-Id: Icfb30f88f593806971746d14e3fc0d9b5e7caa96

11 years agoMerge "Merge branch 'release-4-6'"
Christoph Junghans [Wed, 13 Jun 2012 21:17:35 +0000 (23:17 +0200)]
Merge "Merge branch 'release-4-6'"

11 years agoRenamed TestTemporaryFileManager to TestFileManager
Roland Schulz [Tue, 5 Jun 2012 20:55:36 +0000 (16:55 -0400)]
Renamed TestTemporaryFileManager to TestFileManager

Made utility functions static members of class

Change-Id: I706a9c4b5d6e8fe4f121d1e50d229b03f492e49d

11 years agoTestutils improvements for arrays and parameterized tests
Roland Schulz [Mon, 4 Jun 2012 15:48:58 +0000 (11:48 -0400)]
Testutils improvements for arrays and parameterized tests

- For parameterized tests replace / with _ to have all refdata
  xml files in one folder
- Print index in sequence in error message for value/refValue
  mismatch

Change-Id: Ic593b87f9c1e4cf2ea049044e48a705eca0aa839

12 years agoMerge branch 'release-4-6'
Roland Schulz [Wed, 6 Jun 2012 12:13:00 +0000 (08:13 -0400)]
Merge branch 'release-4-6'

Conflicts:
src/gromacs/gmxlib/dihres.c
src/gromacs/legacyheaders/dihre.h
src/gromacs/mdlib/force.c
src/gromacs/mdlib/mdebin.c
src/gromacs/mdlib/sim_util.c
src/programs/mdrun/md.c

Change-Id: I0c5e6d8e57f9f19da73a81737c3105dcd55488ec
Moved:
     src/mdlib/expanded.c ->
       src/gromacs/mdlib/expanded.c

12 years agoMerging in free energy, exp. ensemble, & andersen t-control to 4.6
Michael Shirts [Tue, 17 Jan 2012 14:51:13 +0000 (09:51 -0500)]
Merging in free energy, exp. ensemble, & andersen t-control to 4.6

Conflicts:
src/gmxlib/mvdata.c
src/gmxlib/txtdump.c
src/kernel/readir.c
src/mdlib/sim_util.c
src/tools/gmx_membed.c
include/mdrun.h
src/kernel/md.c
src/kernel/md_openmm.c
src/kernel/md_openmm.h
src/kernel/runner.c
src/mdlib/minimize.c
src/mdlib/tpi.c
src/tools/gmx_membed.c
src/kernel/md.c

Change-Id: Ide69a8dbfb96072d5c55d0a051dc9db788cbe144

12 years agoMerge release-4-6 into master
Roland Schulz [Sun, 3 Jun 2012 15:45:26 +0000 (11:45 -0400)]
Merge release-4-6 into master

Conflicts:
src/mdlib/CMakeLists.txt
          change applied to src/gromacs/mdlib/CMakeLists.txt
src/tools/gmx_tune_pme.c
  trivial conflict

Moved:
src/mdlib/fftpack.c & src/mdlib/fftpack.h to src/external/fftpack

Fixed paths in COPYING-OTHER and added boost and gtest/gmock.

Moved the copyright header and list of modifications from fftpack.c into
new README file. Reduces modifications to original file.

Fixed header location in src/gromacs/mdlib/gmx_fft_fftpack.c.

Added macros.h to g_tune_pme (fixing missing min/max)

Change-Id: I9324b1695412e21d16bdcb4d2dc316c53356da5f

12 years agothread_mpi C++11 compatible mutex classes
Sander Pronk [Thu, 31 May 2012 09:58:21 +0000 (11:58 +0200)]
thread_mpi C++11 compatible mutex classes

This brings the master branch thread_mpi up to date, and introduces
a C++11 compatible API for mutexes and lock_guards (found in
thread_mpi/mutex.h).

Partially fixes http://redmine.gromacs.org/issues/948

Change-Id: Ibce48ae10e84bedee9fe641b94a21f6674efcd6b

12 years agoMerge release-4-5-patches into release-4-6
Roland Schulz [Fri, 1 Jun 2012 06:24:10 +0000 (02:24 -0400)]
Merge release-4-5-patches into release-4-6

Changes in 4.5 for removed lines/files in 4.6:
Makefile.am
include/domdec.h
include/domdec_network.h

Trivial conflict:
include/types/commrec.h

Fixed GMX_THREADS into GMX_THREAD_MPI for those added in 4.5 in:
        include/mdrun.h
        src/gmxlib/shift_util.c
        src/mdlib/gmx_fft_fftw3.c

Change-Id: Id37bfbbacc945a7cf184fa21313c05e2680e1fba

12 years agoMerge "Use External BLAS/LAPACK by default" into release-4-6
Christoph Junghans [Fri, 1 Jun 2012 06:04:28 +0000 (08:04 +0200)]
Merge "Use External BLAS/LAPACK by default" into release-4-6

12 years agoMerge "Replace our fftpack version with Numpy's version" into release-4-5-patches
Christoph Junghans [Fri, 1 Jun 2012 05:35:50 +0000 (07:35 +0200)]
Merge "Replace our fftpack version with Numpy's version" into release-4-5-patches

12 years agoReplace our fftpack version with Numpy's version
Roland Schulz [Sun, 27 May 2012 18:07:30 +0000 (14:07 -0400)]
Replace our fftpack version with Numpy's version

Fixes incorrect results for vectors with length of multiples of 12

Fixes #946

Change-Id: I9a110de7334cbb96a72d0ced73ade4d55f665fee

12 years agoMore config.h cleanup.
Teemu Murtola [Thu, 31 May 2012 05:01:18 +0000 (08:01 +0300)]
More config.h cleanup.

Remove defines from config.h for standard types:
 - gid_t, never used.
 - uid_t, added an ifdef around the single use, should always be present
   if getuid() is.
 - off_t, was only used if HAVE_FSEEKO was set.

Also removed the code to check these types from CMake, as well as the
detection code for size_t (define already removed in Icc5bba87).

Change-Id: I2835b0bc0a524a30464230d65a2d873b611ed350

12 years agoMake get_libdir() robust when run from build tree.
Teemu Murtola [Wed, 30 May 2012 09:45:38 +0000 (12:45 +0300)]
Make get_libdir() robust when run from build tree.

get_libdir() now uses the share/top/ directory in the original source
tree if the binary is run from the build tree.  Makes it easier to run
tests.  GMXLIB environment variable can still override this detection.

Change-Id: I74a5d3ba5ff02d68e35ab169b5466d411bad2ae1

12 years agoFix use after free in g_anaeig projection code.
Teemu Murtola [Wed, 30 May 2012 04:18:10 +0000 (07:18 +0300)]
Fix use after free in g_anaeig projection code.

PBC removal structure was deleted immediately after it was initialized,
and used afterwards.

Change-Id: I6126967b34e8de289370dede79cc50a9924ac34d

12 years agoFixed some memory leaks.
Teemu Murtola [Wed, 30 May 2012 04:08:06 +0000 (07:08 +0300)]
Fixed some memory leaks.

- gmx_rmpbc_done() is now symmetric to gmx_rmpbc_init() in that it frees
  also the gmx_rmpbc_t pointer.
- gmx_fio_fclose() frees the memory for the removed t_fileio structure.
- gmxfio functions free t_fileio::fn when they free the structure.

Change-Id: I0d2d667d915109f8a2670aea21326d714ae25adb

12 years agoRemoved dependency on windows.h through commrec.h, domdec.h.
Sander Pronk [Tue, 22 May 2012 15:46:37 +0000 (17:46 +0200)]
Removed dependency on windows.h through commrec.h, domdec.h.

Change-Id: If40506b521a4b4690506465a3f421dab93bc9ce6

12 years agoMerge "Revised g_tune_pme" into release-4-6
Christoph Junghans [Tue, 29 May 2012 16:26:52 +0000 (18:26 +0200)]
Merge "Revised g_tune_pme" into release-4-6

12 years agoImprove 'g_ana help'.
Teemu Murtola [Wed, 16 May 2012 06:51:50 +0000 (09:51 +0300)]
Improve 'g_ana help'.

- 'g_ana help' now internally uses the new online help classes.
  Without any additional arguments, it still prints out the list of
  commands, and now also list of additional help topics.
- 'g_ana help <command>' prints help for the given command (the same as
  'g_ana <command> -h' for the trajectory analysis modules).
- 'g_ana help selections <subtopic>' can be used to access the general
  help for selections.

IssueID #666.

Change-Id: Id34044842b297591923bef242a93b4ae1ae9e14e

12 years agoGeneric handling of online help topics.
Teemu Murtola [Fri, 11 May 2012 18:08:47 +0000 (21:08 +0300)]
Generic handling of online help topics.

- Added a few simple classes for handling a tree of help topics
  (src/gromacs/onlinehelp/).
- Rewrote the selection help to use the new classes. Required changing
  the help parser slightly to pass all requested help topics in a single
  call to _gmx_sel_handle_help_cmd(). Although this changes the usage of
  the help slightly, did not yet update the help texts.
- Added a way to specify the bison and flex binaries to use for
  regenerate_parser.sh (useful, e.g., if multiple versions are
  installed).

Related to #666.

Change-Id: I318fc0fc42e4af39734a5aa65a503582302ecdd8

12 years agoAdditional features to TextTableFormatter.
Teemu Murtola [Mon, 14 May 2012 05:13:40 +0000 (08:13 +0300)]
Additional features to TextTableFormatter.

Add possibility to print out a table without a header (if there are no
column titles) and possibility to indent the whole table.
Use the new features for formatting the list of commands in
CommandLineModuleManager.

IssueID #666

Change-Id: I2d5aaceaf1c5545ff3be215d27ec30df38fbacde

12 years agoSeparated string formatting used only for help.
Teemu Murtola [Sat, 12 May 2012 03:17:30 +0000 (06:17 +0300)]
Separated string formatting used only for help.

Moved string formatting routines used only in help printing to
src/gromacs/onlinehelp/ from src/gromacs/utility/format.*.
Also moved one function from cmdlinehelpwriter.cpp to the new file.
Subsequent commits will add more content to the new directory and will
use the same string formatting routines.

Added NOMINMAX define for Windows to avoid min/max macros.

Related to #666.

Change-Id: I9b52012df2fc718bc3d68c697140661a241a1467

12 years agoReorganize linear algebra code.
Teemu Murtola [Mon, 21 May 2012 08:25:44 +0000 (11:25 +0300)]
Reorganize linear algebra code.

- Moved gmx_arpack.* and internal BLAS/LAPACK implementations to
  src/gromacs/linearalgebra/.
- Moved all routines that directly depend on these to the same dir.
  Also moved integrally related routines (sparsematrix.*, mtxio.*).
- Some reformatting of headers.
- Adjusted Doxygen settings to resolve warnings in these files.
- Adjusted #include statements to make things compile.

With this, the internal BLAS/LAPACK/ARPACK is completely hidden within
libgromacs, and these headers don't need to be installed.  Removes
dependency on F77_FUNC (and hence on config.h) from installed headers.
Also makes it possible to hide the BLAS/LAPACK/ARPACK symbols if
necessary (not done in this change), such that Gromacs compiled with the
internal versions could be linked into a program that uses external
BLAS/LAPACK without symbol conflicts.

Change-Id: I9b2b1ea9832e307a29f5c5038afe1af5504223d9

12 years agoMerge "Continuing to fix threading on Cygwin" into release-4-5-patches
Christoph Junghans [Mon, 28 May 2012 23:25:59 +0000 (01:25 +0200)]
Merge "Continuing to fix threading on Cygwin" into release-4-5-patches

12 years agoMerge "Improve gmx::test::CommandLine."
Christoph Junghans [Mon, 28 May 2012 23:16:08 +0000 (01:16 +0200)]
Merge "Improve gmx::test::CommandLine."

12 years agoMerge "Improve analysisdata reference checks."
Christoph Junghans [Mon, 28 May 2012 23:15:34 +0000 (01:15 +0200)]
Merge "Improve analysisdata reference checks."

12 years agoMerge "Move common test code to testutils."
Christoph Junghans [Mon, 28 May 2012 23:14:41 +0000 (01:14 +0200)]
Merge "Move common test code to testutils."

12 years agoMerge "Simplify selection parsing methods signature."
Christoph Junghans [Mon, 28 May 2012 23:13:04 +0000 (01:13 +0200)]
Merge "Simplify selection parsing methods signature."

12 years agoMerge "Option parsing through SelectionOptionManager."
Christoph Junghans [Mon, 28 May 2012 23:11:55 +0000 (01:11 +0200)]
Merge "Option parsing through SelectionOptionManager."

12 years agoMerge "Simpler required selection input from a file."
Christoph Junghans [Mon, 28 May 2012 23:11:21 +0000 (01:11 +0200)]
Merge "Simpler required selection input from a file."

12 years agoMerge "Split option code away from SelectionCollection."
Christoph Junghans [Mon, 28 May 2012 23:10:44 +0000 (01:10 +0200)]
Merge "Split option code away from SelectionCollection."

12 years agoMerge "Merge release-4-6 (commit 'Ic142a690')"
Christoph Junghans [Mon, 28 May 2012 23:09:14 +0000 (01:09 +0200)]
Merge "Merge release-4-6 (commit 'Ic142a690')"

12 years agoMerge "Fixed 'g_ana select' broken by I8806b3e0."
Christoph Junghans [Mon, 28 May 2012 23:07:58 +0000 (01:07 +0200)]
Merge "Fixed 'g_ana select' broken by I8806b3e0."

12 years agoFix editconf real-bool misusage
Roland Schulz [Sun, 27 May 2012 19:26:24 +0000 (15:26 -0400)]
Fix editconf real-bool misusage

Bool variable was declared as real. Caused invalid stack read
in double precision. Could have caused wrong value to be printed
for argument display but couldn't have caused wrong behavior.

Found with AddressSanitizer

Change-Id: I32553b1a898fb3a7f072ae177518dd63fad56dde

12 years agoMerge release-4-6 (commit 'Ic142a690')
Roland Schulz [Sun, 27 May 2012 16:29:15 +0000 (12:29 -0400)]
Merge release-4-6 (commit 'Ic142a690')

This merges changes more than resolving a conflict.
The reason is that Ic142a690 moved the files to a location
not suitable for master.

molfile_plugin.h, vmddlopen.h, vmdio.h, and vmdplugin.h
were in
- "include" before Ic142a690
- "src/gmxlib" after Ic142a690
- "src/gromacs/legacyheaders" in master

Moved all but vmdio.h to "src/external/vmd_molfile"
Moved vmdio.h to "src/gromacs/gmxlib"

Moved vmddlopen.c (in src/gmxlib or src/gromacs/gmxlib) also to
"src/external/vmd_molfile" (was not moved by Ic142a690).

Removed "#ifdef GMX_USE_PLUGINS" from vmddlopen.c
This makes the files in src/external/vmd_molfile identical to
VMD 1.8.6 besides the Copyright notice.

Instead of the #ifdef, only compile vmdio.c and vmddlopen.c if
GMX_USE_PLUGINS is set (in src/gromacs/gmxlib/CMakeLists.txt)

Trivial conflict in:
src/gromacs/mdlib/pull_rotation.c

Change-Id: If9bda639e4f680c09d785b046fc0382c16688beb

12 years agoMerge "added explicit sqrtf to the float version of norm" into release-4-6
David van der Spoel [Sun, 27 May 2012 08:49:56 +0000 (10:49 +0200)]
Merge "added explicit sqrtf to the float version of norm" into release-4-6

12 years agoFix Clang 3.1 warning
Roland Schulz [Sun, 27 May 2012 02:51:05 +0000 (22:51 -0400)]
Fix Clang 3.1 warning

grid_spacing is an integer and thus it was always set to 0

Change-Id: Id10bccdadef8f2630631d638e94bd27d78774536

12 years agoContinuing to fix threading on Cygwin
Mark Abraham [Fri, 25 May 2012 09:45:09 +0000 (19:45 +1000)]
Continuing to fix threading on Cygwin

Fixes #833

Change-Id: I5d577a149ad18b295559f6d87c24dc42bffd281e

12 years agoMake load_vmd_library static
Roland Schulz [Mon, 21 May 2012 18:21:23 +0000 (14:21 -0400)]
Make load_vmd_library static

Was already used only within the same file

Change-Id: I43276424d51021bc8247c04a3c3647f7fc1565f7

12 years agoMade all vmdio headers private
Roland Schulz [Thu, 17 May 2012 22:23:25 +0000 (18:23 -0400)]
Made all vmdio headers private

- Made vmdio struct in trx a pointer
- No need for vmdio to be in the public API

Change-Id: Ic142a6900d0cbc803e8c24139efbfbc072b46c22

12 years agoMerge "fixed [dd] and [TT] typos in documentation of mdrun and gmx_sans" into release-4-6
Roland Schulz [Fri, 25 May 2012 14:47:21 +0000 (16:47 +0200)]
Merge "fixed [dd] and [TT] typos in documentation of mdrun and gmx_sans" into release-4-6

12 years agoMerge "grompp now retains the order of bonds converted to constraints" into release-4-6
David van der Spoel [Fri, 25 May 2012 14:26:50 +0000 (16:26 +0200)]
Merge "grompp now retains the order of bonds converted to constraints" into release-4-6

12 years agofixed [dd] and [TT] typos in documentation of mdrun and gmx_sans
Martin Hoefling [Fri, 25 May 2012 10:09:07 +0000 (12:09 +0200)]
fixed [dd] and [TT] typos in documentation of mdrun and gmx_sans

Change-Id: Ia51f67b2b056f66072875d2c7a366ae4685bf9d4

12 years agoMerge "Fix Clang 3.1 compile error"
Szilárd Páll [Fri, 25 May 2012 09:00:28 +0000 (11:00 +0200)]
Merge "Fix Clang 3.1 compile error"

12 years agoMerge "Fix that sigaction mask wasn't zeroed" into release-4-6
Christoph Junghans [Fri, 25 May 2012 07:17:48 +0000 (09:17 +0200)]
Merge "Fix that sigaction mask wasn't zeroed" into release-4-6

12 years agoFix Clang 3.1 compile error
Roland Schulz [Thu, 24 May 2012 21:57:34 +0000 (17:57 -0400)]
Fix Clang 3.1 compile error

Change-Id: I3cdfed9168c8ea1b1ca29de0efba071e1f73b9e4

12 years agonow mdrun always initializes MPI
Berk Hess [Wed, 23 May 2012 16:23:12 +0000 (18:23 +0200)]
now mdrun always initializes MPI

MPI was only initialized with more than one process. This required
checks everywhere. Now MPI is also initialized with one process.

Change-Id: I4d0f543d5c1ae5a6136a0ba34f0f83ac27604b14

12 years agoMerge "Code cleanup to avoid name collisions" into release-4-6
Teemu Murtola [Thu, 24 May 2012 17:02:36 +0000 (19:02 +0200)]
Merge "Code cleanup to avoid name collisions" into release-4-6

12 years agoImprove gmx::test::CommandLine.
Teemu Murtola [Thu, 24 May 2012 06:39:42 +0000 (09:39 +0300)]
Improve gmx::test::CommandLine.

- Make the class properly copyable for easier use in tests that need to
  manipulate it.
- Make the class manage its memory using std::vector and prevent memory
  leaks if the argv array is modified outside the class (the internal
  state of the class is still not correctly maintained, though).
- Add methods to append arguments.

Needed for #920, but split from the main change to keep it smaller.

Change-Id: I66ebe9d48936d35bce9e0b4fc1d6246d3d5ec07d

12 years agoImprove analysisdata reference checks.
Teemu Murtola [Thu, 24 May 2012 05:12:46 +0000 (08:12 +0300)]
Improve analysisdata reference checks.

The reference checking for AnalysisData objects now supports more
scenarios with multipoint data, i.e., cases where there are point sets
that do not cover all columns.

Supporting changes:
 - Add a TestReferenceChecker::checkPresent() method that allows to
   assign meaning to absence of a reference data item (and to check for
   that).
 - Split common analysisdata XML stylesheet elements to a separate xsl
   file.
 - Add a script for copying the XML stylesheets to the reference data
   directories for easier maintenance.  Master copies of shared
   stylesheets are now kept in src/testutils/.

Needed for #920, but split from the main change to keep it smaller.

Change-Id: I108c013833052c37a4f2e6c73be6161c0dae1c78

12 years agoMove common test code to testutils.
Teemu Murtola [Tue, 22 May 2012 07:14:35 +0000 (10:14 +0300)]
Move common test code to testutils.

- Move test fixture for AbstractAnalysisData classes from analysisdata/
  to testutils/.
- Some renaming to make file and class names more descriptive.
- Move gmx::test::CommandLine from commandline/ to testutils/.

Prerequisite for #920.

Change-Id: I2d4c8aaf87db03fe6c170856ba5b41eae05c483b

12 years agoRevised g_tune_pme
Carsten Kutzner [Tue, 22 May 2012 08:07:42 +0000 (10:07 +0200)]
Revised g_tune_pme

1. Now, g_tune_pme only duplicates mdrun options where necessary,
options not understood by g_tune_pme are simply passed over to mdrun.
2. Users can now set minimum and maximum Coulomb radius iso scaling
factors for rcoulomb and the Fourier grid.
3. As a result of 1 and 2, some cleanup of the code was possible and
unneeded code was removed.
4. For -npme auto, the tool now derives a reasonable number of PME-
only nodes from the .tpr file settings and tests values around this
number.
Change-Id: I88af5d38a61e0409613f5f3fd4272f7f43823f64

12 years agoFix that sigaction mask wasn't zeroed
Roland Schulz [Wed, 23 May 2012 09:30:50 +0000 (05:30 -0400)]
Fix that sigaction mask wasn't zeroed

Change-Id: I84a1f77e6320538730cc367ed722eadf22046a68

12 years agoCode cleanup to avoid name collisions
Roland Schulz [Wed, 23 May 2012 00:30:08 +0000 (20:30 -0400)]
Code cleanup to avoid name collisions

- Adding missing prepropessor guards
- Renaming functions defined using same name as other function
- Removing unused magic.h

Change-Id: I1375097eb7eced2dafb30222c9986ac24f45fb08

12 years agoUse External BLAS/LAPACK by default
Roland Schulz [Tue, 22 May 2012 21:38:12 +0000 (17:38 -0400)]
Use External BLAS/LAPACK by default

Check if Blas/Lapack is available and only use internal
if it isn't found

Updated FindLAPACK to 2.8.8. and included FindBLAS
so that it works without Fortran enabled.

Change-Id: I6d1df8a03196d9c14436d5b70c731d36b4ddf823

12 years agoadded explicit sqrtf to the float version of norm
Szilard Pall [Mon, 21 May 2012 20:33:11 +0000 (22:33 +0200)]
added explicit sqrtf to the float version of norm

Additionally, as inlining is not a concern nowadays, also cleaned up the
code by using iprod in norm.

Change-Id: Iabc237906380f848e16ed158809bf22b1de9ddd0

12 years agoFixed 'g_ana select' broken by I8806b3e0.
Teemu Murtola [Tue, 22 May 2012 03:36:15 +0000 (06:36 +0300)]
Fixed 'g_ana select' broken by I8806b3e0.

The loop for creating the output for -om is now even simpler and easier
to understand.

Change-Id: If1bb1eb09c40562a90effcfffb4da32de28d0a7a

12 years agogrompp now retains the order of bonds converted to constraints
Berk Hess [Mon, 21 May 2012 17:07:09 +0000 (19:07 +0200)]
grompp now retains the order of bonds converted to constraints

With the constraint mdp option grompp used to write tpr files where
the order of the constraints was reversed with respect to the order
of the bonds. This reordering has been removed.

Change-Id: I094c5001ccad1e80f46b61c4fbcfa400fd5c1e74

12 years agore-introduced fix for real/double issue in gmx_density
Berk Hess [Thu, 17 May 2012 22:07:46 +0000 (00:07 +0200)]
re-introduced fix for real/double issue in gmx_density

The float density histogram could overflow for large data sets.
A fix replaced 3 of the 4 pointers to floats by pointers to doubles, leading
to compilation issues. In two steps these replacements were reverted.
Now all 4 pointers have been replaced.

Change-Id: I0d8e38d27ac5c469480ff731ad191d869f5d890f

12 years agoRemove unused defines from config.h, part 3.
Teemu Murtola [Sun, 20 May 2012 18:33:01 +0000 (21:33 +0300)]
Remove unused defines from config.h, part 3.

- C89 defines size_t in stddef.h, even for free-standing
  implementations, we probably don't need to define our own fallback
  (and it probably doesn't work in any case).
- F77_FUNC_, the underscored version is not used anywhere.  Left it's
  definition in CMakeLists.txt as commented.
- TMPI_WINDOWS_NUMA_API, not used in source files nor in CMake.
- HAVE_LIBM and GMX_LARGEFILES, not used in any source file.
- HAVE_?MMINTRIN_H, not used anywhere.
- restrict, not used anywhere, and the check was broken.

Change-Id: Icc5bba87973c7a086a01be486a5785faee4c5cad

12 years agoRemove unused defines from config.h, part 2.
Teemu Murtola [Sun, 20 May 2012 05:40:38 +0000 (08:40 +0300)]
Remove unused defines from config.h, part 2.

Remove defines that were detected in CMake, but never used, not within
the source files nor within CMake.  Some more of this type remain, but
these seem clear.
Also removed TestRetSigType.c, since the related test is already gone.

Change-Id: I219f9d571b9da06844745a735de631d7c3dc33f9

12 years agoRemove unused defines from config.h, part 1.
Teemu Murtola [Sun, 20 May 2012 05:23:56 +0000 (08:23 +0300)]
Remove unused defines from config.h, part 1.

Removed defines that were never used, and neither were they set in
CMake.  Also removed CPLUSPLUS, since it is not used.

Change-Id: I5b1ec59c2cff594a1ff48ff4c888cae84ee9280e

12 years agoSimplify selection parsing methods signature.
Teemu Murtola [Sat, 19 May 2012 06:29:04 +0000 (09:29 +0300)]
Simplify selection parsing methods signature.

Selection parsing methods in SelectionCollection now return the list of
parsed selections instead of using an output variable.  This makes it
more obvious from the signature alone how the methods should be used.
Also, the ability to append to an existing vector was not used in any
code currently (except in tests), and the code to do that with the new
signature is still simple.

Change-Id: I344e4c15367e956b4294d18f56f4da34ccf42e27

12 years agoOption parsing through SelectionOptionManager.
Teemu Murtola [Sat, 19 May 2012 04:58:34 +0000 (07:58 +0300)]
Option parsing through SelectionOptionManager.

Make the rest of interaction between selection option implementation and
SelectionCollection go through SelectionOptionManager, i.e., make
SelectionOptionStorage::convertValue() call a method in
SelectionOptionManager instead of exposing the SelectionCollection
directly.  Cleans up the design a bit.  Also some include clean-up.

Change-Id: I60208a6de4c0f1dd5f89e7728f1e4ce4663c8c7b

12 years agoSimpler required selection input from a file.
Teemu Murtola [Fri, 18 May 2012 18:59:56 +0000 (21:59 +0300)]
Simpler required selection input from a file.

Now a selection file option (-sf) assigns the contents of the file to
required selection option(s) that haven't yet been assigned if it has no
other context.  Main benefit is that a plain '-sf file.dat' (without any
other selection options specified) assigns the contents of file.dat to
required selections, similarly to how it worked in 4.5.

Resolves the main open issue for #656, error message and help
improvements remain.

Change-Id: I6311b548ab21ecf0f489f2743e2750411f86b3ff

12 years agoSplit option code away from SelectionCollection.
Teemu Murtola [Fri, 18 May 2012 08:32:56 +0000 (11:32 +0300)]
Split option code away from SelectionCollection.

Move code required for selection option implementation from
SelectionCollection to a separate SelectionOptionManager class.
Simplified the selection request handling code in the process, but
otherwise this commit mainly moves code around without changing any
functionality (except for small changes required to use the new class
in code using the selections).

This makes the responsibilities in the code clearer, since
SelectionCollection is now completely independent of any options
implementation.  It also simplifies the involved classes, since
the options handling (which will become even more involved with #656)
no longer complicates the core of the selection module.

Related to #656.

Change-Id: Iac24a2f9392c8cc2421edef3f212ddb462e864b3

12 years agoMerge remote-tracking branch 'origin/release-4-6'
Roland Schulz [Fri, 18 May 2012 01:00:16 +0000 (21:00 -0400)]
Merge remote-tracking branch 'origin/release-4-6'

Conflicts:
include/membed.h
src/gromacs/legacyheaders/membed.h
src/kernel/membed.h

All 3 conflicts old names. Renamed to src/programs/mdrun/membed.h
with content of src/kernel/membed.h from 4.6

Change-Id: I64654ce18162fa7887f17a7c565bc5783c3a1238

12 years agoRename BOOL to EBOOL
Roland Schulz [Fri, 18 May 2012 00:00:22 +0000 (20:00 -0400)]
Rename BOOL to EBOOL

- All other ENUM_NAME functions start with E
- BOOL can easily collide with other names (e.g. on Windows)

Change-Id: I6cb9438386dfb0c93299dfc5a161e4294e7834a3

12 years agoMerge "Fixing more clang warnings" into release-4-6
Teemu Murtola [Thu, 17 May 2012 15:15:25 +0000 (17:15 +0200)]
Merge "Fixing more clang warnings" into release-4-6

12 years agomv membed.h from include to src/kernel
Maarten Wolf [Wed, 16 May 2012 08:16:43 +0000 (10:16 +0200)]
mv membed.h from include to src/kernel

,because membed function calls are not part of gmxlib
Created an abstract datatype gmx_membed_t in include/types
mv all struct declaration to file that uses them (membed.c)
made membed init print conditional on MASTER(cr)

Change-Id: I8bb23403415f1c35a31f06c2fb0fae2148ee15f6

12 years agoUtility class for temporary unit testing files.
Teemu Murtola [Wed, 16 May 2012 17:32:04 +0000 (20:32 +0300)]
Utility class for temporary unit testing files.

Added a utility class for constructing unique names for per-test
temporary files and for automatically removing them at test teardown.

Change-Id: I4ddf4a39d399518b8764be0af41bb423269e245c

12 years agoAdd C++ methods for accessing binary name etc.
Teemu Murtola [Mon, 14 May 2012 09:29:05 +0000 (12:29 +0300)]
Add C++ methods for accessing binary name etc.

- Add a ProgramInfo class that can be used to access global information
  about binary name etc. Move some path manipulation code from
  CommandLineModuleManager to the new class, resolving a TODO item.
- Make initialization methods of this class also call the relevant
  methods in statutil.h.
- Call the new initialization methods in unit tests and in g_ana.
- Use the new method for accessing program names in C++ code.
- Fix ShortProgram() such that it does not segfault if
  set_program_name() has not been called (not needed after the above
  changes, but still better this way).
- Add statutil.c methods that use global storage to valgrind suppression
  list.

Change-Id: I74c906aa5188d2dc4f0e1f6edab89e36393724f3

12 years agoRemove libtool-specific hacks from oenv.c.
Teemu Murtola [Mon, 14 May 2012 05:26:58 +0000 (08:26 +0300)]
Remove libtool-specific hacks from oenv.c.

When did I9b54f82a, didn't notice that the same code was duplicated in
oenv.c.

Change-Id: Ic1c8840ee2cbab5229b3e4c7f74ac26b8c6e181a

12 years agoMerge "Merge 'origin/release-4-6' into master"
Roland Schulz [Wed, 16 May 2012 15:56:51 +0000 (17:56 +0200)]
Merge "Merge 'origin/release-4-6' into master"

12 years agoMerge 'origin/release-4-6' into master
Roland Schulz [Fri, 11 May 2012 14:36:02 +0000 (10:36 -0400)]
Merge 'origin/release-4-6' into master

Conflicts:
src/gromacs/genversion.sh
src/kernel/CMakeLists.txt
src/programs/mdrun/mdrun.c
src/programs/mdrun/runner.c

Change-Id: Ifa85592226e84dea08d707ef1a76ee3020ed3bc3

12 years agoFixing more clang warnings
Roland Schulz [Sun, 13 May 2012 03:49:24 +0000 (23:49 -0400)]
Fixing more clang warnings

Change-Id: I1359503f61e1fa003c078c98a99420249b915e9c

12 years agoMerge "Membed code merge from release-4-6"
Teemu Murtola [Tue, 15 May 2012 19:07:36 +0000 (21:07 +0200)]
Merge "Membed code merge from release-4-6"

12 years agoFix clang warning introduced by new clang version.
Teemu Murtola [Mon, 14 May 2012 06:25:48 +0000 (09:25 +0300)]
Fix clang warning introduced by new clang version.

Change-Id: Ic7eede951558237a8f03c3c1b69876848c37d0e7

12 years agoMembed code merge from release-4-6
Maarten Wolf [Fri, 11 May 2012 09:09:07 +0000 (11:09 +0200)]
Membed code merge from release-4-6

After backporting "membed to mdrun" from master to release-4-6
(commit 3dcc9c8d5) code update was necessary to match gromacs
coding standards. After Gerrit approval, these changes are now
merged into master.

Conflicts:
src/programs/mdrun/membed.c
src/tools/gmx_membed.c

Change-Id: Ib1566a677b46e91052f74800dd4f4d16d1bc3b41

12 years agoMerge "Backporting "moving membed to mdrun" from master" into release-4-6
Christoph Junghans [Wed, 9 May 2012 21:08:35 +0000 (23:08 +0200)]
Merge "Backporting "moving membed to mdrun" from master" into release-4-6

12 years agoMerge "Detect module name from symlinks."
Christoph Junghans [Wed, 9 May 2012 20:58:02 +0000 (22:58 +0200)]
Merge "Detect module name from symlinks."

12 years ago[tools] g_sans - add OpenMP based parallelism
Alexey Shvetsov [Tue, 8 May 2012 18:17:50 +0000 (22:17 +0400)]
[tools] g_sans - add OpenMP based parallelism

This commit adds OpenMP based parallelism for
calc_radial_distribution_histogram function

Also it adds check for mcover parameter which should be -1 or (0,1]

Change-Id: Ic14267782c69c25364b69a91719cb451fd8e3a89
Signed-off-by: Alexey Shvetsov <alexxy@omrb.pnpi.spb.ru>
12 years agoSimplify build system for unit tests.
Teemu Murtola [Wed, 9 May 2012 08:11:06 +0000 (11:11 +0300)]
Simplify build system for unit tests.

- Now that gtest and gmock are build from bundled sources, there should
  be no reason to allow disabling just gmock from the tests (at least
  not strong enough reason compared to the complexity it brings to
  writing the tests and maintaining the build system).
- Make libxml2 mandatory for building any unit tests.  Again,
  simplifies the build system significantly.  Even before this change,
  very few of the unit tests were built without libxml2.

Closes #935.

Change-Id: I8ec5552661860ca43a00d70957fd82d69dcdf739

12 years agoDetect module name from symlinks.
Teemu Murtola [Wed, 9 May 2012 07:12:52 +0000 (10:12 +0300)]
Detect module name from symlinks.

This makes it possible to create, e.g., a symlink named g_select and
point it to g_ana; executing the symlink will work exactly like 'g_ana
select'.

Closes #672.

Change-Id: Ia27069466bea19b1203370c35b9ecdacfe0cdd98

12 years agoMerge "Print list of modules with 'g_ana help'."
Christoph Junghans [Tue, 8 May 2012 20:00:08 +0000 (22:00 +0200)]
Merge "Print list of modules with 'g_ana help'."

12 years agoBackporting "moving membed to mdrun" from master
Maarten Wolf [Fri, 27 Aug 2010 12:40:26 +0000 (14:40 +0200)]
Backporting "moving membed to mdrun" from master

commit 1: cherry pick 45181651
Moved g_membed functionality to mdrun
commit 2: cherry pick 21a84994
Moved g_membed functionality to mdrun bug fix
commit 3: cherry pick 34471042
added gmx_membed.c to CMakeLists.txt for mdrun
commit 4: cherry pick 1a72f4c8
membed renaming and adding tools wrapper again
commit 5:
Fixes necessary after membed to mdrun cherry picking
commit 6: cherry pick a52f8c45
bugfix #697 for g_membed
commit 7:
deleted unused code, changed fclose to ffclose in membed.c

Change-Id: Ia3ba001b338cadcadc9b2bf1f4c728c5ffc1414b

12 years agoMerge "Remove g_luck."
Teemu Murtola [Tue, 8 May 2012 11:54:14 +0000 (13:54 +0200)]
Merge "Remove g_luck."