OpenMPI MPI_Barrier problems

后端 未结 4 1114
花落未央
花落未央 2021-01-02 13:28

I having some synchronization issues using the OpenMPI implementation of MPI_Barrier:

int rank;
int nprocs;

int rc = MPI_Init(&argc, &argv);

if(rc          


        
4条回答
  •  甜味超标
    2021-01-02 13:41

    Adding to the previous answers here, your MPI_BARRIER works fine.

    Though, if you just intend to see it working, you can force pause the execution (SLEEP(1)) for a moment to let the output catch up.

提交回复
热议问题