Browse Source

little optimization to reduce number of barriers when benchmarking Master-Slave

Corentin Salingue 8 years ago
parent
commit
bebe96a109
1 changed files with 2 additions and 2 deletions
  1. 2 2
      src/drivers/mpi/driver_mpi_common.c

+ 2 - 2
src/drivers/mpi/driver_mpi_common.c

@@ -484,12 +484,12 @@ void _starpu_mpi_common_measure_bandwidth_latency(double bandwidth_dtod[STARPU_M
         {
                 for(receiver = 0; receiver < nb_proc; receiver++) 
                 {
-                        MPI_Barrier(MPI_COMM_WORLD);
-
                         //Node can't be a sender and a receiver
                         if(sender == receiver)
                                 continue;
 
+                        MPI_Barrier(MPI_COMM_WORLD);
+
                         if(id_proc == sender)
                         {
                                 double start, end;