*/
#include "gmxpre.h"
-#include <stdio.h>
+#include "gromacs/legacyheaders/update.h"
+
#include <math.h>
+#include <stdio.h>
-#include "gromacs/legacyheaders/types/commrec.h"
-#include "gromacs/legacyheaders/typedefs.h"
-#include "gromacs/legacyheaders/nrnb.h"
-#include "gromacs/math/units.h"
-#include "gromacs/legacyheaders/macros.h"
-#include "gromacs/math/vec.h"
-#include "gromacs/legacyheaders/update.h"
-#include "gromacs/random/random.h"
-#include "gromacs/legacyheaders/tgroup.h"
-#include "gromacs/legacyheaders/force.h"
-#include "gromacs/legacyheaders/names.h"
-#include "gromacs/legacyheaders/txtdump.h"
-#include "gromacs/legacyheaders/mdrun.h"
+#include "gromacs/fileio/confio.h"
#include "gromacs/legacyheaders/constr.h"
#include "gromacs/legacyheaders/disre.h"
-#include "gromacs/legacyheaders/orires.h"
+#include "gromacs/legacyheaders/force.h"
#include "gromacs/legacyheaders/gmx_omp_nthreads.h"
-
-#include "gromacs/fileio/confio.h"
+#include "gromacs/legacyheaders/macros.h"
+#include "gromacs/legacyheaders/mdrun.h"
+#include "gromacs/legacyheaders/names.h"
+#include "gromacs/legacyheaders/nrnb.h"
+#include "gromacs/legacyheaders/orires.h"
+#include "gromacs/legacyheaders/tgroup.h"
+#include "gromacs/legacyheaders/txtdump.h"
+#include "gromacs/legacyheaders/typedefs.h"
+#include "gromacs/legacyheaders/types/commrec.h"
+#include "gromacs/math/units.h"
+#include "gromacs/math/vec.h"
#include "gromacs/pbcutil/mshift.h"
#include "gromacs/pbcutil/pbc.h"
#include "gromacs/pulling/pull.h"
+#include "gromacs/random/random.h"
#include "gromacs/timing/wallcycle.h"
#include "gromacs/utility/futil.h"
#include "gromacs/utility/gmxomp.h"
}
else
{
-#pragma omp parallel for num_threads(gmx_omp_nthreads_get(emntUpdate)) schedule(static)
+ nth = gmx_omp_nthreads_get(emntUpdate);
+
+#pragma omp parallel for num_threads(nth) schedule(static)
for (i = start; i < nrend; i++)
{
copy_rvec(upd->xp[i], state->x[i]);