alexxy/gromacs.git
10 years agoRemoved ions.itp from GMX/share/top directory.
Rossen Apostolov [Mon, 20 Jan 2014 12:07:36 +0000 (13:07 +0100)]
Removed ions.itp from GMX/share/top directory.

Topologies of the ions should go in the corresponding xxxx.ff/ions.itp
files, there is no need for a top level one.

Change-Id: I9c711b75f494211d9ba86a6b375e8ca69c7a1df2

10 years agoMove command listing to 'gmx help commands'
Teemu Murtola [Sat, 25 Jan 2014 18:07:47 +0000 (20:07 +0200)]
Move command listing to 'gmx help commands'

Instead of printing the list of commands on 'gmx' or 'gmx help', print
it only when explicitly requested with 'gmx help commands'.  This makes
it easier to see the help about the common command line options that
'gmx' accepts.  The list of available help topics lists the 'commands'
topic, so it should be easy to find.

Related to #685.

Change-Id: I00e9ceae15ebd47d2ac129aae8e6e407f86c388a

10 years agoAllocate memory for MD5 on heap
Roland Schulz [Wed, 29 Jan 2014 20:06:39 +0000 (15:06 -0500)]
Allocate memory for MD5 on heap

1MB on stack can cause issues with stack size limits (e.g. MSVC).

Change-Id: I1e9858ae32d78b4d494652f4aaed5354b9276669

10 years agoImproved dependencies on maths includes
Mark Abraham [Mon, 20 Jan 2014 17:57:55 +0000 (18:57 +0100)]
Improved dependencies on maths includes

Our physics.h should have a dependency on our maths header for
PI.

Made explicit some dependencies on system math.h that were being
covered transitively.

Change-Id: I5a35ff10860a84688bfe73260acbd63166f4caec

10 years agoFixes to filename shell completions
Teemu Murtola [Tue, 28 Jan 2014 20:37:21 +0000 (22:37 +0200)]
Fixes to filename shell completions

- When completing a file name, don't add a space after a directory name
  has been completed.
- Don't exclude directory names starting with . from the completions.
  This also excludes ../foobar/.
- Use a more reasonable pattern to match the file names: expect exactly
  one of the acceptable extensions, and at most one .gz/.Z extension.
- Complete directory names for mdrun -multidir.

Issues that remain:
- Completions for paths that contain spaces doesn't really work.
  The only difference to earlier behavior is that now, completing
  something that starts with a " gets an appended space before the
  closing ".
- When completing to subdirectories, the list of possible completions
  shows the subdirectory for each alternative.  This doesn't happen with
  standard bash completion.  Not sure whether this is feasible to fix.

Part of #1410 and #1159.

Change-Id: I1aff3ab89419e0ed4b53bc998c9a50b9a1879e9c

10 years agoUncrustify all files
Roland Schulz [Sat, 18 Jan 2014 04:47:30 +0000 (23:47 -0500)]
Uncrustify all files

Add a script that can be used to do this again if necessary.  The script
also supports listing the files based on the filter attribute, and
checking the copyright; can be extended if/when there is need.

Some manual reformatting in gpu_utils.cu, nbnxn_cuda_data_mgmt.cu, and
nbnxn_cuda_kernel.cuh.  Updated the Sparc kernel generator to generate
code that is invariant under uncrustify, like the other kernels already
do.

Copyright not updated, except for fixing readpull.c such that the script
doesn't complain.

Part of #845

Change-Id: Ia77738ec781f75f1c4e7a264734aac884321f3e5

10 years agoPrint common options to 'gmx -h'
Teemu Murtola [Sat, 25 Jan 2014 05:38:21 +0000 (07:38 +0200)]
Print common options to 'gmx -h'

The help shown for the wrapper binary now includes the command line
options it accepts.  Remaining issues that will be fixed separately:
 - Unlike other help output, this output is actually influenced by what
   the user specifies on the command line.
 - The information is not so easy to find, because of the long list of
   subcommands that comes after it.
 - The information should go to some man page as well.

Related to #685.

Change-Id: Iac72dd21d4a733016b331549e139d4184bd3e283

10 years agoClarified use of table-extension..
Justin Lemkul [Wed, 29 Jan 2014 14:03:30 +0000 (09:03 -0500)]
Clarified use of table-extension..

Following some discussion on gmx-users of the implications of
table-extension, added a clarifying remark in mdp_opt.html for
online and printed manual.  I did not add all of the suggested
fixes, as most were redundant, and this single sentence should
alleviate anything that may have been unclear.

Change-Id: I89bcecee2d0b11149423990f957b7092b0f083b9

10 years agoAutomated Verlet rlist for NVE simulations
Berk Hess [Thu, 9 Jan 2014 12:58:12 +0000 (13:58 +0100)]
Automated Verlet rlist for NVE simulations

NVE simulations with the Verlet scheme will now automatically have
the list buffer set using verlet-buffer-tolerance and the initial
temperature, unless this is zero in which case a 10% buffer is used.
A warning is added for potentially large drift over the simulation.
This change makes empty mdp files valid again.

Change-Id: Iae2d3d8ba212dd9e57783d9fb3d84f7cfc1efdd0

10 years agoMerge "Merge branch 'release-4-6'"
Teemu Murtola [Wed, 29 Jan 2014 05:14:11 +0000 (06:14 +0100)]
Merge "Merge branch 'release-4-6'"

10 years agoMoved random number generator code to separate dir.
David van der Spoel [Sun, 19 Jan 2014 07:51:06 +0000 (08:51 +0100)]
Moved random number generator code to separate dir.

GROMACS sports two random number generators for historical
reason. The oldest one is phased out in this patch.
Changing the random number
generator means that e.g. replica exchange simulations will
not be reproducible (if they ever were in practice).

Change-Id: If24f1019fba9b9412713b5fe04b5c0a8a7638468

10 years agoMerge branch 'release-4-6'
Mark Abraham [Tue, 28 Jan 2014 20:06:13 +0000 (21:06 +0100)]
Merge branch 'release-4-6'

Conflicts:
src/contrib/fftw/CMakeLists.txt
Resolved by merging bump to 3.3.3 and increased variable indirection
from both branches

src/gromacs/legacyheaders/nbnxn_cuda_data_mgmt.h
Resolved with master - both branches have now removed fplog parameter
from the free function

src/gromacs/legacyheaders/sim_util.h
src/gromacs/mdlib/minimize.c
src/gromacs/mdlib/tpi.c
src/programs/mdrun/md.c
These are text clashes between master branch runtime ->
walltime_accounting encapsulation transition, and the recently merged
release-4-6 consolidation of start-time printing. There's no code
clash, though. Resolved by using the code that works consistent with
both refactorings. The call to the print_start function has to follow
the call to the walltime_accounting_start function, of course.

Change-Id: I1559fbadfc15eb7b7e880b17e4519159ba9b534e

