Remove unnecessary config.h includes
[alexxy/gromacs.git] / src / gromacs / mdlib / genborn_allvsall_sse2_double.c
index e795efa5615e0f622746d222b543ce91a2434892..4816c101337fd7aacb534e747e6f3077fa2e69c0 100644 (file)
@@ -1,50 +1,54 @@
 /*
- *                This source code is part of
- *
- *                 G   R   O   M   A   C   S
+ * This file is part of the GROMACS molecular simulation package.
  *
  * Copyright (c) 1991-2000, University of Groningen, The Netherlands.
- * Copyright (c) 2001-2009, The GROMACS Development Team
+ * Copyright (c) 2001-2009, The GROMACS Development Team.
+ * Copyright (c) 2012,2014, by the GROMACS development team, led by
+ * Mark Abraham, David van der Spoel, Berk Hess, and Erik Lindahl,
+ * and including many others, as listed in the AUTHORS file in the
+ * top-level source directory and at http://www.gromacs.org.
+ *
+ * GROMACS is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 2.1
+ * of the License, or (at your option) any later version.
  *
- * Gromacs is a library for molecular simulation and trajectory analysis,
- * written by Erik Lindahl, David van der Spoel, Berk Hess, and others - for
- * a full list of developers and information, check out http://www.gromacs.org
+ * GROMACS is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+ * Lesser General Public License for more details.
  *
- * This program is free software; you can redistribute it and/or modify it under
- * the terms of the GNU Lesser General Public License as published by the Free
- * Software Foundation; either version 2 of the License, or (at your option) any
- * later version.
- * As a special exception, you may use this file as part of a free software
- * library without restriction.  Specifically, if other files instantiate
- * templates or use macros or inline functions from this file, or you compile
- * this file and link it with other files to produce an executable, this
- * file does not by itself cause the resulting executable to be covered by
- * the GNU Lesser General Public License.
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with GROMACS; if not, see
+ * http://www.gnu.org/licenses, or write to the Free Software Foundation,
+ * Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA.
  *
- * In plain-speak: do not worry about classes/macros/templates either - only
- * changes to the library have to be LGPL, not an application linking with it.
+ * If you want to redistribute modifications to GROMACS, please
+ * consider that scientific software is very special. Version
+ * control is crucial - bugs must be traceable. We will be happy to
+ * consider code for inclusion in the official distribution, but
+ * derived work must not be called official GROMACS. Details are found
+ * in the README & COPYING files - if they are missing, get the
+ * official version at http://www.gromacs.org.
  *
- * To help fund GROMACS development, we humbly ask that you cite
- * the papers people have written on it - you can find them on the website!
+ * To help us fund GROMACS development, we humbly ask that you cite
+ * the research papers on the package. Check out http://www.gromacs.org.
  */
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
+#include "gmxpre.h"
 
 #include <math.h>
-#include "types/simple.h"
+#include "gromacs/legacyheaders/types/simple.h"
 
-#include "vec.h"
-#include "smalloc.h"
+#include "gromacs/math/vec.h"
+#include "gromacs/utility/smalloc.h"
 
-#include "partdec.h"
-#include "network.h"
-#include "physics.h"
-#include "genborn.h"
+#include "gromacs/legacyheaders/network.h"
+#include "gromacs/math/units.h"
+#include "gromacs/legacyheaders/genborn.h"
 #include "genborn_allvsall.h"
 
 
-#if 0 && defined (GMX_X86_SSE2)
+#if 0 && defined (GMX_SIMD_X86_SSE2_OR_HIGHER)
 
 #include <gmx_sse2_double.h>
 
@@ -718,7 +722,7 @@ genborn_allvsall_setup(gmx_allvsallgb2_data_t     **  p_aadata,
         aadata->fz_align[i] = 0.0;
     }
 
-    setup_gb_exclusions_and_indices(aadata, top->idef.il, mdatoms->start, mdatoms->start+mdatoms->homenr, mdatoms->nr,
+    setup_gb_exclusions_and_indices(aadata, top->idef.il, 0, mdatoms->homenr, mdatoms->nr,
                                     bInclude12, bInclude13, bInclude14);
 }
 
@@ -797,8 +801,8 @@ genborn_allvsall_calc_still_radii_sse2_double(t_forcerec   *           fr,
     __m128d                 still_p4_SSE, still_p5inv_SSE, still_pip5_SSE;
 
     natoms              = mdatoms->nr;
-    ni0                 = (mdatoms->start/SIMD_WIDTH)*SIMD_WIDTH;
-    ni1                 = mdatoms->start+mdatoms->homenr;
+    ni0                 = 0;
+    ni1                 = mdatoms->homenr;
 
     n = 0;
 
@@ -1165,11 +1169,7 @@ genborn_allvsall_calc_still_radii_sse2_double(t_forcerec   *           fr,
         work[i-natoms] += work[i];
     }
 
-    /* Parallel summations */
-    if (PARTDECOMP(cr))
-    {
-        gmx_sum(natoms, work, cr);
-    }
+    /* Parallel summations would go here if ever implemented with DD */
 
     factor  = 0.5 * ONE_4PI_EPS0;
     /* Calculate the radii - should we do all atoms, or just our local ones? */
@@ -1264,8 +1264,8 @@ genborn_allvsall_calc_hct_obc_radii_sse2_double(t_forcerec   *           fr,
     __m128d                 doffset_SSE, tmpSSE;
 
     natoms              = mdatoms->nr;
-    ni0                 = (mdatoms->start/SIMD_WIDTH)*SIMD_WIDTH;
-    ni1                 = mdatoms->start+mdatoms->homenr;
+    ni0                 = 0;
+    ni1                 = mdatoms->homenr;
 
     n = 0;
 
@@ -2222,12 +2222,7 @@ genborn_allvsall_calc_hct_obc_radii_sse2_double(t_forcerec   *           fr,
         work[i] += work[natoms+i];
     }
 
-    /* Parallel summations */
-
-    if (PARTDECOMP(cr))
-    {
-        gmx_sum(natoms, work, cr);
-    }
+    /* Parallel summations would go here if ever implemented in DD */
 
     if (gb_algorithm == egbHCT)
     {
@@ -2340,8 +2335,8 @@ genborn_allvsall_calc_chainrule_sse2_double(t_forcerec   *           fr,
     __m128d                 t1, t2, tmpSSE;
 
     natoms              = mdatoms->nr;
-    ni0                 = (mdatoms->start/SIMD_WIDTH)*SIMD_WIDTH;
-    ni1                 = mdatoms->start+mdatoms->homenr;
+    ni0                 = 0;
+    ni1                 = mdatoms->homenr;
 
     aadata = (gmx_allvsallgb2_data_t *)paadata;