Fix more data issues

This commit is contained in:
Stan Moore
2025-06-23 16:39:05 -06:00
parent 339c570b3e
commit f090a63536
2 changed files with 6 additions and 0 deletions

View File

@ -824,10 +824,12 @@ void AtomVecKokkos::unpack_reverse_kokkos(const int &n,
// Choose correct reverse UnPackReverse kernel
if (lmp->kokkos->reverse_comm_on_host) {
atomKK->sync(HostKK,F_MASK);
struct AtomVecKokkos_UnPackReverse<LMPHostType> f(atomKK->k_f,buf,list);
Kokkos::parallel_for(n,f);
atomKK->modified(Host,F_MASK);
} else {
atomKK->sync(Device,F_MASK);
struct AtomVecKokkos_UnPackReverse<LMPDeviceType> f(atomKK->k_f,buf,list);
Kokkos::parallel_for(n,f);
atomKK->modified(Device,F_MASK);

View File

@ -1437,6 +1437,10 @@ void FixShakeKokkos<DeviceType>::stats()
template<class DeviceType>
void FixShakeKokkos<DeviceType>::grow_arrays(int nmax)
{
k_shake_flag.sync_device();
k_shake_atom.sync_device();
k_shake_type.sync_device();
memoryKK->grow_kokkos(k_shake_flag,shake_flag,nmax,"shake:shake_flag");
memoryKK->grow_kokkos(k_shake_atom,shake_atom,nmax,4,"shake:shake_atom");
memoryKK->grow_kokkos(k_shake_type,shake_type,nmax,3,"shake:shake_type");