Tthis is to note that we are only using a barrier a mechanism to sync
with GPU tasks rather than to preventing a race between the copy and
other CPU tasks.
Change-Id: I8d432f7ef3e87e56beffa7f58230e50bcd59a666
if (useGpuForUpdate)
{
stateGpu->copyCoordinatesToGpu(state->x, AtomLocality::Local);
+ // Here we block until the H2D copy completes because event sync with the
+ // force kernels that use the coordinates on the next steps is not implemented
+ // (not because of a race on state->x being modified on the CPU while H2D is in progress).
stateGpu->waitCoordinatesCopiedToDevice(AtomLocality::Local);
}
}