Dear all, I have the following problem:
In my program each rank has a vector, where the position indicates where I have to send the data. For example for rank 0, I have: *ALLOCATE(Ndata2send(0,MPI%nCPU-1)* *Ndata2send(:) = 0,10,10,16* where MPI%nCPU is the number of cPU, in my case 4 Thins means that I have to send 10 to rank 1, 10 to rank 2 and 16 to rank 3 I have the following cycle: icount=1 DO iCPU=0,MPI%nCPU-1 IF(iCPU.NE.MPI%rank)THEN iTag=iCPU CALL MPI_ISEND(Ndata2send(iCPU),1,MPI_INTEGER,iCPU,iTag,MPI_COMM_WORLD,send_request(icount),MPI%iErr) icount=icount+1 ENDIF ENDDO icount=1 DO iCPU=0,MPI%nCPU-1 IF(iCPU.NE.MPI%rank)THEN iTag=iCPU CALL MPI_IRECV(Ndata2recv(iCPU),1,MPI_INTEGER,iCPU,iTag,MPI_COMM_WORLD,recv_request(icount),MPI%iErr) icount=icount+1 ENDIF ENDDO and then, to wait all comunication I have: * CALL MPI_WAITALL(3,send_request,send_status_list,MPI%iErr)* * CALL MPI_WAITALL(3,recv_request,recv_status_list,MPI%iErr)* The problem is that comunication never stops. Have I missed something? Please help me to understand what I havent't understood. Thanks Diego