1
0
mirror of https://github.com/paboyle/Grid.git synced 2025-06-16 23:07:05 +01:00

UVM check in MPI calls

This commit is contained in:
Peter Boyle
2020-09-03 20:29:26 -04:00
parent 8244caff25
commit a8309638d4
3 changed files with 26 additions and 12 deletions

View File

@ -309,15 +309,8 @@ void CartesianCommunicator::SendToRecvFrom(void *xmit,
int ierr;
// Enforce no UVM in comms, device or host OK
int uvm;
auto
cuerr = cuPointerGetAttribute( &uvm, CU_POINTER_ATTRIBUTE_IS_MANAGED, (CUdeviceptr) xmit);
assert(cuerr == cudaSuccess );
assert(uvm==0);
cuerr = cuPointerGetAttribute( &uvm, CU_POINTER_ATTRIBUTE_IS_MANAGED, (CUdeviceptr) recv);
assert(cuerr == cudaSuccess );
assert(uvm==0);
assert(acceleratorIsCommunicable(xmit));
assert(acceleratorIsCommunicable(recv));
// Give the CPU to MPI immediately; can use threads to overlap optionally
// printf("proc %d SendToRecvFrom %d bytes Sendrecv \n",_processor,bytes);