Sort all includes in src/gromacs
[alexxy/gromacs.git] / src / gromacs / mdlib / domdec_network.c
index f2cde6b101e03bbe04763806dd7be041a03cc6da..eec664a5d028eda9623a889928bd42bd89a4dbec 100644 (file)
@@ -1,38 +1,57 @@
-/* -*- mode: c; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; c-file-style: "stroustrup"; -*-
+/*
+ * This file is part of the GROMACS molecular simulation package.
  *
+ * Copyright (c) 2008,2009,2010,2012,2013,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.
  *
- * This file is part of Gromacs        Copyright (c) 1991-2008
- * David van der Spoel, Erik Lindahl, Berk Hess, University of Groningen.
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; either version 2
+ * 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.
  *
- * To help us fund GROMACS development, we humbly ask that you cite
- * the research papers on the package. 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.
+ *
+ * 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.
+ *
+ * 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.
  *
- * And Hey:
- * Gnomes, ROck Monsters And Chili Sauce
+ * 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 "gromacs/legacyheaders/domdec_network.h"
+
+#include "config.h"
 
 #include <string.h>
-#include "domdec_network.h"
 
+#include "gromacs/legacyheaders/types/commrec.h"
 #include "gromacs/utility/gmxmpi.h"
 
 
 #define DDMASTERRANK(dd)   (dd->masterrank)
 
 
-void dd_sendrecv_int(const gmx_domdec_t *dd,
-                     int ddimind, int direction,
-                     int *buf_s, int n_s,
-                     int *buf_r, int n_r)
+void dd_sendrecv_int(const gmx_domdec_t gmx_unused *dd,
+                     int gmx_unused ddimind, int gmx_unused direction,
+                     int gmx_unused *buf_s, int gmx_unused n_s,
+                     int gmx_unused *buf_r, int gmx_unused n_r)
 {
 #ifdef GMX_MPI
     int        rank_s, rank_r;
@@ -61,10 +80,10 @@ void dd_sendrecv_int(const gmx_domdec_t *dd,
 #endif
 }
 
-void dd_sendrecv_real(const gmx_domdec_t *dd,
-                      int ddimind, int direction,
-                      real *buf_s, int n_s,
-                      real *buf_r, int n_r)
+void dd_sendrecv_real(const gmx_domdec_t gmx_unused *dd,
+                      int gmx_unused ddimind, int gmx_unused direction,
+                      real gmx_unused *buf_s, int gmx_unused n_s,
+                      real gmx_unused *buf_r, int gmx_unused n_r)
 {
 #ifdef GMX_MPI
     int        rank_s, rank_r;
@@ -93,10 +112,10 @@ void dd_sendrecv_real(const gmx_domdec_t *dd,
 #endif
 }
 
-void dd_sendrecv_rvec(const gmx_domdec_t *dd,
-                      int ddimind, int direction,
-                      rvec *buf_s, int n_s,
-                      rvec *buf_r, int n_r)
+void dd_sendrecv_rvec(const gmx_domdec_t gmx_unused *dd,
+                      int gmx_unused ddimind, int gmx_unused direction,
+                      rvec gmx_unused *buf_s, int gmx_unused n_s,
+                      rvec gmx_unused *buf_r, int gmx_unused n_r)
 {
 #ifdef GMX_MPI
     int        rank_s, rank_r;
@@ -125,12 +144,12 @@ void dd_sendrecv_rvec(const gmx_domdec_t *dd,
 #endif
 }
 
-void dd_sendrecv2_rvec(const gmx_domdec_t *dd,
-                       int ddimind,
-                       rvec *buf_s_fw, int n_s_fw,
-                       rvec *buf_r_fw, int n_r_fw,
-                       rvec *buf_s_bw, int n_s_bw,
-                       rvec *buf_r_bw, int n_r_bw)
+void dd_sendrecv2_rvec(const gmx_domdec_t gmx_unused *dd,
+                       int gmx_unused ddimind,
+                       rvec gmx_unused *buf_s_fw, int gmx_unused n_s_fw,
+                       rvec gmx_unused *buf_r_fw, int gmx_unused n_r_fw,
+                       rvec gmx_unused *buf_s_bw, int gmx_unused n_s_bw,
+                       rvec gmx_unused *buf_r_bw, int gmx_unused n_r_bw)
 {
 #ifdef GMX_MPI
     int         rank_fw, rank_bw, nreq;
@@ -200,7 +219,7 @@ void dd_sendrecv2_rvec(const gmx_domdec_t *dd,
  * called during DD setup and partition.
  */
 
-void dd_bcast(gmx_domdec_t *dd, int nbytes, void *data)
+void dd_bcast(gmx_domdec_t gmx_unused *dd, int gmx_unused nbytes, void gmx_unused *data)
 {
 #ifdef GMX_MPI
 #ifdef GMX_BLUEGENE
@@ -234,7 +253,7 @@ void dd_bcastc(gmx_domdec_t *dd, int nbytes, void *src, void *dest)
 #endif
 }
 
-void dd_scatter(gmx_domdec_t *dd, int nbytes, void *src, void *dest)
+void dd_scatter(gmx_domdec_t gmx_unused *dd, int gmx_unused nbytes, void gmx_unused *src, void gmx_unused *dest)
 {
 #ifdef GMX_MPI
     MPI_Scatter(src, nbytes, MPI_BYTE,
@@ -243,7 +262,7 @@ void dd_scatter(gmx_domdec_t *dd, int nbytes, void *src, void *dest)
 #endif
 }
 
-void dd_gather(gmx_domdec_t *dd, int nbytes, void *src, void *dest)
+void dd_gather(gmx_domdec_t gmx_unused *dd, int gmx_unused nbytes, void gmx_unused *src, void gmx_unused *dest)
 {
 #ifdef GMX_MPI
     MPI_Gather(src, nbytes, MPI_BYTE,
@@ -252,9 +271,9 @@ void dd_gather(gmx_domdec_t *dd, int nbytes, void *src, void *dest)
 #endif
 }
 
-void dd_scatterv(gmx_domdec_t *dd,
-                 int *scounts, int *disps, void *sbuf,
-                 int rcount, void *rbuf)
+void dd_scatterv(gmx_domdec_t gmx_unused *dd,
+                 int gmx_unused *scounts, int gmx_unused *disps, void gmx_unused *sbuf,
+                 int gmx_unused rcount, void gmx_unused *rbuf)
 {
 #ifdef GMX_MPI
     int dum;
@@ -270,9 +289,9 @@ void dd_scatterv(gmx_domdec_t *dd,
 #endif
 }
 
-void dd_gatherv(gmx_domdec_t *dd,
-                int scount, void *sbuf,
-                int *rcounts, int *disps, void *rbuf)
+void dd_gatherv(gmx_domdec_t gmx_unused *dd,
+                int gmx_unused scount, void gmx_unused *sbuf,
+                int gmx_unused *rcounts, int gmx_unused *disps, void gmx_unused *rbuf)
 {
 #ifdef GMX_MPI
     int dum;