10 years agoAllow for "computational electrophysiology" simulations (CompEl)
Carsten Kutzner [Fri, 13 Dec 2013 09:41:57 +0000 (10:41 +0100)]
Allow for "computational electrophysiology" simulations (CompEl)

The basic new functionality is to allow exchanges of molecular
positions, e.g. of an ion with a distant water molecule. Whereas
this could be used for different things, the target application is
to determine electrophysiological properties of membrane channels.
In a double-membrane setup the number of ions, and thus the
charge imbalance, and thus the potential difference between
the two compartments can be controlled and kept constant.
If ionic flow occurs through membrane channels, which
dissipates the charge imbalance, ions can be swapped back
to restore the desired charge imbalance between the
compartments. A continuous flow of ions through the
membrane channels can be established that allows to
measure channel conductance and selectivity for example.

If requested by .mdp file settings, the do_swapcoords() routine
is called in the main MD loop. It checks whether the actual
ion counts deviate from the specified reference values and
restores the reference values by ion/water swaps. It also
reports how many ions of each type pass through which channel.

Most of this functionality is in ./src/gromacs/swap/swapcoords.c,
but there is also some new code scattered over the source tree
allowing for grompp reading of CompEl parameters, writing CompEl
data to checkpoint and letting other programs as g_tune_pme
deal with that.

There is also a section in the Latex manual in the special
section describing the protocol.

Some tests have been added in mdrun/tests/swapcoords.cpp that
at the moment only check whether the CompEl parameters are
understood, whether mdrun exits without error code when
running a CompEl simulation and whether checkpointing works.
Some extras have been added to the MdrunTestFixture
class to handle more mdrun-related filenames.

Added doxygen documentation for the new functions.

Ran uncrustify on all new files for up-to-date copyright headers
and proper code formatting. Also uncrustified tpxio.c and
changed the tpx_version from 95 to 96.

Change-Id: Iffda273fd9f47a43e511e70ecdf849f881e933c1

10 years agocmake: added FFTW_URL to allow easy offline build
Christoph Junghans [Mon, 27 Jan 2014 18:30:52 +0000 (11:30 -0700)]
cmake: added FFTW_URL to allow easy offline build

Change-Id: I9904ce03e0ee1b377e4961c1f8481fc98c10cba4

10 years agoBump own fftw build to version 3.3.3
Rossen Apostolov [Mon, 27 Jan 2014 14:50:32 +0000 (15:50 +0100)]
Bump own fftw build to version 3.3.3

Change-Id: I2a4e6acff97e1895517fd58314a010610c0637f5

10 years agoRemove "gmx trjconv -app"
Mark Abraham [Sat, 11 Jan 2014 20:52:55 +0000 (21:52 +0100)]
Remove "gmx trjconv -app"

This functionality is present in gmx trjcat and should not be
duplicated.

Change-Id: I29657de3f488549e3ce7f708c35be41b705416a3

10 years agoRemove unused fplog
Mark Abraham [Tue, 28 Jan 2014 13:24:31 +0000 (14:24 +0100)]
Remove unused fplog

Keeps gcc 4.8 build happy

Change-Id: I392b02c0950ead04c414dffd6340b364b804b7aa

10 years agoShell completion export from the wrapper binary
Teemu Murtola [Wed, 4 Sep 2013 03:39:16 +0000 (06:39 +0300)]
Shell completion export from the wrapper binary

Bash completions now complete the arguments to the wrapper binary
itself, as well as the subcommand names.  After a subcommand has been
specified, use the existing completion logic.  Completions now work also
for arbitrarily suffixed binaries (which the old system didn't work at
all).  No completion is generated for symlinks, but should be
straightforward to do if really required; approach would be the same as
for GMX_BUILD_MDRUN_ONLY.

Other completions are not working for the wrapper binary, and as far as
I can tell, require a completely different approach. Removed the
non-functional code.

Related to #685 and #1410.

Change-Id: I55b13a65c176dab6e2f4f41bf6e829112c99e6b3

10 years agoUnify logic for timing counts
Mark Abraham [Tue, 28 May 2013 08:35:24 +0000 (10:35 +0200)]
Unify logic for timing counts

Made all integrators use the same logic for starting timing
mechanisms.

Change-Id: Id8cb154f7b96d977efffcc9533d4a6dd9894afbd

10 years agoclarified OpenMP-related things in mdrun help/man
Szilárd Páll [Tue, 26 Feb 2013 22:06:42 +0000 (23:06 +0100)]
clarified OpenMP-related things in mdrun help/man

Added note on OMP_NUM_THREADS/GMX_PME_NUM_THREADS env vars and
improved description on the use-cases when MPI+OpenMP improves
performance.

Change-Id: I904f00c8a4b6907a006b9d4367406d3fa3f3ce42

10 years agoExtend version information output
Teemu Murtola [Mon, 27 Jan 2014 19:57:04 +0000 (21:57 +0200)]
Extend version information output

The output of 'gmx -version' now identifies more configuration options
that have been introduced for 5.0:
- Whether C++11 compilation was enabled when compiling the library.
- What version of Boost was used, and whether that was internal or
  external.
- Whether TNG support was configured in.

Change-Id: I5a00165d1d66d0221e895f9c13c28309b904dafa

10 years agoDon't number a list manually
Mark Abraham [Sat, 11 Jan 2014 20:44:50 +0000 (21:44 +0100)]
Don't number a list manually

There's no point in numbering this list, and the numbers are
about to change, anyway.

Change-Id: I015f931086b52a26e91deb3e18210132f02f392d

10 years agoSimplify ProgramInfo
Teemu Murtola [Sat, 28 Dec 2013 06:35:26 +0000 (08:35 +0200)]
Simplify ProgramInfo

Remove realBinaryName() and invariantBinaryName() from ProgramInfo, as
they were only necessary for the command line module manager.  Instead,
pass the binary name to CommandLineModuleManager constructor and move
the invariant name logic into the manager.  This removes unnecessary
functionality from ProgramInfo, allowing to simplify it further.

Change-Id: I2f18dffcb5dde8e2101376444435bb13daf8c236

10 years agoBreak dependency of fileio on tools
Mark Abraham [Tue, 21 Jan 2014 09:52:04 +0000 (10:52 +0100)]
Break dependency of fileio on tools

The issue fixed in Change-Id: I674d41d contributed to the creation of
poor dependencies while trying to avoid yet other dependencies. This
solution relaxes all the constraints, and fixes the mdrun-only build.

Change-Id: I372d5e390469e99ba2d2a4fb70caf2e9a1c404eb

10 years agoUpdate libxml2 CMake detection
Mark Abraham [Mon, 20 Jan 2014 18:57:19 +0000 (19:57 +0100)]
Update libxml2 CMake detection

find_package doesn't check that the library found can be linked.
Particularly when cross-compiling (observed on Power7 front end to
BlueGene/Q), this can be a problem. We need libxml2 to be reliably
detected in order to know whether we should attempt to build the test
binaries.

Change-Id: Iaf9aa2c9577ed66bd41a03c97c13b6e4d6f493c0

10 years agoBug-fix in long-range correction for LJ-PME
Christian Wennberg [Wed, 22 Jan 2014 08:09:19 +0000 (09:09 +0100)]
Bug-fix in long-range correction for LJ-PME

Missing 1/r in the force, when multiplying with the distance vector in order
to get the direction.

Change-Id: I572706b6066cdeb84a2e574b87d077969e166d8c

10 years agoUse local ProgramInfo in CommandLineModuleManager
Teemu Murtola [Sat, 28 Dec 2013 06:12:47 +0000 (08:12 +0200)]
Use local ProgramInfo in CommandLineModuleManager

Remove all usage of the global ProgramInfo object from
CommandLineModuleManager and the classes it uses.  Instead, use the
local instance.  This allows further refactoring.

Change-Id: I52d930ae4bd6bca8a9b4d12c2d0d66470e56a645

10 years agoMove more preprocessing files into the module
Mark Abraham [Fri, 17 Jan 2014 16:38:47 +0000 (17:38 +0100)]
Move more preprocessing files into the module

This removes the need for the gmx_objlib CMake object library, because
there is no longer random functionality orphaned in src/programs/gmx
(which is there because it was orphaned in src/kernel in release-4-6).

