diff --git a/doc/src/Speed_kokkos.txt b/doc/src/Speed_kokkos.txt index 6e64510e44..597ed73e53 100644 --- a/doc/src/Speed_kokkos.txt +++ b/doc/src/Speed_kokkos.txt @@ -102,9 +102,9 @@ the case, especially when using pre-compiled MPI libraries provided by a Linux distribution. This is not a problem when using only a single GPU and a single MPI rank on a desktop. When running with multiple MPI ranks, you may see segmentation faults without GPU-direct support. -These can be avoided by adding the flags '-pk kokkos gpu/direct no' -to the LAMMPS command line or using "package kokkos gpu/direct no"_package.html -in the input file. +These can be avoided by adding the flags '-pk kokkos gpu/direct off' +to the LAMMPS command line or by using the command +"package kokkos gpu/direct off"_package.html in the input file. Use a C++11 compatible compiler and set KOKKOS_ARCH variable in /src/MAKE/OPTIONS/Makefile.kokkos_cuda_mpi for both GPU and CPU as diff --git a/doc/src/package.txt b/doc/src/package.txt index 19a19156b7..55bd111b50 100644 --- a/doc/src/package.txt +++ b/doc/src/package.txt @@ -507,10 +507,10 @@ typically faster to let the host handle communication, by using the {host} value. Using {host} instead of {no} will enable use of multiple threads to pack/unpack communicated data. -The {gpu/direct} keyword chooses whether GPU-direct will be used. When -this keyword is set to {on}, buffers in GPU memory are passed directly -through MPI send/receive calls. This reduces overhead of first copying -the data to the host CPU. However GPU-direct is not supported on all +The {gpu/direct} keyword chooses whether GPU-direct will be used. When +this keyword is set to {on}, buffers in GPU memory are passed directly +through MPI send/receive calls. This reduces overhead of first copying +the data to the host CPU. However GPU-direct is not supported on all systems, which can lead to segmentation faults and would require using a value of {off}. When the {gpu/direct} keyword is set to {off} while any of the {comm} keywords are set to {device}, the value for the @@ -622,12 +622,12 @@ is used. If it is not used, you must invoke the package intel command in your input script or or via the "-pk intel" "command-line switch"_Section_start.html#start_6. -For the KOKKOS package, the option defaults neigh = full, neigh/qeq = -full, newton = off, binsize = 0.0, and comm = device, gpu/direct = on. -These settings are made automatically by the required "-k on" -"command-line switch"_Section_start.html#start_6. You can change them bu -using the package kokkos command in your input script or via the "-pk -kokkos" "command-line switch"_Section_start.html#start_6. +For the KOKKOS package, the option defaults neigh = full, neigh/qeq = +full, newton = off, binsize = 0.0, and comm = device, gpu/direct = on. +These settings are made automatically by the required "-k on" +"command-line switch"_Section_start.html#start_6. You can change them by +using the package kokkos command in your input script or via the "-pk +kokkos" "command-line switch"_Section_start.html#start_6. For the OMP package, the default is Nthreads = 0 and the option defaults are neigh = yes. These settings are made automatically if diff --git a/src/KOKKOS/kokkos.cpp b/src/KOKKOS/kokkos.cpp index 078b871473..050b1420d3 100644 --- a/src/KOKKOS/kokkos.cpp +++ b/src/KOKKOS/kokkos.cpp @@ -156,16 +156,16 @@ KokkosLMP::KokkosLMP(LAMMPS *lmp, int narg, char **arg) : Pointers(lmp) } else if (-1 == have_gpu_direct() ) { error->warning(FLERR,"Kokkos with CUDA assumes GPU-direct is available," " but cannot determine if this is the case\n try" - " '-pk kokkos gpu/direct no' when getting segmentation faults"); + " '-pk kokkos gpu/direct off' when getting segmentation faults"); } else if ( 0 == have_gpu_direct() ) { error->warning(FLERR,"GPU-direct is NOT available, but some parts of " "Kokkos with CUDA require it by default\n try" - " '-pk kokkos gpu/direct no' when getting segmentation faults"); + " '-pk kokkos gpu/direct off' when getting segmentation faults"); } else { ; // should never get here } } - + #endif Kokkos::InitArguments args; @@ -310,7 +310,7 @@ void KokkosLMP::accelerator(int narg, char **arg) } else error->all(FLERR,"Illegal package kokkos command"); } - // if "gpu/direct no" and "comm device", change to "comm host" + // if "gpu/direct off" and "comm device", change to "comm host" if (!gpu_direct) { if (exchange_comm_classic == 0 && exchange_comm_on_host == 0)