예제 #1
0
파일: igather.c 프로젝트: NexMirror/MPICH
int MPIR_Igather_sched_intra_auto(const void *sendbuf, int sendcount, MPI_Datatype sendtype, void *recvbuf, int recvcount, MPI_Datatype recvtype, int root, MPIR_Comm *comm_ptr, MPIR_Sched_t s)
{
    int mpi_errno = MPI_SUCCESS;

    mpi_errno = MPIR_Igather_sched_intra_binomial(sendbuf, sendcount, sendtype, recvbuf, recvcount, recvtype, root, comm_ptr, s);
    if (mpi_errno) MPIR_ERR_POP(mpi_errno);

fn_exit:
    return mpi_errno;
fn_fail:
    goto fn_exit;
}
예제 #2
0
파일: igather.c 프로젝트: jeffhammond/mpich
int MPIR_Igather_sched_impl(const void *sendbuf, int sendcount, MPI_Datatype sendtype,
                            void *recvbuf, int recvcount, MPI_Datatype recvtype,
                            int root, MPIR_Comm * comm_ptr, MPIR_Sched_t s)
{
    int mpi_errno = MPI_SUCCESS;

    if (comm_ptr->comm_kind == MPIR_COMM_KIND__INTRACOMM) {
        /* intracommunicator */
        switch (MPIR_CVAR_IGATHER_INTRA_ALGORITHM) {
            case MPIR_CVAR_IGATHER_INTRA_ALGORITHM_binomial:
                mpi_errno = MPIR_Igather_sched_intra_binomial(sendbuf, sendcount, sendtype,
                                                              recvbuf, recvcount, recvtype, root,
                                                              comm_ptr, s);
                break;
            case MPIR_CVAR_IGATHER_INTRA_ALGORITHM_auto:
                MPL_FALLTHROUGH;
            default:
                mpi_errno = MPIR_Igather_sched_intra_auto(sendbuf, sendcount, sendtype,
                                                          recvbuf, recvcount, recvtype, root,
                                                          comm_ptr, s);
                break;
        }
    } else {
        /* intercommunicator */
        switch (MPIR_CVAR_IGATHER_INTER_ALGORITHM) {
            case MPIR_CVAR_IGATHER_INTER_ALGORITHM_long:
                mpi_errno = MPIR_Igather_sched_inter_long(sendbuf, sendcount, sendtype,
                                                          recvbuf, recvcount, recvtype, root,
                                                          comm_ptr, s);
                break;
            case MPIR_CVAR_IGATHER_INTER_ALGORITHM_short:
                mpi_errno = MPIR_Igather_sched_inter_short(sendbuf, sendcount, sendtype,
                                                           recvbuf, recvcount, recvtype, root,
                                                           comm_ptr, s);
                break;
            case MPIR_CVAR_IGATHER_INTER_ALGORITHM_auto:
                MPL_FALLTHROUGH;
            default:
                mpi_errno = MPIR_Igather_sched_inter_auto(sendbuf, sendcount, sendtype, recvbuf,
                                                          recvcount, recvtype, root, comm_ptr, s);
        }
    }

    return mpi_errno;
}