Moved legacyheaders/grompp.h to gmxpreprocess/grompp-impl.h since it
only declared structures that are (now) only used in that module (and
it no longer #includes stdio.h). gmxpreprocess/grompp.h now only
declares gmx_grompp().

Likewise, pdb2gmx, protonate and x2top now have their own
single-function headers.

Removed useless declaration of ncontrol from h_db.h

Removed grompp.h-related useless dependencies, declarations and
definitions from Generalized Born files.

Updated include and added C++ guards for files already within the
module (and new ones). Uncrustified, bumped copyrights

Refs #1415

Change-Id: Ie7967d7d7f61df684d530e3c2d982486a3cd128f

10 years agoFixed wrong message when building own FFTW.
Rossen Apostolov [Mon, 20 Jan 2014 11:46:59 +0000 (12:46 +0100)]
Fixed wrong message when building own FFTW.

Change-Id: I54d26291cce4f8986868f9463ecbc6701f974823

10 years agoFix race conditions
Roland Schulz [Mon, 18 Nov 2013 18:48:58 +0000 (13:48 -0500)]
Fix race conditions

progBal problem didn't cause probles because the value written
to the same value on each thread. mdatom.c (c6/c12) problem
was introduced in commit 1c4ab8dc85d1b.

Change-Id: Ia61d214f82771b181308573e4ae1adac94ce5ffa

10 years agoEnsure we don't #define constants before system headers
Mark Abraham [Mon, 20 Jan 2014 21:07:36 +0000 (22:07 +0100)]
Ensure we don't #define constants before system headers

For whatever reason, some older libc (e.g. as found on BG/Q login
nodes) live life such that they unilaterally #define some of the same
M_* constants that we do. If we ever #include <math.h> after
"gromacs/math/utilities.h" then those constants can differ and cause
compilation errors, because we've double-crossed our own #ifndef
attempts.

Change-Id: I4bd6d80e87489cc6f616ce0fb4260a0ac4f9e111

10 years agoAdded ASPP and GLUP to residuetypes.dat.
Justin Lemkul [Tue, 21 Jan 2014 15:40:36 +0000 (10:40 -0500)]
Added ASPP and GLUP to residuetypes.dat.

CHARMM force fields use this nomenclature for neutral forms of
Asp and Glu, unlike other force fields that use ASPH and GLUH.

Change-Id: Id67ab0bf336d9da5bbd62a68b86e0a79609253d1

10 years agoRemove hidden option to gmx dump
Mark Abraham [Tue, 21 Jan 2014 09:36:45 +0000 (10:36 +0100)]
Remove hidden option to gmx dump

gmx dump -xvg -f a.xtc duplicates gmx traj -ox a.xtc

Change-Id: I674d41de5dec9f99fac41f031be7c65e6bc72246

10 years agoRemove unused split.h
Teemu Murtola [Tue, 21 Jan 2014 04:10:57 +0000 (06:10 +0200)]
Remove unused split.h

The header declared functions that weren't even defined, and no one was
including it or using anyt of the definitions.

Change-Id: I53d3ee3b9bdcdcae3f8de1e1941f75cc310e6412

10 years agoImprove file name option help
Teemu Murtola [Mon, 20 Jan 2014 19:17:42 +0000 (21:17 +0200)]
Improve file name option help

- Add brackets for cases where the file name is actually optional.
- Add [...] for cases where multiple file names can be specified.

As supporting changes, extend the options machinery to be able to get
this information for the options, and fix an issue in the table
formatter that was causing some ugly formatting.

Related to #969.

Change-Id: I5b38d7ac6d7c58c3decce64ddfe60fff0a5797ed

10 years agoRemove various outdated things from the repo
Mark Abraham [Sun, 19 Jan 2014 23:27:20 +0000 (00:27 +0100)]
Remove various outdated things from the repo

RPM spec files can be added back if/when someone wants to work out how
to maintain them automatically.

tpbconv symlink can't work now that it is renamed.

Change-Id: Id9ee11a6a21784f68da462fb600243146a0e7b87

10 years agoRename 'gmx tpbconv' to 'gmx convert-tpr'
Mark Abraham [Sat, 18 Jan 2014 21:31:47 +0000 (22:31 +0100)]
Rename 'gmx tpbconv' to 'gmx convert-tpr'

This should help people find the tool they are looking for, rather
than one that is named for a file format that hasn't been written in
over 5 years. Updated comments and documentation accordingly.

Uncrustified, added copyright headers.

Change-Id: I5c29c30af54b90081cfb44f5b24764c8280c49fa

10 years agoFix test reference data
Teemu Murtola [Mon, 20 Jan 2014 19:06:09 +0000 (21:06 +0200)]
Fix test reference data

Combination of a few different changes getting submitted around the same
time led to test reference data not being up-to-date with what the code
actually produced, without producing any conflicts.

Change-Id: I22f9a43faa3bd88668ba4c655d8d26f2a12089d1

10 years agoRewrite help output from Options
Teemu Murtola [Thu, 17 Oct 2013 03:18:47 +0000 (06:18 +0300)]
Rewrite help output from Options

(Partially) rewrite the way command-line help is printed for an Options
object.  Now man pages and HTML output are supported in addition to
console output.  The console output is formatted in a simpler manner,
since there is no longer any need to cater for user-provided values in
the output.  There is some extra machinery now in cmdlinehelpwriter.cpp,
but left it there as it may still be useful in the future, and it does
structure the code a bit more cleanly.

As an extra bonus, the commandline module should no longer depend on the
selection module.

Things more or less work, but the following could still be addressed,
either in this change or later:
 - Re-add selection option help formatting tests somewhere else.
 - Add unit tests for various things about non-console help formatting.
 - Refactor the way the help information is fetched from OptionInfo
   objects: it would be cleaner to have a single method that returns all
   the information in a struct, instead of multiple virtual methods that
   return different pieces of information, many of which are not
   required for anything else except the help output.
 - Add proper synopsis that lists all the options.

Part of #969.

Change-Id: Iadf1b5df15f278547d5db6407f3e3c689fb88645

10 years agoFix .gitignore of some files
Mark Abraham [Mon, 20 Jan 2014 14:29:23 +0000 (15:29 +0100)]
Fix .gitignore of some files

Rooting "bin" and "lib" means they won't match sub-directories like
src/external/tng_io/src/lib.

I can't think of a good reason to .gitignore "log," whether rooted or
not.

Change-Id: Icf3a2fb54f9519dbb936ceabff290084b66f8711

10 years agoAdd TNG writing and reading support
Magnus Lundborg [Tue, 1 Oct 2013 08:11:00 +0000 (10:11 +0200)]
Add TNG writing and reading support

TNG is never read or written by default, but is available as
a trajectory format. The TNG repo is bundled in the GROMACS
source (commit 35827d2c19db8ad86690be32f33da7470abddf3d).

Tools such as trjconv, trjcat, gmxcheck and gmxdump have partial
support for TNG available. Full support for these tools (even only for
the subset of TNG features that GROMACS might want to use right now)
is currently difficult, because the code and data for existing
trajectory writing is a mess of excess functionality.  This will need
to be revisited when (at least) trjconv is broken up into more parts.

Writing with mdrun -x works (tests included)
Reading with mdrun -rerun works (tests included)
Reading and writing with trjconv works (tests included)
trjconv -n subsets work (tests included)

Reading works from e.g. dump, check, trjconv trjcat.
Writing works from e.g. mdrun trjconv, trjcat.
Some other tools seem to work as well, e.g., g_rms.

Reworked some integration test machinery to do more value-paramterized
tests.

Renamed status variable in gmx_trjconv.c to better reflect its usage
as an opaque trajectory-reading-management object.

Encapsulated gmx_mdoutf_t

Moved content of trajectory_writing_low_level.c to mdoutf.c

The Windows build with GMX_USE_TNG=ON is known to be broken with TNG
files.

Changed .mdp field and code variable names that were specific to XTC
to be more generic, now that there is more than one way to write a
trajectory file with lossy compression. Other associated documentation
updates also.

Change-Id: Ied156d8ad728711e08a0c61db5ee3472b0df39d5

10 years agoFix installed headers
Teemu Murtola [Sun, 19 Jan 2014 05:19:17 +0000 (07:19 +0200)]
Fix installed headers

It was not possible to compile anything against the installed headers
without including the installed legacyheaders/ directory in the include
path (which should not be required).

Change-Id: I2d0a65db8e84a3fc4f4a7fb01b359bf6a7d98cbe

10 years agoMove md5.* to fileio/
Teemu Murtola [Sun, 19 Jan 2014 06:00:18 +0000 (08:00 +0200)]
Move md5.* to fileio/

These are only used internally for gmxfio routines, so there is no need
to install the header.

Change-Id: I4e6a40e342108a87e3f88ced451a02e11403f9c1

10 years agoMove strdb.* to src/gromacs/fileio/
Teemu Murtola [Sun, 19 Jan 2014 05:39:46 +0000 (07:39 +0200)]
Move strdb.* to src/gromacs/fileio/

Don't install the header, since it is quite marginal functionality, and
typically user code would not use the string databases directly.

Change-Id: I169cfa6a54e284e3df44f4b1ea2e0b73b7fdfdec

10 years agoClean up after gmxcpp
Mark Abraham [Wed, 15 Jan 2014 17:02:33 +0000 (18:02 +0100)]
Clean up after gmxcpp

Using grompp in integration tests with potentially multiple different
calls to gmx_grompp per executable requires that we start from a clean
state every time we do such a call. Old code was re-using -I paths,
and both -D and #defines, which was breaking some tests I am working
on.

Also added some other done_* calls on the general theory of trying not
to be evil.

Change-Id: I6016bc1786c8ecc9303eeee2ad4a83975117ca5f

10 years agoMove dump, check and tpbconv utilities
Mark Abraham [Sat, 18 Jan 2014 21:28:14 +0000 (22:28 +0100)]
Move dump, check and tpbconv utilities

These now form the start of the tools module, which is intended to
contain code for GROMACS tools whose use is not primarily for analysis
of data from simulations.

tpbcmp.* now named compare.*, since that code did not relate only to
run input files.

Removed declarations duplicated in legacycmodules.cpp in favour
of those in legacycmainfunctions.h.

Uncrustified, added copyright headers.

Change-Id: I48bf171f290fdfb177d5a020473b3a5296d89305

10 years agoFix that check_library_exist is rerun for FFTW
Roland Schulz [Thu, 16 Jan 2014 18:52:04 +0000 (13:52 -0500)]
Fix that check_library_exist is rerun for FFTW

If the library check for fftw plan fails (e.g. missing dependency or
shared library_exists not supported), then the message suggests to change
FFTWF_LIBRARY. But this failed because the check_library test wasn't
rerun because the result was already cached.

TODO: This only fixes it for FFTW. E.g. FindGsl has the same problem.

Change-Id: I170588b0fca2515e9626d7fd85a5730a10777355

10 years agoThis patch moves the statistics library to its own dir.
David van der Spoel [Tue, 14 Jan 2014 18:17:13 +0000 (19:17 +0100)]
This patch moves the statistics library to its own dir.

In the move to depopulate the legacyheaders directory
http://redmine.gromacs.org/issues/1415 this is a small
contribution. Histogram files removed.
Added doxygen style comments as well.

Change-Id: I9da9fefac0d4dd1c5de13862f348adc5c812ad4d

10 years agoFix, simplify and test XTC writing
Mark Abraham [Wed, 15 Jan 2014 13:02:24 +0000 (14:02 +0100)]
Fix, simplify and test XTC writing

The old implementation had various sins, including repeating setup and
leaking natoms_xtc rvecs of memory per step writing xtc-grps when they
are a subset of the whole system. Cleaned lots of things up.

Added integration-style tests for XTC writing.

Added more grompp -n support to integration-style tests, though not
all of it is actually used by this patch.

Also added a pragma to work around a curious warning by ICC 12 on
Windows.

Fixes #1423

Change-Id: I3a75f890f21e4a87be62bcf877eb5c471670286d

10 years agoThis patch moves preprocessing headers to gmxpreprocess
David van der Spoel [Tue, 14 Jan 2014 19:54:49 +0000 (20:54 +0100)]
This patch moves preprocessing headers to gmxpreprocess

In the move to depopulate the legacyheaders directory
http://redmine.gromacs.org/issues/1415 this is a small
contribution.

Change-Id: I209f6e5a1e76f2d3ea072f66eca9ae1f59bc0d42

10 years agoDefine MPI_INT64_T if not defined by mpi
Roland Schulz [Wed, 15 Jan 2014 19:15:33 +0000 (14:15 -0500)]
Define MPI_INT64_T if not defined by mpi

Change-Id: Ie3332ce85a5ef538d57b272ebe3e4326fb7a31ff

10 years agoClean up inputrec reading
Mark Abraham [Wed, 15 Jan 2014 22:11:26 +0000 (23:11 +0100)]
Clean up inputrec reading

In old code, there was no way to reset the state of the string buffers
that were used in parsing the inputrec from .mdp files. This was a
problem for test executables trying to parse more than one such
file. New code still doesn't permit more than one .mdp file to be
parsed at a time, but at least we can clean up and parse another one
from a fresh state.

Got rid of some useless #defines.

Change-Id: If3d72ba68e0addef18c9cf132025958995e7e2ee

10 years agoFix build with GMX_BUILD_UNITTESTS=OFF
Teemu Murtola [Wed, 15 Jan 2014 19:19:25 +0000 (21:19 +0200)]
Fix build with GMX_BUILD_UNITTESTS=OFF

Don't build the object libraries used for unit tests either if the unit
tests are disabled.  Added a helper macro for this as well.

Change-Id: I7b9f899dd2ee8adef261e49d3f8100530487ed54

10 years agoSupport for 64-bit int and real valued Options
Teemu Murtola [Mon, 23 Dec 2013 18:12:00 +0000 (20:12 +0200)]
Support for 64-bit int and real valued Options

Add Int64Option and FloatOption to the options machinery.
Add RealOption that aliases either DoubleOption or FloatOption,
depending on GMX_DOUBLE.
With these additions, the options machinery supports all the
functionality and types of the old t_pargs machinery.

Change-Id: I2260e52d3a220f824e1c3e790da2dba83f381972

10 years agoRemove unused PCA_KEEP_ARGS
Teemu Murtola [Tue, 24 Dec 2013 05:03:23 +0000 (07:03 +0200)]
Remove unused PCA_KEEP_ARGS

Simplifies the code, and removes one path to be tested.

Change-Id: Ie0fe8329a0a9130def5e03438a029ae88b6b1431

10 years agoUnit tests for parse_common_args()
Teemu Murtola [Sat, 21 Dec 2013 18:33:44 +0000 (20:33 +0200)]
Unit tests for parse_common_args()

Add unit tests for most of the basic command line parsing functionality
in parse_common_args(), including the file name handling.

To support these tests, extend arrayref.h to also include ArrayRef,
which provides a mutable wrapper for a C array.  This is complete enough
for the purpose of the tests, but may need additional work for more
general use.  Also fix some documentation typos noticed in the existing
code.

Also, fix unintuitive behavior of etTIME options that was revealed by
the tests.

Change-Id: I4b8b3ad92b0efe24fdf478cd39ba246692b036c7

10 years agoAdd nbnxn tree force reduction
Roland Schulz [Mon, 2 Dec 2013 15:07:55 +0000 (10:07 -0500)]
Add nbnxn tree force reduction

Alternative implementation of the nbnx force reduction. The previous
method is implemented as a loop over all thread buffers. Its advantage is
that it doesn't require any synchronizations during reduction and only
requires a single write per element. The new method utilizes a binary tree
for the reduction. Its advantage is that the data locality of the force
buffers is used during reduction.

The current implementation isn't faster on the CPU (for E526070 with icc).
On the MIC it is faster (36% reduction of buffer-f time for 32 threads).

Part of #1420

Change-Id: I2d84345e9a19d9030a837d324671f2ab0ba9b91b

10 years agoSimplify C array handling in C++ code
Teemu Murtola [Sat, 21 Dec 2013 18:13:22 +0000 (20:13 +0200)]
Simplify C array handling in C++ code

Add a constructor to ConstArrayRef that allows implicit creation of
ConstArrayRef from a plain C array.  This makes it possible to write a
function that takes a ConstArrayRef, pass a C array directly, and let
the compiler do the job of passing the size of the array (or complain if
that size is not available).  This is in particular useful for testing;
removed similar template implementations from a few different locations
in test code that this allows.

Change-Id: I3b59c2b911d7c8bd2a95de769426c0878ce36a7e

10 years agoThis patch moves the nrama.[ch] to the gmxana dir.
David van der Spoel [Tue, 14 Jan 2014 19:25:33 +0000 (20:25 +0100)]
This patch moves the nrama.[ch] to the gmxana dir.

In the move to depopulate the legacyheaders directory
http://redmine.gromacs.org/issues/1415 this is a small
contribution.

Change-Id: Ifa079583472b91060398e829df745834676a1eb0

10 years agoReorganize shared unit test code
Teemu Murtola [Mon, 6 Jan 2014 18:37:23 +0000 (20:37 +0200)]
Reorganize shared unit test code

Move mocks and test fixtures to the modules that they are mocking:
 - datatest.*, mock_datamodule.* to analysisdata/tests/
 - mock_helptopic.* to onlinehelp/tests/
This is now easier with object libraries, and clarifies the dependencies
in the test code.  src/testutils/ is now really about utilities, and not
about some specific-purpose test code.

Change-Id: Ib0cbe6382813315df65fa65f7fe0233b9b5e2d4e

10 years agoStop doing cppcheck on src/external
Mark Abraham [Tue, 14 Jan 2014 09:53:44 +0000 (10:53 +0100)]
Stop doing cppcheck on src/external

GROMACS doesn't plan to maintain things that live here, so we
shouldn't be exposed to messages from there, either.

Change-Id: I88661026571a52772a9fd1f25ca36540d17737e9

10 years agoDon't install links.dat
Teemu Murtola [Sat, 4 Jan 2014 18:36:12 +0000 (20:36 +0200)]
Don't install links.dat

This file is only necessary for generating the online HTML help, and
this doesn't anyways work (and doesn't need to work) except when run in
the build directory, through 'make html'.

