From e844ce3ddf0cdffad77faafefa3c6218f1e97f5f Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Thu, 25 Jul 2024 08:44:54 -0400 Subject: [PATCH] re-align ReaxFF OpenMP version of ValidateLists with serial version --- src/OPENMP/reaxff_forces_omp.cpp | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/src/OPENMP/reaxff_forces_omp.cpp b/src/OPENMP/reaxff_forces_omp.cpp index 26922add1e..ce8ad0716f 100644 --- a/src/OPENMP/reaxff_forces_omp.cpp +++ b/src/OPENMP/reaxff_forces_omp.cpp @@ -155,7 +155,7 @@ namespace ReaxFF { /* ---------------------------------------------------------------------- */ static void Validate_ListsOMP(reax_system *system, reax_list **lists, - int step, int n, int N, int numH) + int step, int N, int numH) { int comp, Hindex; reax_list *bonds, *hbonds; @@ -195,7 +195,7 @@ namespace ReaxFF { #if defined(_OPENMP) #pragma omp for schedule(guided) #endif - for (int i = 0; i < n; ++i) { + for (int i = 0; i < N; ++i) { Hindex = system->my_atoms[i].Hindex; if (Hindex > -1) { system->my_atoms[i].num_hbonds = @@ -457,8 +457,7 @@ namespace ReaxFF { workspace->realloc.num_bonds = num_bonds; workspace->realloc.num_hbonds = num_hbonds; - Validate_ListsOMP(system, lists, data->step, - system->n, system->N, system->numH); + Validate_ListsOMP(system, lists, data->step, system->N, system->numH); } /* ---------------------------------------------------------------------- */