Skip to content

Commit 1c6cdc9

Browse files
committed
Fix sync images to take the syncer's id from mpi_status.
Take the source index of the image that is sending the current image data from the MPI_status handle of Waitany instead of the index i, which only denotes the handle in the array of receive-requests.
1 parent 882c371 commit 1c6cdc9

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/mpi/mpi_caf.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3098,7 +3098,7 @@ sync_images_internal (int count, int images[], int *stat, char *errmsg,
30983098
if (i != MPI_UNDEFINED)
30993099
{
31003100
++done_count;
3101-
if (ierr == MPI_SUCCESS && arrived[i] == STAT_STOPPED_IMAGE)
3101+
if (ierr == MPI_SUCCESS && arrived[s.MPI_SOURCE] == STAT_STOPPED_IMAGE)
31023102
{
31033103
/* Possible future extension: Abort pending receives. At the
31043104
moment the receives are discarded by the program

0 commit comments

Comments
 (0)