forked from lijiext/lammps
Merge branch 'omp4-compat' into correct-kokkos-docs
This commit is contained in:
commit
8b1c6cb279
|
@ -240,16 +240,7 @@ if(OpenMP_FOUND)
|
|||
endif()
|
||||
endif()
|
||||
|
||||
# TODO: this is a temporary workaround until a better solution is found. AK 2019-05-30
|
||||
# GNU GCC 9.x uses settings incompatible with our use of 'default(none)' in OpenMP pragmas
|
||||
# where we assume older GCC semantics. For the time being, we disable OpenMP by default
|
||||
# for GCC 9.x and beyond. People may manually turn it on, but need to run the script
|
||||
# src/USER-OMP/hack_openmp_for_pgi_gcc9.sh on all sources to make it compatible with gcc 9.
|
||||
if ((CMAKE_CXX_COMPILER_ID STREQUAL "GNU") AND (CMAKE_CXX_COMPILER_VERSION VERSION_GREATER 8.99.9))
|
||||
option(BUILD_OMP "Build with OpenMP support" OFF)
|
||||
else()
|
||||
option(BUILD_OMP "Build with OpenMP support" ${BUILD_OMP_DEFAULT})
|
||||
endif()
|
||||
option(BUILD_OMP "Build with OpenMP support" ${BUILD_OMP_DEFAULT})
|
||||
|
||||
if(BUILD_OMP)
|
||||
find_package(OpenMP REQUIRED)
|
||||
|
@ -257,6 +248,17 @@ if(BUILD_OMP)
|
|||
if(NOT HAVE_OMP_H_INCLUDE)
|
||||
message(FATAL_ERROR "Cannot find the 'omp.h' header file required for full OpenMP support")
|
||||
endif()
|
||||
|
||||
if (((CMAKE_CXX_COMPILER_ID STREQUAL "GNU") AND (CMAKE_CXX_COMPILER_VERSION VERSION_GREATER 8.99.9)) OR
|
||||
((CMAKE_CXX_COMPILER_ID STREQUAL "Clang") AND (CMAKE_CXX_COMPILER_VERSION VERSION_GREATER 9.99.9)) OR
|
||||
((CMAKE_CXX_COMPILER_ID STREQUAL "Intel") AND (CMAKE_CXX_COMPILER_VERSION VERSION_GREATER 18.99.9))
|
||||
)
|
||||
# GCC 9.x and later plus Clang 10.x and later implement strict OpenMP 4.0 semantics for consts.
|
||||
# Intel 18.0 was tested to support both, so we switch to OpenMP 4+ from 19.x onward to be safe.
|
||||
target_compile_definitions(lammps PRIVATE -DLAMMPS_OMP_COMPAT=4)
|
||||
else()
|
||||
target_compile_definitions(lammps PRIVATE -DLAMMPS_OMP_COMPAT=3)
|
||||
endif()
|
||||
target_link_libraries(lammps PRIVATE OpenMP::OpenMP_CXX)
|
||||
endif()
|
||||
|
||||
|
|
|
@ -264,6 +264,16 @@ cmake -C ../cmake/presets/all_on.cmake -C ../cmake/presets/nolib.cmake -D PKG_GP
|
|||
</dl>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><code>LAMMPS_OMP_COMPAT</code></td>
|
||||
<td>Workaround for backwards-incompatible changes regarding predetermined sharing modes in OpenMP 4.x. A value of 3 or 4 should be used, reflecting the version of the OpenMP spec that is implemented by the compiler.</td>
|
||||
<td>
|
||||
<dl>
|
||||
<dt><code>3</code> (default except for known OMP 4.0 compilers)</dt>
|
||||
<dt><code>4</code></dt>
|
||||
</dl>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><code>LAMMPS_MEMALIGN</code></td>
|
||||
<td>controls the alignment of blocks of memory allocated by LAMMPS</td>
|
||||
|
|
|
@ -142,14 +142,15 @@ please refer to its documentation.
|
|||
**OpenMP Compiler compatibility info**\ :
|
||||
|
||||
Some compilers do not fully support the ``default(none)`` directive
|
||||
and others (e.g. GCC version 9 and beyond) may implement OpenMP 4.0
|
||||
semantics, which are incompatible with the OpenMP 3.1 semantics used
|
||||
in LAMMPS (for maximal compatibility with compiler versions in use).
|
||||
In those case, all ``default(none)`` directives (which aid in detecting
|
||||
incorrect and unwanted sharing) can be replaced with ``default(shared)``
|
||||
while dropping all ``shared()`` directives. The script
|
||||
'src/USER-OMP/hack_openmp_for_pgi_gcc9.sh' can be used to automate
|
||||
this conversion.
|
||||
and others (e.g. GCC version 9 and beyond, Clang version 10 and later)
|
||||
may implement strict OpenMP 4.0 and later semantics, which are incompatible
|
||||
with the OpenMP 3.1 semantics used in LAMMPS for maximal compatibility
|
||||
with compiler versions in use. If compilation with OpenMP enabled fails
|
||||
because of your compiler requiring strict OpenMP 4.0 semantic, you can
|
||||
change the behavior by adding ``-D LAMMPS_OMP_COMPAT=4`` to the ``LMP_INC``
|
||||
variable in your makefile, or add it to the command line while configuring
|
||||
with CMake. CMake will detect the suitable setting for the GNU, Clang,
|
||||
and Intel compilers.
|
||||
|
||||
----------
|
||||
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Paul Coffman (IBM)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "dump_atom_mpiio.h"
|
||||
#include <cmath>
|
||||
#include <cstdlib>
|
||||
|
@ -587,7 +588,7 @@ int DumpAtomMPIIO::convert_image_omp(int n, double *mybuf)
|
|||
mpifh_buffer_line_per_thread[i] = (char *) malloc(DUMP_BUF_CHUNK_SIZE * sizeof(char));
|
||||
mpifh_buffer_line_per_thread[i][0] = '\0';
|
||||
|
||||
#pragma omp parallel default(none) shared(bufOffset, bufRange, bufLength, mpifhStringCountPerThread, mpifh_buffer_line_per_thread, mybuf)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(bufOffset, bufRange, bufLength, mpifhStringCountPerThread, mpifh_buffer_line_per_thread, mybuf)
|
||||
{
|
||||
int tid = omp_get_thread_num();
|
||||
int m=0;
|
||||
|
@ -677,7 +678,7 @@ int DumpAtomMPIIO::convert_noimage_omp(int n, double *mybuf)
|
|||
mpifh_buffer_line_per_thread[i] = (char *) malloc(DUMP_BUF_CHUNK_SIZE * sizeof(char));
|
||||
mpifh_buffer_line_per_thread[i][0] = '\0';
|
||||
|
||||
#pragma omp parallel default(none) shared(bufOffset, bufRange, bufLength, mpifhStringCountPerThread, mpifh_buffer_line_per_thread, mybuf)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(bufOffset, bufRange, bufLength, mpifhStringCountPerThread, mpifh_buffer_line_per_thread, mybuf)
|
||||
{
|
||||
int tid = omp_get_thread_num();
|
||||
int m=0;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Paul Coffman (IBM)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "dump_cfg_mpiio.h"
|
||||
#include <cmath>
|
||||
#include <cstdlib>
|
||||
|
@ -365,7 +366,7 @@ int DumpCFGMPIIO::convert_string_omp(int n, double *mybuf)
|
|||
mpifh_buffer_line_per_thread[i] = (char *) malloc(DUMP_BUF_CHUNK_SIZE * sizeof(char));
|
||||
mpifh_buffer_line_per_thread[i][0] = '\0';
|
||||
|
||||
#pragma omp parallel default(none) shared(bufOffset, bufRange, bufLength, mpifhStringCountPerThread, mpifh_buffer_line_per_thread, mybuf)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(bufOffset, bufRange, bufLength, mpifhStringCountPerThread, mpifh_buffer_line_per_thread, mybuf)
|
||||
{
|
||||
int tid = omp_get_thread_num();
|
||||
int m=0;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Paul Coffman (IBM)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "dump_custom_mpiio.h"
|
||||
#include <cmath>
|
||||
#include <cstdlib>
|
||||
|
@ -612,7 +613,7 @@ int DumpCustomMPIIO::convert_string_omp(int n, double *mybuf)
|
|||
mpifh_buffer_line_per_thread[i] = (char *) malloc(DUMP_BUF_CHUNK_SIZE * sizeof(char));
|
||||
mpifh_buffer_line_per_thread[i][0] = '\0';
|
||||
|
||||
#pragma omp parallel default(none) shared(bufOffset, bufRange, bufLength, mpifhStringCountPerThread, mpifh_buffer_line_per_thread, mybuf)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(bufOffset, bufRange, bufLength, mpifhStringCountPerThread, mpifh_buffer_line_per_thread, mybuf)
|
||||
{
|
||||
int tid = omp_get_thread_num();
|
||||
int m=0;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Paul Coffman (IBM)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "dump_xyz_mpiio.h"
|
||||
#include <cmath>
|
||||
#include <cstdlib>
|
||||
|
@ -350,7 +351,7 @@ int DumpXYZMPIIO::convert_string_omp(int n, double *mybuf)
|
|||
mpifh_buffer_line_per_thread[i] = (char *) malloc(DUMP_BUF_CHUNK_SIZE * sizeof(char));
|
||||
mpifh_buffer_line_per_thread[i][0] = '\0';
|
||||
|
||||
#pragma omp parallel default(none) shared(bufOffset, bufRange, bufLength, mpifhStringCountPerThread, mpifh_buffer_line_per_thread, mybuf)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(bufOffset, bufRange, bufLength, mpifhStringCountPerThread, mpifh_buffer_line_per_thread, mybuf)
|
||||
{
|
||||
int tid = omp_get_thread_num();
|
||||
int m=0;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing authors: Shawn Coleman & Douglas Spearot (Arkansas)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "compute_saed.h"
|
||||
#include <mpi.h>
|
||||
#include <cmath>
|
||||
|
@ -418,7 +419,7 @@ void ComputeSAED::compute_vector()
|
|||
double frac = 0.1;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(offset,ASFSAED,typelocal,xlocal,Fvec,m,frac)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(offset,ASFSAED,typelocal,xlocal,Fvec,m,frac)
|
||||
#endif
|
||||
{
|
||||
double *f = new double[ntypes]; // atomic structure factor by type
|
||||
|
|
|
@ -16,6 +16,7 @@
|
|||
Updated: 06/17/2015-2
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "compute_xrd.h"
|
||||
#include <mpi.h>
|
||||
#include <cmath>
|
||||
|
@ -353,7 +354,7 @@ void ComputeXRD::compute_array()
|
|||
double frac = 0.1;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(typelocal,xlocal,Fvec,m,frac,ASFXRD)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(typelocal,xlocal,Fvec,m,frac,ASFXRD)
|
||||
#endif
|
||||
{
|
||||
double *f = new double[ntypes]; // atomic structure factor by type
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: W. Michael Brown (Intel)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include <cmath>
|
||||
#include <cstdlib>
|
||||
#include "angle_charmm_intel.h"
|
||||
|
@ -134,7 +135,7 @@ void AngleCharmmIntel::eval(const int vflag,
|
|||
}
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) \
|
||||
#pragma omp parallel LMP_DEFAULT_NONE \
|
||||
shared(f_start,f_stride,fc) \
|
||||
reduction(+:oeangle,ov0,ov1,ov2,ov3,ov4,ov5)
|
||||
#endif
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: W. Michael Brown (Intel)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include <cmath>
|
||||
#include <cstdlib>
|
||||
#include "angle_harmonic_intel.h"
|
||||
|
@ -134,7 +135,7 @@ void AngleHarmonicIntel::eval(const int vflag,
|
|||
}
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) \
|
||||
#pragma omp parallel LMP_DEFAULT_NONE \
|
||||
shared(f_start,f_stride,fc) \
|
||||
reduction(+:oeangle,ov0,ov1,ov2,ov3,ov4,ov5)
|
||||
#endif
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Stan Moore (Sandia)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include <cmath>
|
||||
#include <cstdlib>
|
||||
#include "bond_fene_intel.h"
|
||||
|
@ -127,7 +128,7 @@ void BondFENEIntel::eval(const int vflag,
|
|||
}
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) \
|
||||
#pragma omp parallel LMP_DEFAULT_NONE \
|
||||
shared(f_start,f_stride,fc) \
|
||||
reduction(+:oebond,ov0,ov1,ov2,ov3,ov4,ov5)
|
||||
#endif
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: W. Michael Brown (Intel)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include <cmath>
|
||||
#include <cstdlib>
|
||||
#include "bond_harmonic_intel.h"
|
||||
|
@ -127,7 +128,7 @@ void BondHarmonicIntel::eval(const int vflag,
|
|||
}
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) \
|
||||
#pragma omp parallel LMP_DEFAULT_NONE \
|
||||
shared(f_start,f_stride,fc) \
|
||||
reduction(+:oebond,ov0,ov1,ov2,ov3,ov4,ov5)
|
||||
#endif
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: W. Michael Brown (Intel)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include <mpi.h>
|
||||
#include <cmath>
|
||||
#include "dihedral_charmm_intel.h"
|
||||
|
@ -148,7 +149,7 @@ void DihedralCharmmIntel::eval(const int vflag,
|
|||
}
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) \
|
||||
#pragma omp parallel LMP_DEFAULT_NONE \
|
||||
shared(f_start,f_stride,fc) \
|
||||
reduction(+:oevdwl,oecoul,oedihedral,ov0,ov1,ov2,ov3,ov4,ov5, \
|
||||
opv0,opv1,opv2,opv3,opv4,opv5)
|
||||
|
@ -522,7 +523,7 @@ void DihedralCharmmIntel::eval(const int vflag,
|
|||
}
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) \
|
||||
#pragma omp parallel LMP_DEFAULT_NONE \
|
||||
shared(f_start,f_stride,fc) \
|
||||
reduction(+:oevdwl,oecoul,oedihedral,ov0,ov1,ov2,ov3,ov4,ov5, \
|
||||
opv0,opv1,opv2,opv3,opv4,opv5)
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: W. Michael Brown (Intel)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include <mpi.h>
|
||||
#include <cmath>
|
||||
#include "dihedral_fourier_intel.h"
|
||||
|
@ -127,7 +128,7 @@ void DihedralFourierIntel::eval(const int vflag,
|
|||
}
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) \
|
||||
#pragma omp parallel LMP_DEFAULT_NONE \
|
||||
shared(f_start,f_stride,fc) \
|
||||
reduction(+:oedihedral,ov0,ov1,ov2,ov3,ov4,ov5)
|
||||
#endif
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: W. Michael Brown (Intel)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include <mpi.h>
|
||||
#include <cmath>
|
||||
#include "dihedral_harmonic_intel.h"
|
||||
|
@ -127,7 +128,7 @@ void DihedralHarmonicIntel::eval(const int vflag,
|
|||
}
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) \
|
||||
#pragma omp parallel LMP_DEFAULT_NONE \
|
||||
shared(f_start,f_stride,fc) \
|
||||
reduction(+:oedihedral,ov0,ov1,ov2,ov3,ov4,ov5)
|
||||
#endif
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: W. Michael Brown (Intel)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include <mpi.h>
|
||||
#include <cmath>
|
||||
#include "dihedral_opls_intel.h"
|
||||
|
@ -131,7 +132,7 @@ void DihedralOPLSIntel::eval(const int vflag,
|
|||
}
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) \
|
||||
#pragma omp parallel LMP_DEFAULT_NONE \
|
||||
shared(f_start,f_stride,fc) \
|
||||
reduction(+:oedihedral,ov0,ov1,ov2,ov3,ov4,ov5)
|
||||
#endif
|
||||
|
|
|
@ -16,6 +16,7 @@
|
|||
Anupama Kurpad (Intel) - Host Affinitization
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "fix_intel.h"
|
||||
#include "comm.h"
|
||||
#include "error.h"
|
||||
|
@ -220,7 +221,7 @@ FixIntel::FixIntel(LAMMPS *lmp, int narg, char **arg) : Fix(lmp, narg, arg)
|
|||
comm->nthreads = nomp;
|
||||
} else {
|
||||
int nthreads;
|
||||
#pragma omp parallel default(none) shared(nthreads)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(nthreads)
|
||||
nthreads = omp_get_num_threads();
|
||||
comm->nthreads = nthreads;
|
||||
}
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: W. Michael Brown (Intel)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include <mpi.h>
|
||||
#include <cmath>
|
||||
#include <cstdlib>
|
||||
|
@ -138,7 +139,7 @@ void ImproperCvffIntel::eval(const int vflag,
|
|||
}
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) \
|
||||
#pragma omp parallel LMP_DEFAULT_NONE \
|
||||
shared(f_start,f_stride,fc) \
|
||||
reduction(+:oeimproper,ov0,ov1,ov2,ov3,ov4,ov5)
|
||||
#endif
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: W. Michael Brown (Intel)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include <mpi.h>
|
||||
#include <cmath>
|
||||
#include <cstdlib>
|
||||
|
@ -139,7 +140,7 @@ void ImproperHarmonicIntel::eval(const int vflag,
|
|||
}
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) \
|
||||
#pragma omp parallel LMP_DEFAULT_NONE \
|
||||
shared(f_start,f_stride,fc) \
|
||||
reduction(+:oeimproper,ov0,ov1,ov2,ov3,ov4,ov5)
|
||||
#endif
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: W. Michael Brown (Intel)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "comm.h"
|
||||
#include "domain.h"
|
||||
#include "timer.h"
|
||||
|
@ -263,7 +264,7 @@ void NPairIntel::bin_newton(const int offload, NeighList *list,
|
|||
}
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) \
|
||||
#pragma omp parallel LMP_DEFAULT_NONE \
|
||||
shared(overflow, nstencilp, binstart, binend)
|
||||
#endif
|
||||
{
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing authors: William McDoniel (RWTH Aachen University)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include <mpi.h>
|
||||
#include <cstdlib>
|
||||
#include <cmath>
|
||||
|
@ -729,7 +730,7 @@ void PPPMDispIntel::particle_map(double delx, double dely, double delz,
|
|||
int flag = 0;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) \
|
||||
#pragma omp parallel LMP_DEFAULT_NONE \
|
||||
shared(nlocal, nthr, delx, dely, delz, sft, p2g, nup, nlow, nxlo,\
|
||||
nylo, nzlo, nxhi, nyhi, nzhi) reduction(+:flag) if(!_use_lrt)
|
||||
#endif
|
||||
|
@ -803,7 +804,7 @@ void PPPMDispIntel::make_rho_c(IntelBuffers<flt_t,acc_t> * /*buffers*/)
|
|||
int nthr = comm->nthreads;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) \
|
||||
#pragma omp parallel LMP_DEFAULT_NONE \
|
||||
shared(nthr, nlocal, global_density) if(!_use_lrt)
|
||||
#endif
|
||||
{
|
||||
|
@ -909,7 +910,7 @@ void PPPMDispIntel::make_rho_c(IntelBuffers<flt_t,acc_t> * /*buffers*/)
|
|||
|
||||
// reduce all the perthread_densities into global_density
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) \
|
||||
#pragma omp parallel LMP_DEFAULT_NONE \
|
||||
shared(nthr, global_density) if(!_use_lrt)
|
||||
#endif
|
||||
{
|
||||
|
@ -951,7 +952,7 @@ void PPPMDispIntel::make_rho_g(IntelBuffers<flt_t,acc_t> * /*buffers*/)
|
|||
int nthr = comm->nthreads;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) \
|
||||
#pragma omp parallel LMP_DEFAULT_NONE \
|
||||
shared(nthr, nlocal, global_density) if(!_use_lrt)
|
||||
#endif
|
||||
{
|
||||
|
@ -1059,7 +1060,7 @@ void PPPMDispIntel::make_rho_g(IntelBuffers<flt_t,acc_t> * /*buffers*/)
|
|||
|
||||
// reduce all the perthread_densities into global_density
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) \
|
||||
#pragma omp parallel LMP_DEFAULT_NONE \
|
||||
shared(nthr, global_density) if(!_use_lrt)
|
||||
#endif
|
||||
{
|
||||
|
@ -1234,7 +1235,7 @@ void PPPMDispIntel::make_rho_none(IntelBuffers<flt_t,acc_t> * /*buffers*/)
|
|||
int nthr = comm->nthreads;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) \
|
||||
#pragma omp parallel LMP_DEFAULT_NONE \
|
||||
shared(nthr, nlocal, global_density) if(!_use_lrt)
|
||||
#endif
|
||||
{
|
||||
|
@ -1343,7 +1344,7 @@ void PPPMDispIntel::make_rho_none(IntelBuffers<flt_t,acc_t> * /*buffers*/)
|
|||
|
||||
// reduce all the perthread_densities into global_density
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) \
|
||||
#pragma omp parallel LMP_DEFAULT_NONE \
|
||||
shared(nthr, global_density) if(!_use_lrt)
|
||||
#endif
|
||||
{
|
||||
|
@ -1386,7 +1387,7 @@ void PPPMDispIntel::fieldforce_c_ik(IntelBuffers<flt_t,acc_t> * /*buffers*/)
|
|||
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) \
|
||||
#pragma omp parallel LMP_DEFAULT_NONE \
|
||||
shared(nlocal, nthr) if(!_use_lrt)
|
||||
#endif
|
||||
{
|
||||
|
@ -1536,7 +1537,7 @@ void PPPMDispIntel::fieldforce_c_ad(IntelBuffers<flt_t,acc_t> * /*buffers*/)
|
|||
FFT_SCALAR * _noalias const particle_ekz = this->particle_ekz;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) \
|
||||
#pragma omp parallel LMP_DEFAULT_NONE \
|
||||
shared(nlocal, nthr) if(!_use_lrt)
|
||||
#endif
|
||||
{
|
||||
|
@ -1734,7 +1735,7 @@ void PPPMDispIntel::fieldforce_g_ik(IntelBuffers<flt_t,acc_t> * /*buffers*/)
|
|||
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) \
|
||||
#pragma omp parallel LMP_DEFAULT_NONE \
|
||||
shared(nlocal, nthr) if(!_use_lrt)
|
||||
#endif
|
||||
{
|
||||
|
@ -1881,7 +1882,7 @@ void PPPMDispIntel::fieldforce_g_ad(IntelBuffers<flt_t,acc_t> * /*buffers*/)
|
|||
FFT_SCALAR * _noalias const particle_ekz = this->particle_ekz;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) \
|
||||
#pragma omp parallel LMP_DEFAULT_NONE \
|
||||
shared(nlocal, nthr) if(!_use_lrt)
|
||||
#endif
|
||||
{
|
||||
|
@ -2078,7 +2079,7 @@ void PPPMDispIntel::fieldforce_a_ik(IntelBuffers<flt_t,acc_t> * /*buffers*/)
|
|||
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) \
|
||||
#pragma omp parallel LMP_DEFAULT_NONE \
|
||||
shared(nlocal, nthr) if(!_use_lrt)
|
||||
#endif
|
||||
{
|
||||
|
@ -2312,7 +2313,7 @@ void PPPMDispIntel::fieldforce_a_ad(IntelBuffers<flt_t,acc_t> * /*buffers*/)
|
|||
FFT_SCALAR * _noalias const particle_ekz6 = this->particle_ekz6;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) \
|
||||
#pragma omp parallel LMP_DEFAULT_NONE \
|
||||
shared(nlocal, nthr) if(!_use_lrt)
|
||||
#endif
|
||||
{
|
||||
|
@ -2603,7 +2604,7 @@ void PPPMDispIntel::fieldforce_none_ik(IntelBuffers<flt_t,acc_t> * /*buffers*/)
|
|||
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) \
|
||||
#pragma omp parallel LMP_DEFAULT_NONE \
|
||||
shared(nlocal, nthr) if(!_use_lrt)
|
||||
#endif
|
||||
{
|
||||
|
@ -2762,7 +2763,7 @@ void PPPMDispIntel::fieldforce_none_ad(IntelBuffers<flt_t,acc_t> * /*buffers*/)
|
|||
int nthr = comm->nthreads;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) \
|
||||
#pragma omp parallel LMP_DEFAULT_NONE \
|
||||
shared(nlocal, nthr) if(!_use_lrt)
|
||||
#endif
|
||||
{
|
||||
|
|
|
@ -18,6 +18,7 @@
|
|||
W. Michael Brown (Intel)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include <mpi.h>
|
||||
#include <cstdlib>
|
||||
#include <cmath>
|
||||
|
@ -372,7 +373,7 @@ void PPPMIntel::particle_map(IntelBuffers<flt_t,acc_t> *buffers)
|
|||
error->one(FLERR,"Non-numeric box dimensions - simulation unstable");
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) \
|
||||
#pragma omp parallel LMP_DEFAULT_NONE \
|
||||
shared(nlocal, nthr) reduction(+:flag) if(!_use_lrt)
|
||||
#endif
|
||||
{
|
||||
|
@ -446,7 +447,7 @@ void PPPMIntel::make_rho(IntelBuffers<flt_t,acc_t> *buffers)
|
|||
nthr = comm->nthreads;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) \
|
||||
#pragma omp parallel LMP_DEFAULT_NONE \
|
||||
shared(nthr, nlocal, global_density) if(!_use_lrt)
|
||||
#endif
|
||||
{
|
||||
|
@ -549,7 +550,7 @@ void PPPMIntel::make_rho(IntelBuffers<flt_t,acc_t> *buffers)
|
|||
// reduce all the perthread_densities into global_density
|
||||
if (nthr > 1) {
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) \
|
||||
#pragma omp parallel LMP_DEFAULT_NONE \
|
||||
shared(nthr, global_density) if(!_use_lrt)
|
||||
#endif
|
||||
{
|
||||
|
@ -598,7 +599,7 @@ void PPPMIntel::fieldforce_ik(IntelBuffers<flt_t,acc_t> *buffers)
|
|||
}
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) \
|
||||
#pragma omp parallel LMP_DEFAULT_NONE \
|
||||
shared(nlocal, nthr) if(!_use_lrt)
|
||||
#endif
|
||||
{
|
||||
|
@ -749,7 +750,7 @@ void PPPMIntel::fieldforce_ad(IntelBuffers<flt_t,acc_t> *buffers)
|
|||
}
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) \
|
||||
#pragma omp parallel LMP_DEFAULT_NONE \
|
||||
shared(nlocal, nthr) if(!_use_lrt)
|
||||
#endif
|
||||
{
|
||||
|
|
|
@ -9,11 +9,3 @@ doc/Section_accelerate.html, sub-section 5.2
|
|||
The person who created this package is Axel Kohlmeyer at Temple U
|
||||
(akohlmey at gmail.com). Contact him directly if you have questions.
|
||||
|
||||
--------------------------
|
||||
|
||||
This directory also contains a shell script:
|
||||
|
||||
hack_openmp_for_pgi.sh
|
||||
|
||||
which will convert OpenMP directives in src files
|
||||
into a form compatible with the PGI compiler.
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "angle_charmm_omp.h"
|
||||
#include <cmath>
|
||||
#include "atom.h"
|
||||
|
@ -47,7 +48,7 @@ void AngleCharmmOMP::compute(int eflag, int vflag)
|
|||
const int inum = neighbor->nanglelist;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
int ifrom, ito, tid;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "angle_class2_omp.h"
|
||||
#include <cmath>
|
||||
#include "atom.h"
|
||||
|
@ -47,7 +48,7 @@ void AngleClass2OMP::compute(int eflag, int vflag)
|
|||
const int inum = neighbor->nanglelist;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
int ifrom, ito, tid;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "angle_cosine_delta_omp.h"
|
||||
#include <cmath>
|
||||
#include "atom.h"
|
||||
|
@ -47,7 +48,7 @@ void AngleCosineDeltaOMP::compute(int eflag, int vflag)
|
|||
const int inum = neighbor->nanglelist;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
int ifrom, ito, tid;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "angle_cosine_omp.h"
|
||||
#include <cmath>
|
||||
#include "atom.h"
|
||||
|
@ -47,7 +48,7 @@ void AngleCosineOMP::compute(int eflag, int vflag)
|
|||
const int inum = neighbor->nanglelist;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
int ifrom, ito, tid;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "angle_cosine_periodic_omp.h"
|
||||
#include <cmath>
|
||||
#include "atom.h"
|
||||
|
@ -49,7 +50,7 @@ void AngleCosinePeriodicOMP::compute(int eflag, int vflag)
|
|||
const int inum = neighbor->nanglelist;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
int ifrom, ito, tid;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "angle_cosine_shift_exp_omp.h"
|
||||
#include <cmath>
|
||||
#include "atom.h"
|
||||
|
@ -47,7 +48,7 @@ void AngleCosineShiftExpOMP::compute(int eflag, int vflag)
|
|||
const int inum = neighbor->nanglelist;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
int ifrom, ito, tid;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "angle_cosine_shift_omp.h"
|
||||
#include <cmath>
|
||||
#include "atom.h"
|
||||
|
@ -47,7 +48,7 @@ void AngleCosineShiftOMP::compute(int eflag, int vflag)
|
|||
const int inum = neighbor->nanglelist;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
int ifrom, ito, tid;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "angle_cosine_squared_omp.h"
|
||||
#include <cmath>
|
||||
#include "atom.h"
|
||||
|
@ -47,7 +48,7 @@ void AngleCosineSquaredOMP::compute(int eflag, int vflag)
|
|||
const int inum = neighbor->nanglelist;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
int ifrom, ito, tid;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "angle_dipole_omp.h"
|
||||
#include <cmath>
|
||||
#include "atom.h"
|
||||
|
@ -51,7 +52,7 @@ void AngleDipoleOMP::compute(int eflag, int vflag)
|
|||
const int inum = neighbor->nanglelist;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
int ifrom, ito, tid;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "angle_fourier_omp.h"
|
||||
#include <cmath>
|
||||
#include "atom.h"
|
||||
|
@ -47,7 +48,7 @@ void AngleFourierOMP::compute(int eflag, int vflag)
|
|||
const int inum = neighbor->nanglelist;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
int ifrom, ito, tid;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "angle_fourier_simple_omp.h"
|
||||
#include <cmath>
|
||||
#include "atom.h"
|
||||
|
@ -47,7 +48,7 @@ void AngleFourierSimpleOMP::compute(int eflag, int vflag)
|
|||
const int inum = neighbor->nanglelist;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
int ifrom, ito, tid;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "angle_harmonic_omp.h"
|
||||
#include <cmath>
|
||||
#include "atom.h"
|
||||
|
@ -47,7 +48,7 @@ void AngleHarmonicOMP::compute(int eflag, int vflag)
|
|||
const int inum = neighbor->nanglelist;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
int ifrom, ito, tid;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "angle_quartic_omp.h"
|
||||
#include <cmath>
|
||||
#include "atom.h"
|
||||
|
@ -47,7 +48,7 @@ void AngleQuarticOMP::compute(int eflag, int vflag)
|
|||
const int inum = neighbor->nanglelist;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
int ifrom, ito, tid;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "angle_sdk_omp.h"
|
||||
#include <cmath>
|
||||
#include "atom.h"
|
||||
|
@ -49,7 +50,7 @@ void AngleSDKOMP::compute(int eflag, int vflag)
|
|||
const int inum = neighbor->nanglelist;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
int ifrom, ito, tid;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "angle_table_omp.h"
|
||||
#include <cmath>
|
||||
#include "atom.h"
|
||||
|
@ -47,7 +48,7 @@ void AngleTableOMP::compute(int eflag, int vflag)
|
|||
const int inum = neighbor->nanglelist;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
int ifrom, ito, tid;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "bond_class2_omp.h"
|
||||
#include "atom.h"
|
||||
#include "comm.h"
|
||||
|
@ -47,7 +48,7 @@ void BondClass2OMP::compute(int eflag, int vflag)
|
|||
const int inum = neighbor->nbondlist;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
int ifrom, ito, tid;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "bond_fene_expand_omp.h"
|
||||
#include "atom.h"
|
||||
#include "comm.h"
|
||||
|
@ -48,7 +49,7 @@ void BondFENEExpandOMP::compute(int eflag, int vflag)
|
|||
const int inum = neighbor->nbondlist;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
int ifrom, ito, tid;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "bond_fene_omp.h"
|
||||
#include "atom.h"
|
||||
#include "comm.h"
|
||||
|
@ -48,7 +49,7 @@ void BondFENEOMP::compute(int eflag, int vflag)
|
|||
const int inum = neighbor->nbondlist;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
int ifrom, ito, tid;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "bond_gromos_omp.h"
|
||||
#include "atom.h"
|
||||
#include "comm.h"
|
||||
|
@ -44,7 +45,7 @@ void BondGromosOMP::compute(int eflag, int vflag)
|
|||
const int inum = neighbor->nbondlist;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
int ifrom, ito, tid;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "bond_harmonic_omp.h"
|
||||
#include "atom.h"
|
||||
#include "comm.h"
|
||||
|
@ -46,7 +47,7 @@ void BondHarmonicOMP::compute(int eflag, int vflag)
|
|||
const int inum = neighbor->nbondlist;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
int ifrom, ito, tid;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "bond_harmonic_shift_cut_omp.h"
|
||||
#include "atom.h"
|
||||
#include "comm.h"
|
||||
|
@ -46,7 +47,7 @@ void BondHarmonicShiftCutOMP::compute(int eflag, int vflag)
|
|||
const int inum = neighbor->nbondlist;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
int ifrom, ito, tid;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "bond_harmonic_shift_omp.h"
|
||||
#include "atom.h"
|
||||
#include "comm.h"
|
||||
|
@ -46,7 +47,7 @@ void BondHarmonicShiftOMP::compute(int eflag, int vflag)
|
|||
const int inum = neighbor->nbondlist;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
int ifrom, ito, tid;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "bond_morse_omp.h"
|
||||
#include "atom.h"
|
||||
#include "comm.h"
|
||||
|
@ -46,7 +47,7 @@ void BondMorseOMP::compute(int eflag, int vflag)
|
|||
const int inum = neighbor->nbondlist;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
int ifrom, ito, tid;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "bond_nonlinear_omp.h"
|
||||
#include "atom.h"
|
||||
#include "comm.h"
|
||||
|
@ -46,7 +47,7 @@ void BondNonlinearOMP::compute(int eflag, int vflag)
|
|||
const int inum = neighbor->nbondlist;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
int ifrom, ito, tid;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "bond_quartic_omp.h"
|
||||
#include "atom.h"
|
||||
#include "comm.h"
|
||||
|
@ -52,7 +53,7 @@ void BondQuarticOMP::compute(int eflag, int vflag)
|
|||
const int inum = neighbor->nbondlist;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
int ifrom, ito, tid;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "bond_table_omp.h"
|
||||
#include "atom.h"
|
||||
#include "comm.h"
|
||||
|
@ -46,7 +47,7 @@ void BondTableOMP::compute(int eflag, int vflag)
|
|||
const int inum = neighbor->nbondlist;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
int ifrom, ito, tid;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "dihedral_charmm_omp.h"
|
||||
#include <cmath>
|
||||
#include "atom.h"
|
||||
|
@ -56,7 +57,7 @@ void DihedralCharmmOMP::compute(int eflag, int vflag)
|
|||
const int inum = neighbor->ndihedrallist;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
int ifrom, ito, tid;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include <cmath>
|
||||
#include "dihedral_class2_omp.h"
|
||||
#include "atom.h"
|
||||
|
@ -50,7 +51,7 @@ void DihedralClass2OMP::compute(int eflag, int vflag)
|
|||
const int inum = neighbor->ndihedrallist;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
int ifrom, ito, tid;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include <cmath>
|
||||
#include "dihedral_cosine_shift_exp_omp.h"
|
||||
#include "atom.h"
|
||||
|
@ -50,7 +51,7 @@ void DihedralCosineShiftExpOMP::compute(int eflag, int vflag)
|
|||
const int inum = neighbor->ndihedrallist;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
int ifrom, ito, tid;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "dihedral_fourier_omp.h"
|
||||
#include <cmath>
|
||||
#include "atom.h"
|
||||
|
@ -49,7 +50,7 @@ void DihedralFourierOMP::compute(int eflag, int vflag)
|
|||
const int inum = neighbor->ndihedrallist;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
int ifrom, ito, tid;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include <cmath>
|
||||
#include "dihedral_harmonic_omp.h"
|
||||
#include "atom.h"
|
||||
|
@ -50,7 +51,7 @@ void DihedralHarmonicOMP::compute(int eflag, int vflag)
|
|||
const int inum = neighbor->ndihedrallist;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
int ifrom, ito, tid;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include <cmath>
|
||||
#include "dihedral_helix_omp.h"
|
||||
#include "atom.h"
|
||||
|
@ -53,7 +54,7 @@ void DihedralHelixOMP::compute(int eflag, int vflag)
|
|||
const int inum = neighbor->ndihedrallist;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
int ifrom, ito, tid;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include <cmath>
|
||||
#include "dihedral_multi_harmonic_omp.h"
|
||||
#include "atom.h"
|
||||
|
@ -50,7 +51,7 @@ void DihedralMultiHarmonicOMP::compute(int eflag, int vflag)
|
|||
const int inum = neighbor->ndihedrallist;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
int ifrom, ito, tid;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include <cmath>
|
||||
#include "dihedral_nharmonic_omp.h"
|
||||
#include "atom.h"
|
||||
|
@ -50,7 +51,7 @@ void DihedralNHarmonicOMP::compute(int eflag, int vflag)
|
|||
const int inum = neighbor->ndihedrallist;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
int ifrom, ito, tid;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include <cmath>
|
||||
#include "dihedral_opls_omp.h"
|
||||
#include "atom.h"
|
||||
|
@ -51,7 +52,7 @@ void DihedralOPLSOMP::compute(int eflag, int vflag)
|
|||
const int inum = neighbor->ndihedrallist;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
int ifrom, ito, tid;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include <cmath>
|
||||
#include "dihedral_quadratic_omp.h"
|
||||
#include "atom.h"
|
||||
|
@ -51,7 +52,7 @@ void DihedralQuadraticOMP::compute(int eflag, int vflag)
|
|||
const int inum = neighbor->ndihedrallist;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
int ifrom, ito, tid;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "dihedral_table_omp.h"
|
||||
#include <cmath>
|
||||
#include "atom.h"
|
||||
|
@ -113,7 +114,7 @@ void DihedralTableOMP::compute(int eflag, int vflag)
|
|||
const int inum = neighbor->ndihedrallist;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
int ifrom, ito, tid;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author : Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "accelerator_omp.h"
|
||||
#include "atom.h"
|
||||
|
||||
|
@ -45,7 +46,7 @@ void DomainOMP::pbc()
|
|||
const int nlocal = atom->nlocal;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none) schedule(static)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE schedule(static)
|
||||
#endif
|
||||
for (int i = 0; i < nlocal; i++) {
|
||||
imageint idim,otherdims;
|
||||
|
@ -143,7 +144,7 @@ void DomainOMP::lamda2x(int n)
|
|||
const int num = n;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none) schedule(static)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE schedule(static)
|
||||
#endif
|
||||
for (int i = 0; i < num; i++) {
|
||||
x[i].x = h[0]*x[i].x + h[5]*x[i].y + h[4]*x[i].z + boxlo[0];
|
||||
|
@ -163,7 +164,7 @@ void DomainOMP::x2lamda(int n)
|
|||
const int num = n;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none) schedule(static)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE schedule(static)
|
||||
#endif
|
||||
for (int i = 0; i < num; i++) {
|
||||
double delta0 = x[i].x - boxlo[0];
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing authors: Roy Pollock (LLNL), Paul Crozier (SNL)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "ewald_omp.h"
|
||||
#include <mpi.h>
|
||||
#include <cmath>
|
||||
|
@ -104,7 +105,7 @@ void EwaldOMP::compute(int eflag, int vflag)
|
|||
v0=v1=v2=v3=v4=v5=0.0;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag) reduction(+:eng_tmp,v0,v1,v2,v3,v4,v5)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag) reduction(+:eng_tmp,v0,v1,v2,v3,v4,v5)
|
||||
#endif
|
||||
{
|
||||
|
||||
|
@ -234,7 +235,7 @@ void EwaldOMP::eik_dot_r()
|
|||
const int nthreads = comm->nthreads;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE
|
||||
#endif
|
||||
{
|
||||
int i,ifrom,ito,k,l,m,n,ic,tid;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "fix_gravity_omp.h"
|
||||
#include "atom.h"
|
||||
#include "update.h"
|
||||
|
@ -69,7 +70,7 @@ void FixGravityOMP::post_force(int /* vflag */)
|
|||
|
||||
if (rmass) {
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none) reduction(-:grav)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE reduction(-:grav)
|
||||
#endif
|
||||
for (int i = 0; i < nlocal; i++)
|
||||
if (mask[i] & groupbit) {
|
||||
|
@ -81,7 +82,7 @@ void FixGravityOMP::post_force(int /* vflag */)
|
|||
}
|
||||
} else {
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none) reduction(-:grav)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE reduction(-:grav)
|
||||
#endif
|
||||
for (int i = 0; i < nlocal; i++)
|
||||
if (mask[i] & groupbit) {
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
See the README file in the top-level LAMMPS directory.
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "fix_neigh_history_omp.h"
|
||||
#include <cstring>
|
||||
#include "my_page.h"
|
||||
|
@ -73,7 +74,7 @@ void FixNeighHistoryOMP::pre_exchange_onesided()
|
|||
maxpartner = 0;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE
|
||||
#endif
|
||||
{
|
||||
|
||||
|
@ -199,7 +200,7 @@ void FixNeighHistoryOMP::pre_exchange_newton()
|
|||
for (int i = 0; i < nall_neigh; i++) npartner[i] = 0;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE
|
||||
#endif
|
||||
{
|
||||
|
||||
|
@ -373,7 +374,7 @@ void FixNeighHistoryOMP::pre_exchange_no_newton()
|
|||
maxpartner = 0;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE
|
||||
#endif
|
||||
{
|
||||
|
||||
|
@ -525,7 +526,7 @@ void FixNeighHistoryOMP::post_neighbor()
|
|||
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE
|
||||
#endif
|
||||
{
|
||||
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include <cstring>
|
||||
#include <cstdlib>
|
||||
#include <cmath>
|
||||
|
@ -82,7 +83,7 @@ void FixNHAsphereOMP::nve_v()
|
|||
// merged with FixNHOMP instead of calling it for the COM update.
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none) schedule(static)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE schedule(static)
|
||||
#endif
|
||||
for (int i = 0; i < nlocal; i++) {
|
||||
if (mask[i] & groupbit) {
|
||||
|
@ -122,7 +123,7 @@ void FixNHAsphereOMP::nve_x()
|
|||
// principal moments of inertia
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none) schedule(static)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE schedule(static)
|
||||
#endif
|
||||
for (int i = 0; i < nlocal; i++)
|
||||
if (mask[i] & groupbit) {
|
||||
|
@ -163,7 +164,7 @@ void FixNHAsphereOMP::nh_v_temp()
|
|||
|
||||
if (which == NOBIAS) {
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none) schedule(static)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE schedule(static)
|
||||
#endif
|
||||
for (int i = 0; i < nlocal; i++) {
|
||||
if (mask[i] & groupbit) {
|
||||
|
@ -177,7 +178,7 @@ void FixNHAsphereOMP::nh_v_temp()
|
|||
}
|
||||
} else if (which == BIAS) {
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none) schedule(static)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE schedule(static)
|
||||
#endif
|
||||
for (int i = 0; i < nlocal; i++) {
|
||||
double buf[3];
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing authors: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "fix_nh_omp.h"
|
||||
#include <cmath>
|
||||
#include "atom.h"
|
||||
|
@ -57,7 +58,7 @@ void FixNHOMP::remap()
|
|||
if (allremap) domain->x2lamda(nlocal);
|
||||
else {
|
||||
#if defined (_OPENMP)
|
||||
#pragma omp parallel for default(none) schedule(static)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE schedule(static)
|
||||
#endif
|
||||
for (int i = 0; i < nlocal; i++)
|
||||
if (mask[i] & dilate_group_bit)
|
||||
|
@ -207,7 +208,7 @@ void FixNHOMP::remap()
|
|||
if (allremap) domain->lamda2x(nlocal);
|
||||
else {
|
||||
#if defined (_OPENMP)
|
||||
#pragma omp parallel for default(none) schedule(static)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE schedule(static)
|
||||
#endif
|
||||
for (int i = 0; i < nlocal; i++)
|
||||
if (mask[i] & dilate_group_bit)
|
||||
|
@ -235,7 +236,7 @@ void FixNHOMP::nh_v_press()
|
|||
|
||||
if (which == NOBIAS) {
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none) schedule(static)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE schedule(static)
|
||||
#endif
|
||||
for (int i = 0; i < nlocal; i++) {
|
||||
if (mask[i] & groupbit) {
|
||||
|
@ -253,7 +254,7 @@ void FixNHOMP::nh_v_press()
|
|||
}
|
||||
} else if (which == BIAS) {
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none) schedule(static)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE schedule(static)
|
||||
#endif
|
||||
for (int i = 0; i < nlocal; i++) {
|
||||
double buf[3];
|
||||
|
@ -289,7 +290,7 @@ void FixNHOMP::nve_v()
|
|||
if (atom->rmass) {
|
||||
const double * _noalias const rmass = atom->rmass;
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none) schedule(static)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE schedule(static)
|
||||
#endif
|
||||
for (int i = 0; i < nlocal; i++) {
|
||||
if (mask[i] & groupbit) {
|
||||
|
@ -303,7 +304,7 @@ void FixNHOMP::nve_v()
|
|||
const double *_noalias const mass = atom->mass;
|
||||
const int * _noalias const type = atom->type;
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none) schedule(static)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE schedule(static)
|
||||
#endif
|
||||
for (int i = 0; i < nlocal; i++) {
|
||||
if (mask[i] & groupbit) {
|
||||
|
@ -330,7 +331,7 @@ void FixNHOMP::nve_x()
|
|||
// x update by full step only for atoms in group
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none) schedule(static)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE schedule(static)
|
||||
#endif
|
||||
for (int i = 0; i < nlocal; i++) {
|
||||
if (mask[i] & groupbit) {
|
||||
|
@ -352,7 +353,7 @@ void FixNHOMP::nh_v_temp()
|
|||
|
||||
if (which == NOBIAS) {
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none) schedule(static)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE schedule(static)
|
||||
#endif
|
||||
for (int i = 0; i < nlocal; i++) {
|
||||
if (mask[i] & groupbit) {
|
||||
|
@ -363,7 +364,7 @@ void FixNHOMP::nh_v_temp()
|
|||
}
|
||||
} else if (which == BIAS) {
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none) schedule(static)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE schedule(static)
|
||||
#endif
|
||||
for (int i = 0; i < nlocal; i++) {
|
||||
double buf[3];
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "fix_nh_sphere_omp.h"
|
||||
#include "atom.h"
|
||||
#include "compute.h"
|
||||
|
@ -85,7 +86,7 @@ void FixNHSphereOMP::nve_v()
|
|||
// 4 cases depending on radius vs shape and rmass vs mass
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none) schedule(static)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE schedule(static)
|
||||
#endif
|
||||
for (int i = 0; i < nlocal; i++) {
|
||||
if (mask[i] & groupbit) {
|
||||
|
@ -115,7 +116,7 @@ void FixNHSphereOMP::nh_v_temp()
|
|||
|
||||
if (which == NOBIAS) {
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none) schedule(static)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE schedule(static)
|
||||
#endif
|
||||
for (int i = 0; i < nlocal; i++) {
|
||||
if (mask[i] & groupbit) {
|
||||
|
@ -129,7 +130,7 @@ void FixNHSphereOMP::nh_v_temp()
|
|||
}
|
||||
} else if (which == BIAS) {
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none) schedule(static)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE schedule(static)
|
||||
#endif
|
||||
for (int i = 0; i < nlocal; i++) {
|
||||
double buf[3];
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
See the README file in the top-level LAMMPS directory.
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "fix_nve_omp.h"
|
||||
#include "atom.h"
|
||||
|
||||
|
@ -41,7 +42,7 @@ void FixNVEOMP::initial_integrate(int /* vflag */)
|
|||
if (atom->rmass) {
|
||||
const double * const rmass = atom->rmass;
|
||||
#if defined (_OPENMP)
|
||||
#pragma omp parallel for default(none) schedule(static)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE schedule(static)
|
||||
#endif
|
||||
for (int i = 0; i < nlocal; i++)
|
||||
if (mask[i] & groupbit) {
|
||||
|
@ -58,7 +59,7 @@ void FixNVEOMP::initial_integrate(int /* vflag */)
|
|||
const double * const mass = atom->mass;
|
||||
const int * const type = atom->type;
|
||||
#if defined (_OPENMP)
|
||||
#pragma omp parallel for default(none) schedule(static)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE schedule(static)
|
||||
#endif
|
||||
for (int i = 0; i < nlocal; i++)
|
||||
if (mask[i] & groupbit) {
|
||||
|
@ -87,7 +88,7 @@ void FixNVEOMP::final_integrate()
|
|||
if (atom->rmass) {
|
||||
const double * const rmass = atom->rmass;
|
||||
#if defined (_OPENMP)
|
||||
#pragma omp parallel for default(none) schedule(static)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE schedule(static)
|
||||
#endif
|
||||
for (int i = 0; i < nlocal; i++)
|
||||
if (mask[i] & groupbit) {
|
||||
|
@ -101,7 +102,7 @@ void FixNVEOMP::final_integrate()
|
|||
const double * const mass = atom->mass;
|
||||
const int * const type = atom->type;
|
||||
#if defined (_OPENMP)
|
||||
#pragma omp parallel for default(none) schedule(static)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE schedule(static)
|
||||
#endif
|
||||
for (int i = 0; i < nlocal; i++)
|
||||
if (mask[i] & groupbit) {
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
See the README file in the top-level LAMMPS directory.
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "fix_nve_sphere_omp.h"
|
||||
#include <cmath>
|
||||
#include "atom.h"
|
||||
|
@ -49,7 +50,7 @@ void FixNVESphereOMP::initial_integrate(int /* vflag */)
|
|||
// update v,x,omega for all particles
|
||||
// d_omega/dt = torque / inertia
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE
|
||||
#endif
|
||||
for (int i = 0; i < nlocal; i++) {
|
||||
if (mask[i] & groupbit) {
|
||||
|
@ -76,7 +77,7 @@ void FixNVESphereOMP::initial_integrate(int /* vflag */)
|
|||
double * const * const mu = atom->mu;
|
||||
if (dlm == NODLM) {
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE
|
||||
#endif
|
||||
for (int i = 0; i < nlocal; i++) {
|
||||
double g0,g1,g2,msq,scale;
|
||||
|
@ -95,7 +96,7 @@ void FixNVESphereOMP::initial_integrate(int /* vflag */)
|
|||
}
|
||||
} else {
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE
|
||||
#endif
|
||||
// Integrate orientation following Dullweber-Leimkuhler-Maclachlan scheme
|
||||
for (int i = 0; i < nlocal; i++) {
|
||||
|
@ -223,7 +224,7 @@ void FixNVESphereOMP::final_integrate()
|
|||
// d_omega/dt = torque / inertia
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE
|
||||
#endif
|
||||
for (int i = 0; i < nlocal; i++)
|
||||
if (mask[i] & groupbit) {
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "fix_nvt_sllod_omp.h"
|
||||
#include <cstring>
|
||||
#include "math_extra.h"
|
||||
|
@ -114,7 +115,7 @@ void FixNVTSllodOMP::nh_v_temp()
|
|||
MathExtra::multiply_shape_shape(domain->h_rate,domain->h_inv,h_two);
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none) shared(h_two) schedule(static)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE LMP_SHARED(h_two) schedule(static)
|
||||
#endif
|
||||
for (int i = 0; i < nlocal; i++) {
|
||||
double vdelu0,vdelu1,vdelu2,buf[3];
|
||||
|
|
|
@ -16,6 +16,7 @@
|
|||
OpenMP based threading support for LAMMPS
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "atom.h"
|
||||
#include "comm.h"
|
||||
#include "error.h"
|
||||
|
@ -70,7 +71,7 @@ FixOMP::FixOMP(LAMMPS *lmp, int narg, char **arg)
|
|||
if (narg > 3) {
|
||||
#if defined(_OPENMP)
|
||||
if (strcmp(arg[3],"0") == 0)
|
||||
#pragma omp parallel default(none) shared(nthreads)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(nthreads)
|
||||
nthreads = omp_get_num_threads();
|
||||
else
|
||||
nthreads = force->inumeric(FLERR,arg[3]);
|
||||
|
@ -134,7 +135,7 @@ FixOMP::FixOMP(LAMMPS *lmp, int narg, char **arg)
|
|||
thr = new ThrData *[nthreads];
|
||||
_nthr = nthreads;
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(lmp)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(lmp)
|
||||
#endif
|
||||
{
|
||||
const int tid = get_tid();
|
||||
|
@ -186,7 +187,7 @@ void FixOMP::init()
|
|||
thr = new ThrData *[nthreads];
|
||||
_nthr = nthreads;
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE
|
||||
#endif
|
||||
{
|
||||
const int tid = get_tid();
|
||||
|
@ -350,7 +351,7 @@ void FixOMP::pre_force(int)
|
|||
double *drho = atom->drho;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(f,torque,erforce,de,drho)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(f,torque,erforce,de,drho)
|
||||
#endif
|
||||
{
|
||||
const int tid = get_tid();
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "fix_rigid_nh_omp.h"
|
||||
#include <mpi.h>
|
||||
#include <cstring>
|
||||
|
@ -89,7 +90,7 @@ void FixRigidNHOMP::initial_integrate(int vflag)
|
|||
double akt=0.0, akr=0.0;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none) shared(scale_r,scale_t,scale_v) schedule(static) reduction(+:akt,akr)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE LMP_SHARED(scale_r,scale_t,scale_v) schedule(static) reduction(+:akt,akr)
|
||||
#endif
|
||||
for (int ibody = 0; ibody < nbody; ibody++) {
|
||||
double mbody[3],tbody[3],fquat[4];
|
||||
|
@ -250,7 +251,7 @@ void FixRigidNHOMP::compute_forces_and_torques()
|
|||
int i;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none) private(i) reduction(+:s0,s1,s2,s3,s4,s5)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE private(i) reduction(+:s0,s1,s2,s3,s4,s5)
|
||||
#endif
|
||||
for (i = 0; i < nlocal; i++) {
|
||||
const int ibody = body[i];
|
||||
|
@ -289,7 +290,7 @@ void FixRigidNHOMP::compute_forces_and_torques()
|
|||
int i;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none) private(i) shared(ib) reduction(+:s0,s1,s2,s3,s4,s5)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE private(i) LMP_SHARED(ib) reduction(+:s0,s1,s2,s3,s4,s5)
|
||||
#endif
|
||||
for (i = 0; i < nlocal; i++) {
|
||||
const int ibody = body[i];
|
||||
|
@ -330,7 +331,7 @@ void FixRigidNHOMP::compute_forces_and_torques()
|
|||
memset(&sum[0][0],0,6*nbody*sizeof(double));
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE
|
||||
#endif
|
||||
{
|
||||
#if defined(_OPENMP)
|
||||
|
@ -373,7 +374,7 @@ void FixRigidNHOMP::compute_forces_and_torques()
|
|||
MPI_Allreduce(sum[0],all[0],6*nbody,MPI_DOUBLE,MPI_SUM,world);
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none) private(ibody) schedule(static)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE private(ibody) schedule(static)
|
||||
#endif
|
||||
for (ibody = 0; ibody < nbody; ibody++) {
|
||||
fcm[ibody][0] = all[ibody][0] + langextra[ibody][0];
|
||||
|
@ -388,7 +389,7 @@ void FixRigidNHOMP::compute_forces_and_torques()
|
|||
|
||||
if (id_gravity) {
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none) private(ibody) schedule(static)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE private(ibody) schedule(static)
|
||||
#endif
|
||||
for (ibody = 0; ibody < nbody; ibody++) {
|
||||
fcm[ibody][0] += gvec[0]*masstotal[ibody];
|
||||
|
@ -433,7 +434,7 @@ void FixRigidNHOMP::final_integrate()
|
|||
const double dtf2 = dtf * 2.0;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none) shared(scale_t,scale_r) schedule(static) reduction(+:akt,akr)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE LMP_SHARED(scale_t,scale_r) schedule(static) reduction(+:akt,akr)
|
||||
#endif
|
||||
for (int ibody = 0; ibody < nbody; ibody++) {
|
||||
double mbody[3],tbody[3],fquat[4];
|
||||
|
@ -554,7 +555,7 @@ void FixRigidNHOMP::remap()
|
|||
if (allremap) domain->x2lamda(nlocal);
|
||||
else {
|
||||
#if defined (_OPENMP)
|
||||
#pragma omp parallel for default(none) schedule(static)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE schedule(static)
|
||||
#endif
|
||||
for (int i = 0; i < nlocal; i++)
|
||||
if (mask[i] & dilate_group_bit)
|
||||
|
@ -586,7 +587,7 @@ void FixRigidNHOMP::remap()
|
|||
if (allremap) domain->lamda2x(nlocal);
|
||||
else {
|
||||
#if defined (_OPENMP)
|
||||
#pragma omp parallel for default(none) schedule(static)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE schedule(static)
|
||||
#endif
|
||||
for (int i = 0; i < nlocal; i++)
|
||||
if (mask[i] & dilate_group_bit)
|
||||
|
@ -631,7 +632,7 @@ void FixRigidNHOMP::set_xv_thr()
|
|||
int i;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none) private(i) reduction(+:v0,v1,v2,v3,v4,v5)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE private(i) reduction(+:v0,v1,v2,v3,v4,v5)
|
||||
#endif
|
||||
for (i = 0; i < nlocal; i++) {
|
||||
const int ibody = body[i];
|
||||
|
@ -832,7 +833,7 @@ void FixRigidNHOMP::set_v_thr()
|
|||
int i;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none) private(i) reduction(+:v0,v1,v2,v3,v4,v5)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE private(i) reduction(+:v0,v1,v2,v3,v4,v5)
|
||||
#endif
|
||||
for (i = 0; i < nlocal; i++) {
|
||||
const int ibody = body[i];
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "fix_rigid_omp.h"
|
||||
#include <mpi.h>
|
||||
#include <cmath>
|
||||
|
@ -47,7 +48,7 @@ typedef struct { double x,y,z; } dbl3_t;
|
|||
void FixRigidOMP::initial_integrate(int vflag)
|
||||
{
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none) schedule(static)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE schedule(static)
|
||||
#endif
|
||||
for (int ibody = 0; ibody < nbody; ibody++) {
|
||||
|
||||
|
@ -120,7 +121,7 @@ void FixRigidOMP::compute_forces_and_torques()
|
|||
double s0=0.0,s1=0.0,s2=0.0,s3=0.0,s4=0.0,s5=0.0;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none) reduction(+:s0,s1,s2,s3,s4,s5)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE reduction(+:s0,s1,s2,s3,s4,s5)
|
||||
#endif
|
||||
for (int i = 0; i < nlocal; i++) {
|
||||
const int ibody = body[i];
|
||||
|
@ -158,7 +159,7 @@ void FixRigidOMP::compute_forces_and_torques()
|
|||
double s0=0.0,s1=0.0,s2=0.0,s3=0.0,s4=0.0,s5=0.0;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none) shared(ib) reduction(+:s0,s1,s2,s3,s4,s5)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE LMP_SHARED(ib) reduction(+:s0,s1,s2,s3,s4,s5)
|
||||
#endif
|
||||
for (int i = 0; i < nlocal; i++) {
|
||||
const int ibody = body[i];
|
||||
|
@ -199,7 +200,7 @@ void FixRigidOMP::compute_forces_and_torques()
|
|||
memset(&sum[0][0],0,6*nbody*sizeof(double));
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE
|
||||
#endif
|
||||
{
|
||||
#if defined(_OPENMP)
|
||||
|
@ -246,7 +247,7 @@ void FixRigidOMP::compute_forces_and_torques()
|
|||
// fflag,tflag = 0 for some dimensions in 2d
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none) schedule(static)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE schedule(static)
|
||||
#endif
|
||||
for (int ibody = 0; ibody < nbody; ibody++) {
|
||||
fcm[ibody][0] = all[ibody][0] + langextra[ibody][0];
|
||||
|
@ -261,7 +262,7 @@ void FixRigidOMP::compute_forces_and_torques()
|
|||
|
||||
if (id_gravity) {
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none) schedule(static)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE schedule(static)
|
||||
#endif
|
||||
for (int ibody = 0; ibody < nbody; ibody++) {
|
||||
fcm[ibody][0] += gvec[0]*masstotal[ibody];
|
||||
|
@ -280,7 +281,7 @@ void FixRigidOMP::final_integrate()
|
|||
// update vcm and angmom
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none) schedule(static)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE schedule(static)
|
||||
#endif
|
||||
for (int ibody = 0; ibody < nbody; ibody++) {
|
||||
|
||||
|
@ -346,7 +347,7 @@ void FixRigidOMP::set_xv_thr()
|
|||
const int nlocal = atom->nlocal;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none) reduction(+:v0,v1,v2,v3,v4,v5)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE reduction(+:v0,v1,v2,v3,v4,v5)
|
||||
#endif
|
||||
for (int i = 0; i < nlocal; i++) {
|
||||
const int ibody = body[i];
|
||||
|
@ -546,7 +547,7 @@ void FixRigidOMP::set_v_thr()
|
|||
const int nlocal = atom->nlocal;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none) reduction(+:v0,v1,v2,v3,v4,v5)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE reduction(+:v0,v1,v2,v3,v4,v5)
|
||||
#endif
|
||||
for (int i = 0; i < nlocal; i++) {
|
||||
const int ibody = body[i];
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "fix_rigid_small_omp.h"
|
||||
#include <cmath>
|
||||
#include "atom.h"
|
||||
|
@ -46,7 +47,7 @@ void FixRigidSmallOMP::initial_integrate(int vflag)
|
|||
{
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none) schedule(static)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE schedule(static)
|
||||
#endif
|
||||
for (int ibody = 0; ibody < nlocal_body; ibody++) {
|
||||
|
||||
|
@ -117,7 +118,7 @@ void FixRigidSmallOMP::compute_forces_and_torques()
|
|||
const int nthreads=comm->nthreads;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none) schedule(static)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE schedule(static)
|
||||
#endif
|
||||
for (int ibody = 0; ibody < nlocal_body+nghost_body; ibody++) {
|
||||
double * _noalias const fcm = body[ibody].fcm;
|
||||
|
@ -132,7 +133,7 @@ void FixRigidSmallOMP::compute_forces_and_torques()
|
|||
// and then each thread only processes some bodies.
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE
|
||||
#endif
|
||||
{
|
||||
#if defined(_OPENMP)
|
||||
|
@ -183,7 +184,7 @@ void FixRigidSmallOMP::compute_forces_and_torques()
|
|||
|
||||
if (langflag) {
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none) schedule(static)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE schedule(static)
|
||||
#endif
|
||||
for (int ibody = 0; ibody < nlocal_body; ibody++) {
|
||||
double * _noalias const fcm = body[ibody].fcm;
|
||||
|
@ -201,7 +202,7 @@ void FixRigidSmallOMP::compute_forces_and_torques()
|
|||
|
||||
if (id_gravity) {
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none) schedule(static)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE schedule(static)
|
||||
#endif
|
||||
for (int ibody = 0; ibody < nbody; ibody++) {
|
||||
double * _noalias const fcm = body[ibody].fcm;
|
||||
|
@ -222,7 +223,7 @@ void FixRigidSmallOMP::final_integrate()
|
|||
// update vcm and angmom, recompute omega
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none) schedule(static)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE schedule(static)
|
||||
#endif
|
||||
for (int ibody = 0; ibody < nlocal_body; ibody++) {
|
||||
Body &b = body[ibody];
|
||||
|
@ -294,7 +295,7 @@ void FixRigidSmallOMP::set_xv_thr()
|
|||
const int nlocal = atom->nlocal;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none) reduction(+:v0,v1,v2,v3,v4,v5)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE reduction(+:v0,v1,v2,v3,v4,v5)
|
||||
#endif
|
||||
for (int i = 0; i < nlocal; i++) {
|
||||
const int ibody = atom2body[i];
|
||||
|
@ -489,7 +490,7 @@ void FixRigidSmallOMP::set_v_thr()
|
|||
const int nlocal = atom->nlocal;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel for default(none) reduction(+:v0,v1,v2,v3,v4,v5)
|
||||
#pragma omp parallel for LMP_DEFAULT_NONE reduction(+:v0,v1,v2,v3,v4,v5)
|
||||
#endif
|
||||
for (int i = 0; i < nlocal; i++) {
|
||||
const int ibody = atom2body[i];
|
||||
|
|
|
@ -1,12 +0,0 @@
|
|||
#!/bin/sh
|
||||
|
||||
# convert default(none) directives for OpenMP pragmas to default(shared) and remove shared() directive
|
||||
# this allows compiling OpenMP pragmas in LAMMPS with compilers that don't support default(none) properly
|
||||
# or require backward incompatible OpenMP 4 and OpenMP 5 semantics
|
||||
|
||||
for f in *.h *.cpp
|
||||
do \
|
||||
sed -e '/#pragma omp/s/^\(.*default\)(none)\(.*\)$/\1(shared)\2/' \
|
||||
-e '/#pragma omp/s/shared([a-z0-9,_]\+)//' \
|
||||
-i.bak $f
|
||||
done
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include <cmath>
|
||||
#include "improper_class2_omp.h"
|
||||
#include "atom.h"
|
||||
|
@ -50,7 +51,7 @@ void ImproperClass2OMP::compute(int eflag, int vflag)
|
|||
const int inum = neighbor->nimproperlist;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
int ifrom, ito, tid;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include <cmath>
|
||||
#include "improper_cossq_omp.h"
|
||||
#include "atom.h"
|
||||
|
@ -50,7 +51,7 @@ void ImproperCossqOMP::compute(int eflag, int vflag)
|
|||
const int inum = neighbor->nimproperlist;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
int ifrom, ito, tid;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include <cmath>
|
||||
#include "improper_cvff_omp.h"
|
||||
#include "atom.h"
|
||||
|
@ -50,7 +51,7 @@ void ImproperCvffOMP::compute(int eflag, int vflag)
|
|||
const int inum = neighbor->nimproperlist;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
int ifrom, ito, tid;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include <cmath>
|
||||
#include "improper_fourier_omp.h"
|
||||
#include "atom.h"
|
||||
|
@ -50,7 +51,7 @@ void ImproperFourierOMP::compute(int eflag, int vflag)
|
|||
const int inum = neighbor->nimproperlist;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
int ifrom, ito, tid;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include <cmath>
|
||||
#include "improper_harmonic_omp.h"
|
||||
#include "atom.h"
|
||||
|
@ -50,7 +51,7 @@ void ImproperHarmonicOMP::compute(int eflag, int vflag)
|
|||
const int inum = neighbor->nimproperlist;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
int ifrom, ito, tid;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "improper_ring_omp.h"
|
||||
#include <cmath>
|
||||
#include "atom.h"
|
||||
|
@ -50,7 +51,7 @@ void ImproperRingOMP::compute(int eflag, int vflag)
|
|||
const int inum = neighbor->nimproperlist;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
int ifrom, ito, tid;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing author: Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include <cmath>
|
||||
#include "improper_umbrella_omp.h"
|
||||
#include "atom.h"
|
||||
|
@ -50,7 +51,7 @@ void ImproperUmbrellaOMP::compute(int eflag, int vflag)
|
|||
const int inum = neighbor->nimproperlist;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
int ifrom, ito, tid;
|
||||
|
|
|
@ -16,6 +16,7 @@
|
|||
Original MSM class by: Paul Crozier, Stan Moore, Stephen Bond, (all SNL)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "msm_cg_omp.h"
|
||||
#include <mpi.h>
|
||||
#include <cmath>
|
||||
|
@ -310,7 +311,7 @@ void MSMCGOMP::compute(int eflag, int vflag)
|
|||
}
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
#if defined(_OPENMP)
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
Contributing authors: Axel Kohlmeyer (Temple U), Stan Moore (SNL)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "msm_omp.h"
|
||||
#include <cstring>
|
||||
#include "comm.h"
|
||||
|
@ -52,7 +53,7 @@ void MSMOMP::compute(int eflag, int vflag)
|
|||
MSM::compute(eflag,vflag);
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(eflag,vflag)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(eflag,vflag)
|
||||
#endif
|
||||
{
|
||||
#if defined(_OPENMP)
|
||||
|
@ -158,7 +159,7 @@ void MSMOMP::direct_eval(const int nn)
|
|||
const int n=nn;
|
||||
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) reduction(+:v0,v1,v2,v3,v4,v5,emsm)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE reduction(+:v0,v1,v2,v3,v4,v5,emsm)
|
||||
#endif
|
||||
{
|
||||
double esum,v0sum,v1sum,v2sum,v3sum,v4sum,v5sum;
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
See the README file in the top-level LAMMPS directory.
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "npair_full_bin_atomonly_omp.h"
|
||||
#include "npair_omp.h"
|
||||
#include "neigh_list.h"
|
||||
|
@ -36,7 +37,7 @@ void NPairFullBinAtomonlyOmp::build(NeighList *list)
|
|||
|
||||
NPAIR_OMP_INIT;
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(list)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(list)
|
||||
#endif
|
||||
NPAIR_OMP_SETUP(nlocal);
|
||||
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
See the README file in the top-level LAMMPS directory.
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "npair_full_bin_ghost_omp.h"
|
||||
#include "npair_omp.h"
|
||||
#include "neigh_list.h"
|
||||
|
@ -42,7 +43,7 @@ void NPairFullBinGhostOmp::build(NeighList *list)
|
|||
|
||||
NPAIR_OMP_INIT;
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(list)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(list)
|
||||
#endif
|
||||
NPAIR_OMP_SETUP(nall);
|
||||
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
See the README file in the top-level LAMMPS directory.
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "npair_full_bin_omp.h"
|
||||
#include "npair_omp.h"
|
||||
#include "neigh_list.h"
|
||||
|
@ -40,7 +41,7 @@ void NPairFullBinOmp::build(NeighList *list)
|
|||
|
||||
NPAIR_OMP_INIT;
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(list)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(list)
|
||||
#endif
|
||||
NPAIR_OMP_SETUP(nlocal);
|
||||
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
See the README file in the top-level LAMMPS directory.
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "npair_full_multi_omp.h"
|
||||
#include "npair_omp.h"
|
||||
#include "neigh_list.h"
|
||||
|
@ -41,7 +42,7 @@ void NPairFullMultiOmp::build(NeighList *list)
|
|||
|
||||
NPAIR_OMP_INIT;
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(list)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(list)
|
||||
#endif
|
||||
NPAIR_OMP_SETUP(nlocal);
|
||||
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
See the README file in the top-level LAMMPS directory.
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "npair_full_nsq_ghost_omp.h"
|
||||
#include "npair_omp.h"
|
||||
#include "neigh_list.h"
|
||||
|
@ -42,7 +43,7 @@ void NPairFullNsqGhostOmp::build(NeighList *list)
|
|||
|
||||
NPAIR_OMP_INIT;
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(list)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(list)
|
||||
#endif
|
||||
NPAIR_OMP_SETUP(nall);
|
||||
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
See the README file in the top-level LAMMPS directory.
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "npair_full_nsq_omp.h"
|
||||
#include "npair_omp.h"
|
||||
#include "neigh_list.h"
|
||||
|
@ -42,7 +43,7 @@ void NPairFullNsqOmp::build(NeighList *list)
|
|||
|
||||
NPAIR_OMP_INIT;
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(list)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(list)
|
||||
#endif
|
||||
NPAIR_OMP_SETUP(nlocal);
|
||||
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
See the README file in the top-level LAMMPS directory.
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "npair_half_bin_atomonly_newton_omp.h"
|
||||
#include "npair_omp.h"
|
||||
#include "neigh_list.h"
|
||||
|
@ -37,7 +38,7 @@ void NPairHalfBinAtomonlyNewtonOmp::build(NeighList *list)
|
|||
|
||||
NPAIR_OMP_INIT;
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(list)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(list)
|
||||
#endif
|
||||
NPAIR_OMP_SETUP(nlocal);
|
||||
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
See the README file in the top-level LAMMPS directory.
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "npair_half_bin_newtoff_ghost_omp.h"
|
||||
#include "npair_omp.h"
|
||||
#include "neigh_list.h"
|
||||
|
@ -46,7 +47,7 @@ void NPairHalfBinNewtoffGhostOmp::build(NeighList *list)
|
|||
|
||||
NPAIR_OMP_INIT;
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(list)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(list)
|
||||
#endif
|
||||
NPAIR_OMP_SETUP(nall);
|
||||
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
See the README file in the top-level LAMMPS directory.
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "npair_half_bin_newtoff_omp.h"
|
||||
#include "npair_omp.h"
|
||||
#include "neigh_list.h"
|
||||
|
@ -42,7 +43,7 @@ void NPairHalfBinNewtoffOmp::build(NeighList *list)
|
|||
|
||||
NPAIR_OMP_INIT;
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(list)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(list)
|
||||
#endif
|
||||
NPAIR_OMP_SETUP(nlocal);
|
||||
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
See the README file in the top-level LAMMPS directory.
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "npair_half_bin_newton_omp.h"
|
||||
#include "npair_omp.h"
|
||||
#include "neigh_list.h"
|
||||
|
@ -41,7 +42,7 @@ void NPairHalfBinNewtonOmp::build(NeighList *list)
|
|||
|
||||
NPAIR_OMP_INIT;
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(list)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(list)
|
||||
#endif
|
||||
NPAIR_OMP_SETUP(nlocal);
|
||||
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
See the README file in the top-level LAMMPS directory.
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "npair_half_bin_newton_tri_omp.h"
|
||||
#include "npair_omp.h"
|
||||
#include "neigh_list.h"
|
||||
|
@ -41,7 +42,7 @@ void NPairHalfBinNewtonTriOmp::build(NeighList *list)
|
|||
|
||||
NPAIR_OMP_INIT;
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(list)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(list)
|
||||
#endif
|
||||
NPAIR_OMP_SETUP(nlocal);
|
||||
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
See the README file in the top-level LAMMPS directory.
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "npair_half_multi_newtoff_omp.h"
|
||||
#include "npair_omp.h"
|
||||
#include "neigh_list.h"
|
||||
|
@ -43,7 +44,7 @@ void NPairHalfMultiNewtoffOmp::build(NeighList *list)
|
|||
|
||||
NPAIR_OMP_INIT;
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(list)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(list)
|
||||
#endif
|
||||
NPAIR_OMP_SETUP(nlocal);
|
||||
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
See the README file in the top-level LAMMPS directory.
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "npair_half_multi_newton_omp.h"
|
||||
#include "npair_omp.h"
|
||||
#include "neigh_list.h"
|
||||
|
@ -42,7 +43,7 @@ void NPairHalfMultiNewtonOmp::build(NeighList *list)
|
|||
|
||||
NPAIR_OMP_INIT;
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(list)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(list)
|
||||
#endif
|
||||
NPAIR_OMP_SETUP(nlocal);
|
||||
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
See the README file in the top-level LAMMPS directory.
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "npair_half_multi_newton_tri_omp.h"
|
||||
#include "npair_omp.h"
|
||||
#include "neigh_list.h"
|
||||
|
@ -43,7 +44,7 @@ void NPairHalfMultiNewtonTriOmp::build(NeighList *list)
|
|||
|
||||
NPAIR_OMP_INIT;
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(list)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(list)
|
||||
#endif
|
||||
NPAIR_OMP_SETUP(nlocal);
|
||||
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
See the README file in the top-level LAMMPS directory.
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "omp_compat.h"
|
||||
#include "npair_half_nsq_newtoff_ghost_omp.h"
|
||||
#include "npair_omp.h"
|
||||
#include "neigh_list.h"
|
||||
|
@ -47,7 +48,7 @@ void NPairHalfNsqNewtoffGhostOmp::build(NeighList *list)
|
|||
|
||||
NPAIR_OMP_INIT;
|
||||
#if defined(_OPENMP)
|
||||
#pragma omp parallel default(none) shared(list)
|
||||
#pragma omp parallel LMP_DEFAULT_NONE LMP_SHARED(list)
|
||||
#endif
|
||||
NPAIR_OMP_SETUP(nall);
|
||||
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue