"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "src/mpi/coll/barrier_osu.c" between
mvapich2-2.3.1.tar.gz and mvapich2-2.3.2.tar.gz

About: MVAPICH2 offers "MPI over InfiniBand, 10GigE/iWARP and RDMA over Converged Ethernet (RoCE)" to achieve best performance, scalability and fault tolerance for high-end computing systems and servers.

barrier_osu.c  (mvapich2-2.3.1):barrier_osu.c  (mvapich2-2.3.2)
skipping to change at line 26 skipping to change at line 26
* copyright file COPYRIGHT in the top level MVAPICH2 directory. * copyright file COPYRIGHT in the top level MVAPICH2 directory.
* *
*/ */
#include "mpiimpl.h" #include "mpiimpl.h"
#include "coll_shmem.h" #include "coll_shmem.h"
#ifdef MRAIL_GEN2_INTERFACE #ifdef MRAIL_GEN2_INTERFACE
#include <cr.h> #include <cr.h>
#endif #endif
MPIR_T_PVAR_DOUBLE_TIMER_DECL_EXTERN(MV2, mv2_coll_timer_barrier_pairwise);
MPIR_T_PVAR_DOUBLE_TIMER_DECL_EXTERN(MV2, mv2_coll_timer_barrier_shmem);
MPIR_T_PVAR_ULONG2_COUNTER_DECL_EXTERN(MV2, mv2_coll_barrier_pairwise); MPIR_T_PVAR_ULONG2_COUNTER_DECL_EXTERN(MV2, mv2_coll_barrier_pairwise);
MPIR_T_PVAR_ULONG2_COUNTER_DECL_EXTERN(MV2, mv2_coll_barrier_shmem); MPIR_T_PVAR_ULONG2_COUNTER_DECL_EXTERN(MV2, mv2_coll_barrier_shmem);
MPIR_T_PVAR_ULONG2_COUNTER_DECL_EXTERN(MV2, mv2_coll_barrier_subcomm);
MPIR_T_PVAR_ULONG2_COUNTER_DECL_EXTERN(MV2, mv2_coll_barrier_pairwise_bytes_send ); MPIR_T_PVAR_ULONG2_COUNTER_DECL_EXTERN(MV2, mv2_coll_barrier_pairwise_bytes_send );
MPIR_T_PVAR_ULONG2_COUNTER_DECL_EXTERN(MV2, mv2_coll_barrier_pairwise_bytes_recv ); MPIR_T_PVAR_ULONG2_COUNTER_DECL_EXTERN(MV2, mv2_coll_barrier_pairwise_bytes_recv );
MPIR_T_PVAR_ULONG2_COUNTER_DECL_EXTERN(MV2, mv2_coll_barrier_pairwise_count_send ); MPIR_T_PVAR_ULONG2_COUNTER_DECL_EXTERN(MV2, mv2_coll_barrier_pairwise_count_send );
MPIR_T_PVAR_ULONG2_COUNTER_DECL_EXTERN(MV2, mv2_coll_barrier_pairwise_count_recv ); MPIR_T_PVAR_ULONG2_COUNTER_DECL_EXTERN(MV2, mv2_coll_barrier_pairwise_count_recv );
MPIR_T_PVAR_ULONG2_COUNTER_DECL_EXTERN(MV2, mv2_coll_barrier_bytes_send); MPIR_T_PVAR_ULONG2_COUNTER_DECL_EXTERN(MV2, mv2_coll_barrier_bytes_send);
MPIR_T_PVAR_ULONG2_COUNTER_DECL_EXTERN(MV2, mv2_coll_barrier_bytes_recv); MPIR_T_PVAR_ULONG2_COUNTER_DECL_EXTERN(MV2, mv2_coll_barrier_bytes_recv);
MPIR_T_PVAR_ULONG2_COUNTER_DECL_EXTERN(MV2, mv2_coll_barrier_count_send); MPIR_T_PVAR_ULONG2_COUNTER_DECL_EXTERN(MV2, mv2_coll_barrier_count_send);
MPIR_T_PVAR_ULONG2_COUNTER_DECL_EXTERN(MV2, mv2_coll_barrier_count_recv); MPIR_T_PVAR_ULONG2_COUNTER_DECL_EXTERN(MV2, mv2_coll_barrier_count_recv);
static int MPIR_Pairwise_Barrier_MV2(MPID_Comm * comm_ptr, MPIR_Errflag_t *errfl ag) static int MPIR_Pairwise_Barrier_MV2(MPID_Comm * comm_ptr, MPIR_Errflag_t *errfl ag)
{ {
MPIR_TIMER_START(coll,barrier,pairwise);
int size, rank; int size, rank;
int d, dst, src; int d, dst, src;
int mpi_errno = MPI_SUCCESS; int mpi_errno = MPI_SUCCESS;
MPIR_T_PVAR_COUNTER_INC(MV2, mv2_coll_barrier_pairwise, 1); MPIR_T_PVAR_COUNTER_INC(MV2, mv2_coll_barrier_pairwise, 1);
size = comm_ptr->local_size; size = comm_ptr->local_size;
/* Trivial barriers return immediately */ /* Trivial barriers return immediately */
if (size == 1) if (size == 1)
return MPI_SUCCESS; return MPI_SUCCESS;
skipping to change at line 96 skipping to change at line 100
} else { } else {
/* fanin data to power of 2 subset */ /* fanin data to power of 2 subset */
src = rank - N2_prev; src = rank - N2_prev;
MPIR_PVAR_INC(barrier, pairwise, send, 0, MPI_BYTE); MPIR_PVAR_INC(barrier, pairwise, send, 0, MPI_BYTE);
MPIR_PVAR_INC(barrier, pairwise, recv, 0, MPI_BYTE); MPIR_PVAR_INC(barrier, pairwise, recv, 0, MPI_BYTE);
mpi_errno = MPIC_Sendrecv(NULL, 0, MPI_BYTE, src, MPIR_BARRIER_TAG, mpi_errno = MPIC_Sendrecv(NULL, 0, MPI_BYTE, src, MPIR_BARRIER_TAG,
NULL, 0, MPI_BYTE, src, MPIR_BARRIER_TAG, NULL, 0, MPI_BYTE, src, MPIR_BARRIER_TAG,
comm_ptr, MPI_STATUS_IGNORE, errflag); comm_ptr, MPI_STATUS_IGNORE, errflag);
} }
MPIR_TIMER_END(coll,barrier,pairwise);
return mpi_errno; return mpi_errno;
} }
static int MPIR_shmem_barrier_MV2(MPID_Comm * comm_ptr, MPIR_Errflag_t *errflag) static int MPIR_shmem_barrier_MV2(MPID_Comm * comm_ptr, MPIR_Errflag_t *errflag)
{ {
MPIR_TIMER_START(coll,barrier,shmem);
int mpi_errno = MPI_SUCCESS; int mpi_errno = MPI_SUCCESS;
MPI_Comm shmem_comm = MPI_COMM_NULL, leader_comm = MPI_COMM_NULL; MPI_Comm shmem_comm = MPI_COMM_NULL, leader_comm = MPI_COMM_NULL;
MPID_Comm *shmem_commptr = NULL, *leader_commptr = NULL; MPID_Comm *shmem_commptr = NULL, *leader_commptr = NULL;
int local_rank = -1, local_size = 0; int local_rank = -1, local_size = 0;
int total_size, shmem_comm_rank; int total_size, shmem_comm_rank;
MPIR_T_PVAR_COUNTER_INC(MV2, mv2_coll_barrier_shmem, 1); MPIR_T_PVAR_COUNTER_INC(MV2, mv2_coll_barrier_shmem, 1);
MPIR_T_PVAR_COUNTER_INC(MV2, mv2_num_shmem_coll_calls, 1); MPIR_T_PVAR_COUNTER_INC(MV2, mv2_num_shmem_coll_calls, 1);
shmem_comm = comm_ptr->dev.ch.shmem_comm; shmem_comm = comm_ptr->dev.ch.shmem_comm;
skipping to change at line 139 skipping to change at line 145
if ((local_rank == 0) && (local_size != total_size)) { if ((local_rank == 0) && (local_size != total_size)) {
mpi_errno = MPIR_Pairwise_Barrier_MV2(leader_commptr, errflag); mpi_errno = MPIR_Pairwise_Barrier_MV2(leader_commptr, errflag);
} }
if (local_size > 1) { if (local_size > 1) {
MPIDI_CH3I_SHMEM_COLL_Barrier_bcast(local_size, local_rank, MPIDI_CH3I_SHMEM_COLL_Barrier_bcast(local_size, local_rank,
shmem_comm_rank); shmem_comm_rank);
} }
MPIR_TIMER_END(coll,barrier,shmem);
return mpi_errno; return mpi_errno;
} }
/* This is the default implementation of the barrier operation. The /* This is the default implementation of the barrier operation. The
algorithm is: algorithm is:
Algorithm: MPI_Barrier Algorithm: MPI_Barrier
We use pairwise exchange with recursive doubling algorithm We use pairwise exchange with recursive doubling algorithm
skipping to change at line 210 skipping to change at line 217
return mpi_errno; return mpi_errno;
} }
#undef FUNCNAME #undef FUNCNAME
#define FUNCNAME MPIR_Barrier_MV2 #define FUNCNAME MPIR_Barrier_MV2
#undef FCNAME #undef FCNAME
#define FCNAME MPL_QUOTE(FUNCNAME) #define FCNAME MPL_QUOTE(FUNCNAME)
int MPIR_Barrier_MV2(MPID_Comm * comm_ptr, MPIR_Errflag_t *errflag) int MPIR_Barrier_MV2(MPID_Comm * comm_ptr, MPIR_Errflag_t *errflag)
{ {
int mpi_errno = MPI_SUCCESS; int mpi_errno = MPI_SUCCESS;
MPIR_T_PVAR_COMM_COUNTER_INC(MV2,mv2_coll_barrier_subcomm,1,comm_ptr);
mpi_errno = MPIR_Barrier_intra_MV2(comm_ptr, errflag); mpi_errno = MPIR_Barrier_intra_MV2(comm_ptr, errflag);
if (mpi_errno) if (mpi_errno)
MPIR_ERR_POP(mpi_errno); MPIR_ERR_POP(mpi_errno);
fn_exit: fn_exit:
return mpi_errno; return mpi_errno;
fn_fail: fn_fail:
goto fn_exit; goto fn_exit;
} }
 End of changes. 7 change blocks. 
1 lines changed or deleted 9 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)