Change-Id: Icb276749d7f8a5c4743ce426729e2564a79eb8a2

10 years agoSplit CommandLineHelpModule into a separate file
Teemu Murtola [Thu, 26 Dec 2013 06:13:21 +0000 (08:13 +0200)]
Split CommandLineHelpModule into a separate file

- Move CommandLineHelpModule and supporting classes into
  cmdlinehelpmodule.cpp.  The declaration is in a corresponding header.
- Move declarations required in both .cpp files into
  cmdlinemodulemanager-impl.h.
- Make CommandLineHelpModule use a private implementation class to be
  able to keep most classes internal to cmdlinehelpmodule.cpp.  The
  implementation class is a separate class (not a private inner class)
  to allow using it from contexts outside the actual module (necessary
  for subsequent changes).

cmdlinemodulemanager.cpp was getting long, and contained a lot of
declarations for which order mattered.  Now, the most important such
declarations are in headers, and the division between general module
management and the help management is clearer, simplifying things.

Change-Id: Iecc9a6bf6aa8b020ab153cdde6c882523574a7ab

10 years agoFix line wrapping for long options
Teemu Murtola [Mon, 30 Dec 2013 17:01:03 +0000 (19:01 +0200)]
Fix line wrapping for long options

The default line length for console output should only be set in
HelpWriterContext::writeTextBlock(), but not in the lower-level helpers,
which are generally called from contexts where line wrapping is getting
done on a higher level.

