const bool useGpuForPme = (runMode == PmeRunMode::GPU) || (runMode == PmeRunMode::Mixed);
if (useGpuForPme)
{
- const void* commandStream = pme_gpu_get_device_stream(pme);
+ const DeviceStream& deviceStream = *pme_gpu_get_device_stream(pme);
changePinningPolicy(&pme_pp->chargeA, pme_get_pinning_policy());
changePinningPolicy(&pme_pp->x, pme_get_pinning_policy());
if (c_enableGpuPmePpComms)
{
pme_pp->pmeCoordinateReceiverGpu = std::make_unique<gmx::PmeCoordinateReceiverGpu>(
- commandStream, pme_pp->mpi_comm_mysim, pme_pp->ppRanks);
+ deviceStream, pme_pp->mpi_comm_mysim, pme_pp->ppRanks);
pme_pp->pmeForceSenderGpu = std::make_unique<gmx::PmeForceSenderGpu>(
- commandStream, pme_pp->mpi_comm_mysim, pme_pp->ppRanks);
+ deviceStream, pme_pp->mpi_comm_mysim, pme_pp->ppRanks);
}
GMX_RELEASE_ASSERT(
deviceContext != nullptr,
// TODO: Special PME-only constructor is used here. There is no mechanism to prevent from using the other constructor here.
// This should be made safer.
stateGpu = std::make_unique<gmx::StatePropagatorDataGpu>(
- commandStream, *deviceContext, GpuApiCallBehavior::Async,
+ &deviceStream, *deviceContext, GpuApiCallBehavior::Async,
pme_gpu_get_padding_size(pme), wcycle);
}