Minor improvements to ewald_LRcorrection
authorMark Abraham <mark.j.abraham@gmail.com>
Wed, 22 Jan 2014 13:32:53 +0000 (14:32 +0100)
committerGerrit Code Review <gerrit@gerrit.gromacs.org>
Thu, 30 Jan 2014 22:08:08 +0000 (23:08 +0100)
commit58c51bb63ac887d154911097de9ce1eb3b16937c
treef2c2db47d4101916b100fa72fa2cd546a13b1af4
parentb94ae4256fda537ef7b7d7af7e249b4d6416301a
Minor improvements to ewald_LRcorrection

LJ-PME code doesn't need terms in odd powers of r or beta, so the code
might run a litte faster if expressed this way (fewer flops and fewer
registers).

Made the code that needs dr explicit by declaring dr only where it is
used.

Moved declaration of the fscal temporary to the blocks where it is
used, and commented that it is actually not the scalar force, but the
scalar force pre-multiplied by rinv. Probably that comment should
go in the generic kernels, also.

Change-Id: I052cb5a9b3bdf67a582aec0fcd99ad5da33a3b77
src/gromacs/gmxlib/ewald_util.c