For example, 'gmx help hbond' shows some extra line breaks in the long
option descriptions without this fix.

Also removed an unused overload, that would also violate the above principle.

Change-Id: Ia40cea399c0f0f95d6d53ca2872d93baba47844e

10 years agoRemove useless trjcat -prec option
Mark Abraham [Thu, 9 Jan 2014 13:12:18 +0000 (14:12 +0100)]
Remove useless trjcat -prec option

A tool whose nominal job is concatenation should not also be changing
the precision of the output. Fortunately, that was never implemented
anyway. I don't know what happens if you try to concatenate two files
of different precision, or format or whatever. Joy!

Change-Id: I7c4ff1fe431897eddd7e4627723bac6e15387adf

10 years agoMove pull code to separate subdirectory
Carsten Kutzner [Mon, 13 Jan 2014 10:53:49 +0000 (11:53 +0100)]
Move pull code to separate subdirectory

Another part of #1415 Get rid of legacy headers.

Other changes:
- updated pulling-related include guards to new format
- updated documentation for doxygen
- updated .h includes
- uncrustified pull.h and pull_rotation.h
- updated copyright year for all files touched by this commit

Change-Id: Ief1ed3543b84f651d1bff01f1952b342850f5c22

10 years agoMove writeps.* into fileio/
Teemu Murtola [Sat, 11 Jan 2014 17:32:32 +0000 (19:32 +0200)]
Move writeps.* into fileio/

Don't install the headers, as they are quite marginal functionality.
Also, clean up the header a bit (remove unused and undefined viewps())
and remove some unnecessary inclusions.  Add include guards to
types/matrix.h to make it possible to include it without the full
typedefs.h.

Change-Id: I8352cbe01cda56212be5b185af0fc7d21ca99b23

10 years agoMove gmxcomplex.h to gromacs/math/
Teemu Murtola [Sat, 11 Jan 2014 14:08:29 +0000 (16:08 +0200)]
Move gmxcomplex.h to gromacs/math/

One more header from legacyheaders/.  Also remove some unnecessary
includes of gmxcomplex.h.

Change-Id: I2b184d04ae3ba31a850e0a332a75469f229d42aa

10 years agoFix mdrun integration tests
Mark Abraham [Fri, 13 Dec 2013 10:04:14 +0000 (21:04 +1100)]
Fix mdrun integration tests

Earlier code forced callMdrun() to trigger an mdrun -rerun, which was
not intended. Fixed that, and opened a path for code to use the
defaults of callMdrun(), but set up the executable name and prepend
command-line arguments to suit itself.

Ideally, the configurability would be more general, and there would
not be the requirement to specify the executable name, but so far this
is not a problem.

Change-Id: Id69927f9153a400455b728db577537ebc155d0af

10 years agoFix installation of HTML manual
Teemu Murtola [Mon, 6 Jan 2014 12:48:28 +0000 (14:48 +0200)]
Fix installation of HTML manual

Simplify things by making the source distribution and the git repository
have the same layout (it wasn't working earlier at all, and just adds
complexity if I were to try to fix it).  This allows using the same
installation rules for both (just replacing the binary directory with
the source directory).  Install the output directory under the proper
name (html/ instead of final/).

Change-Id: Ica88a0825999f201e9856e11e1784bd4acc20c91

10 years agoCleaned up list of GROMACS authors
David van der Spoel [Sat, 28 Dec 2013 13:51:28 +0000 (14:51 +0100)]
Cleaned up list of GROMACS authors

Now the authors are listed alphabetically and in four neat columns
(only Berendsen's name overflows its allocated space, but that looks
OK).  List project leaders still separately at the end of the list.
Update the copyright year, add Stockholm University, and add some
contributors to the list of authors (found by digging git log and
including anyone with a full name and more than a few commits).

Change-Id: I14222bab394ee498380709fba9c0967e6d092980

10 years agoMove essential dynamics / flooding code to separate directory
Carsten Kutzner [Tue, 7 Jan 2014 17:48:38 +0000 (18:48 +0100)]
Move essential dynamics / flooding code to separate directory

Part of #1415 Get rid of legacyheaders.

Additional changes:
- provided doxygen-style documentation for functions in edsam.h
  (partly copied over from edsam.c and removed there to avoid
  duplication)
- uncrustified edsam.c and edsam.h

Change-Id: If4af498470c5200d50ac1d1b5537917c873380b5

10 years agoRead essential dynamics data from checkpoint at correct place, fixes #1392
Carsten Kutzner [Fri, 6 Dec 2013 10:45:48 +0000 (11:45 +0100)]
Read essential dynamics data from checkpoint at correct place, fixes #1392

In read_checkpoint(), the order in which the data blocks are read from .cpt
differs from the order in write_checkpoint(), read_checkpoint_data() and
list_checkpoint().
This change puts the do_cpt_EDstate() routine after the do_cpt_enerhist()
routine, as is already the case for the other checkpoint-reading functions.

Change-Id: Ib017dfbd05918b4ee8e27f1ec93523497c559936

10 years agoFixed non-working flat-bottom posres code.
Jochen Hub [Tue, 10 Dec 2013 09:17:07 +0000 (10:17 +0100)]
Fixed non-working flat-bottom posres code.

Change-Id: I905ba495981370bd9346909a707a61e10a852907

10 years agoMerge release-4-6 into master
Roland Schulz [Thu, 9 Jan 2014 18:48:12 +0000 (13:48 -0500)]
Merge release-4-6 into master

Conflicts:
src/gromacs/gmxlib/checkpoint.c
src/kernel/genalg.c
src/programs/mdrun/md.c
             (moved change to trajectory_writing.c)

Change-Id: Ia9c8722c7fb80d48d8e40cec2af0cb93dc7e468e

10 years agoFixed precision in thermal expansion coefficient calc.
David van der Spoel [Mon, 23 Dec 2013 20:42:08 +0000 (21:42 +0100)]
Fixed precision in thermal expansion coefficient calc.

Loss of accuracy was caused by different sampling
of volume and enthalpy and as a result alpha was
computed incorrectly. With the present "fix" the volume
and enthalpy are both downsampled to what is written
in the .edr file. The real fix would be to store the product
of H and V in the .edr file, but that falls outside the
4.6 branch policy.

Change-Id: I1be06d689002d7c9d6be92bf1e377912f0be1efd

10 years agoAdd SIMD support for Intel MIC
Roland Schulz [Mon, 2 Dec 2013 04:37:27 +0000 (23:37 -0500)]
Add SIMD support for Intel MIC

Only single precision is supported so far.

To compile in native mode:
CFLAGS="-mmic" CXXFLAGS="-mmic" cmake

Regressiontests pass with ICC 14.

Instructions are not updated because only offload mode (#1181)
is useful to the user.

Part of #1187

Change-Id: I81a2022cfcecf634fdfaff5ce63ad82f0a5d4dee

10 years agoRemove reimplimentation of two functions
Roland Schulz [Mon, 9 Dec 2013 20:46:03 +0000 (15:46 -0500)]
Remove reimplimentation of two functions

- parse_printf_args was identical to vsprintf (C89)
- str_to_int64_t was identical to strtoll (C99) and
  MSVC provides an replacement (_strtoi64)

Fixes #1163

Change-Id: I62fedc4193b408584d1c6978949202f11a9f81aa

10 years agoRemove remaining usage of SIZEOF*
Roland Schulz [Mon, 9 Dec 2013 18:49:36 +0000 (13:49 -0500)]
Remove remaining usage of SIZEOF*

tmpi still uses SIZEOF_LONG_LONG_INT. It is OK that it is
undefined because this simply causes MPI_LONG_LONG_INT not to
be defined, and it isn't used.

Change-Id: Ifc2cb6267064f05d1573c4a7e23cdc77c003f737

10 years agoRemove some usage of SIZEOF*
Roland Schulz [Mon, 9 Dec 2013 03:57:36 +0000 (22:57 -0500)]
Remove some usage of SIZEOF*

- Remove MacOS hack in src/config.h.cmakein. It wasn't described in detail why
  it was needed. Removed with the asssumption that new cmake versions don't
  have that problem anymore.
- Require 64bit file support. There is no need to keep 32bit file support, now
  that we require 64bit integer. And remove unnessary code.

Change-Id: I501d8b8430ec93ada415b9ac0b60ba6d095c4725

10 years agoAdd messages for skipped tests in make check
Teemu Murtola [Sun, 5 Jan 2014 05:45:46 +0000 (07:45 +0200)]
Add messages for skipped tests in make check

Make 'make check' print a message if unit tests and/or regression tests
are not run, and instruct the user how to change that.

While at it, clean up the test CMake setup slightly. Move some target
definitions into a different file or a different place to make the CMake
code easier to follow, and remove an unnecessary test for CMake version
now that we require 2.8.8.

It is difficult to produce such a message in 'make test', so hopefully
the higher-level message is sufficient.

Change-Id: I8283c88ffab1d797676ba83880690d465ac195ff

10 years agoFix copyright check in admin/uncrustify.sh
Teemu Murtola [Wed, 1 Jan 2014 19:33:40 +0000 (21:33 +0200)]
Fix copyright check in admin/uncrustify.sh

The automatic copyright year check didn't consider files that were also
uncrustified.  Also removed some extra code (that had no effect) from
the script that looks like incorrectly merged or pasted.

Also fix incorrect attribute for thread_mpi/CMakeLists.txt.

Part of #818.

Change-Id: I80ce1b936fa9b77a94eb3dfe8fcff0490a886f42

10 years agoRemove unreachable fatal error
Mark Abraham [Wed, 8 Jan 2014 12:57:01 +0000 (13:57 +0100)]
Remove unreachable fatal error

read_first_xtc returns the same value that is stored in the output
argument, so one branch of the old code was unreachable.

Noticed this while implementing TNG support, but fixed it here since
it is technically unrelated.

Change-Id: I52387ad1628944edca12703557857bf748e7bb86

10 years agoRemove unused debug code
Mark Abraham [Wed, 8 Jan 2014 13:03:45 +0000 (14:03 +0100)]
Remove unused debug code

This serves no purpose, and was causing minor problems with TNG
development.

Change-Id: Icec86de6e16d68773e89b67b115924f12d1fe4e5

10 years agoAdd helpful note about changed default behaviour
Mark Abraham [Wed, 8 Jan 2014 15:35:44 +0000 (16:35 +0100)]
Add helpful note about changed default behaviour

The kind of short .mdp file that might historically have been used for
tests, tutorials or benchmarks used to trigger the group cut-off
scheme up to and including 4.6, because it was either the only
behaviour or the default. Only one year later, the default has changed
to be the Verlet scheme, which might lead to confusion and/or invalid
comparisons. This note will hopefully help people start to understand
any differences.

Refs #1414

Change-Id: I34a2f1c17d4b58e14f81a95c1df3659f13a6cf24

10 years agoMove gmx_sort.* to src/gromacs/utility/
Teemu Murtola [Thu, 2 Jan 2014 15:48:53 +0000 (17:48 +0200)]
Move gmx_sort.* to src/gromacs/utility/

This particular header doesn't need to be installed, since it is only an
implementation detail.

One more header away from legacyheaders/ and from installed headers.

Change-Id: I8a1b511859c370be72fd3da86c613e2f222fe50d

10 years agoCheckpointing fix for Native Client
Peter Kasson [Wed, 8 Jan 2014 00:29:06 +0000 (16:29 -0800)]
Checkpointing fix for Native Client

Native Client doesn't allow file renames.  We can over-write output
files, however.  For checkpoints, live dangerously and skip backups.
The alternate would be to use an in-memory file system, but then we're
still screwed if the program gets killed partway through writing the
on-disk version.  Other alternates:  keep all checkpoints.

Change-Id: I952ee6436e69f015633a150f94fca65c7271c6bb

10 years agoCreate math module
Mark Abraham [Sun, 24 Nov 2013 11:55:28 +0000 (12:55 +0100)]
Create math module

Renamed */maths.[ch] to */math/utilities.[ch]. Added license
statement for Sun FDLIBM. Uncrustified files in new module. Removed
orphan crecipdata.c file and invsqrt_test.c. Updated #include guards.
Moved some non-performance-sensitive function definitions from maths.h
to utilities.c.

A future patch will deal with vec.h.

Change-Id: I954cc48487c1af7f59f5a18c012c76d4297f7cab

10 years agoMove gstat.h to gmxana/
Teemu Murtola [Sat, 4 Jan 2014 18:59:13 +0000 (20:59 +0200)]
Move gstat.h to gmxana/

Remove unnecessary inclusions of gstat.h from outside gmxana/.
Now that the header is no longer used outside gmxana/, move it into that
directory.  Still install the header, since it contains a wide mixture
of stuff, some of which may actually be used by user tools.

This cleans up the include dependency graph considerably, since the
legacyheaders/ directory no longer depends on commandline/.  This was a
source of a cyclic dependency that made the graph layout very confusing.

Change-Id: I3843f2773d6b393e4d260e84478ab559ab8e00d7

10 years agoImprove include dependency script
Teemu Murtola [Fri, 13 Dec 2013 18:48:32 +0000 (20:48 +0200)]
Improve include dependency script

- Make the depcheck, doccheck, and depgraphs targets work on the whole
  src/gromacs/ directory.  Now it is possible to run these checks on new
  or reorganized code without touching the scripts themselves.
- Fix the script to correctly recognize relative paths in #include
  directives again.
- Fix some issues the script complains about, and suppress some messages
  within the script itself.
- Make the colors in the module dependency graph somewhat more
  intuitive, and show legacy dependencies in gray instead of bright red
  to make it look reasonable.
- The module dependency graph now includes the legacy modules
  (gmxlib etc.) as well, with a gray background.  This makes the graph a
  bit messier, but still readable (in particular since most of the lines
  to and from them are gray, making them fade into the background).

Now, 'make depcheck' doesn't report any issues, and we should keep it
that way.  'make doccheck' (with the current, somewhat relaxed rules)
reports only a few issues that should be relatively easy to fix, but
left those for separate changes.  Other Doxygen documentation checks
(not only about file dependencies) could also perhaps be included in
this same target.

Change-Id: I3f837c69f2608d2a6a25ed4062102d252a85a0cf

10 years agoRemoved a few typos in three German quotes.
Carsten Kutzner [Fri, 3 Jan 2014 16:33:16 +0000 (17:33 +0100)]
Removed a few typos in three German quotes.

Change-Id: Ibf4868ec0c70b3004d01c057722aed993a79192f

10 years agoSupport for default values for SelectionOption
Teemu Murtola [Tue, 12 Nov 2013 19:46:30 +0000 (21:46 +0200)]
Support for default values for SelectionOption

SelectionOption now provides a defaultSelectionText() method to define a
default selection text for cases where the user does not provide the
option at all.  The free volume tool now uses this, since typical usage
is to run for all atoms in the system.
Was discussed on gmx-developers some time ago, so hopefully this is
useful in other contexts as well.
The default value does not appear in the output of -h, but that is
better fixed separately as part of a larger overhaul of the help output.

Change-Id: Ib4cba901a33e402a96ece473f70ac10365abcaac

10 years agoFix #include style issues
Teemu Murtola [Mon, 9 Dec 2013 19:32:35 +0000 (21:32 +0200)]
Fix #include style issues

Include local headers as "something.h" instead of <something.h>, and
vice versa for system headers.  These locations were found while working
on the includedeps.py script; it is easier to fix them than try to
selectively suppress things in the script.

All changes under linearalgebra are mechanical replacements of
  #include <types/simple.h>
with
  #include "types/simple.h"
Other files contain various fixes.  Removed includes for sysstuff.h,
since it doesn't serve a very useful purpose.

Deleted displacement.c and displacement.h instead of fixing, as they
have not been compiled in a long time.

Change-Id: I06e04c74707621903a1fa79de060e1989b99f042

10 years agoDon't print quotes on gmx_fatal()
Teemu Murtola [Wed, 1 Jan 2014 19:36:56 +0000 (21:36 +0200)]
Don't print quotes on gmx_fatal()

Printing a quote is a complex operation involving file I/O and memory
allocation.  This can fail in a number of ways, including calling
gmx_fatal()...  The simplest way to avoid the possibility of deadlocks
and/or endless loops is to not try anything like that in an error
handler.

Change-Id: Id891f8fe2036d10966a1f2c8b0fcb61dadcec39b

10 years agoAdd copyright year 2013 to files modified this year
Teemu Murtola [Sun, 29 Dec 2013 18:49:22 +0000 (20:49 +0200)]
Add copyright year 2013 to files modified this year

Excluded copyright modification and mass uncrustification commits from
the consideration.

Change-Id: I1d5177abf09e1d470033b80db721afdb8b77e29f

10 years agoInclude CUDA and latex files in copyright check
Teemu Murtola [Sun, 8 Dec 2013 05:56:44 +0000 (07:56 +0200)]
Include CUDA and latex files in copyright check

Now also CUDA and latex files are indicated by the .gitattributes file
to contain copyright, and the copyright.py script can deal with them.
This should conclude the work to reformat copyright headers in the
master branch.  Some individual files may still be missing, but those
can be fixed when spotted.

Part of #818

Change-Id: Ib6d3e10b57a42ea7a8c990e51df669cace4c8d8f

10 years agoSuppress remaining errors from copyright script
Teemu Murtola [Sat, 7 Dec 2013 18:37:25 +0000 (20:37 +0200)]
Suppress remaining errors from copyright script

- Add a mechanism to the script that allows it to be used only for
  uncrustification, but not for copyright checking for certain files.
- Use the mechanism to suppress copyright checking for thread_mpi files.
  It's somewhat unclear whether we should just prepend the Gromacs
  copyright to these files and get rid of this exception, or whether we
  still are planning to maintain the library separately.  But until that
  is clear, this keeps the script quiet, and the copyright headers need
  to be manually maintained if desired.
- Suppress a few files that don't have any copyright header.
- Add copyright header to two source files that were still missing it.

With these changes, running admin/copyright.py on all files indicated by
.gitattributes only produces messages about outdated copyright years
(which it should, for files that have not been modified this year).

Part of #818.

Change-Id: I2cb09b2b30e782244c16faf02625d405dac642b6

10 years agoFix remaining copyright headers
Teemu Murtola [Mon, 2 Dec 2013 18:59:20 +0000 (20:59 +0200)]
Fix remaining copyright headers

Apply copyright to the remaining files, excluding thread_mpi, with the
copyright year as the year when the last change to that file was made
(excluding other copyright stuff and mass uncrustification).

Part of #818.

Change-Id: Ib70deb8a8e71b23511b68c91e05c1dee821a6d2c

10 years agoMore copyright header updates
Teemu Murtola [Sat, 30 Nov 2013 11:50:39 +0000 (13:50 +0200)]
More copyright header updates

Remove old copyrights from files added recently (for 4.6 or somewhat
earlier, plus some selected files where it was easier to enumerate all
years than to adapt the script to handle their existing copyrights) and
make the copyright headers follow the new format.  Put best-guess
estimates for the copyright years based on when the files have been
modified.  No effort was spent on trying to track content beyond git
rename detection, so some content may originate from earlier than the
first copyright year mentioned, but this is hopefully not a big deal.

Part of #818.

Change-Id: I44e1eff552bff47a2ae10b3181960a8a2a6753df

10 years agoRemove obsolete large file support info
Teemu Murtola [Sat, 21 Dec 2013 13:44:49 +0000 (15:44 +0200)]
Remove obsolete large file support info

The check for large file support in copyrite.cpp wasn't working, since
the define was no longer in config.h.  Given that I501d8b84 makes large
file support required, this information no longer needs to be there.

Change-Id: I9492011d2f8ebb58612ed2a5a79d9f786fd19f61