1
1

Spring cleanup. Nothing important.

This commit was SVN r26247.
Этот коммит содержится в:
George Bosilca 2012-04-06 15:48:07 +00:00
родитель 654c75ff24
Коммит f09e3ce5a4
16 изменённых файлов: 1848 добавлений и 2003 удалений

Просмотреть файл

@ -86,10 +86,7 @@ int ompi_coll_tuned_allgather_intra_bruck(void *sbuf, int scount,
struct ompi_communicator_t *comm,
mca_coll_base_module_t *module)
{
int line = -1;
int rank, size;
int sendto, recvfrom, distance, blockcount;
int err = 0;
int line = -1, rank, size, sendto, recvfrom, distance, blockcount, err = 0;
ptrdiff_t slb, rlb, sext, rext;
char *tmpsend = NULL, *tmprecv = NULL;
@ -262,10 +259,8 @@ ompi_coll_tuned_allgather_intra_recursivedoubling(void *sbuf, int scount,
struct ompi_communicator_t *comm,
mca_coll_base_module_t *module)
{
int line = -1;
int rank, size, pow2size;
int line = -1, rank, size, pow2size, err;
int remote, distance, sendblocklocation;
int err = 0;
ptrdiff_t slb, rlb, sext, rext;
char *tmpsend = NULL, *tmprecv = NULL;
@ -371,10 +366,7 @@ int ompi_coll_tuned_allgather_intra_ring(void *sbuf, int scount,
struct ompi_communicator_t *comm,
mca_coll_base_module_t *module)
{
int line = -1;
int rank, size;
int sendto, recvfrom, i, recvdatafrom, senddatafrom;
int err = 0;
int line = -1, rank, size, err, sendto, recvfrom, i, recvdatafrom, senddatafrom;
ptrdiff_t slb, rlb, sext, rext;
char *tmpsend = NULL, *tmprecv = NULL;
@ -502,11 +494,8 @@ ompi_coll_tuned_allgather_intra_neighborexchange(void *sbuf, int scount,
struct ompi_communicator_t *comm,
mca_coll_base_module_t *module)
{
int line = -1;
int rank, size;
int line = -1, rank, size, i, even_rank, err;
int neighbor[2], offset_at_step[2], recv_data_from[2], send_data_from;
int i, even_rank;
int err = 0;
ptrdiff_t slb, rlb, sext, rext;
char *tmpsend = NULL, *tmprecv = NULL;
@ -621,9 +610,7 @@ int ompi_coll_tuned_allgather_intra_two_procs(void *sbuf, int scount,
struct ompi_communicator_t *comm,
mca_coll_base_module_t *module)
{
int line = -1, err = 0;
int rank;
int remote;
int line = -1, err, rank, remote;
char *tmpsend = NULL, *tmprecv = NULL;
ptrdiff_t sext, rext, lb;

Просмотреть файл

@ -92,11 +92,8 @@ int ompi_coll_tuned_allgatherv_intra_bruck(void *sbuf, int scount,
struct ompi_communicator_t *comm,
mca_coll_base_module_t *module)
{
int line = -1, err = 0;
int rank, size;
int sendto, recvfrom, distance, blockcount, i;
int *new_rcounts = NULL, *new_rdispls = NULL;
int *new_scounts = NULL, *new_sdispls = NULL;
int line = -1, err = 0, rank, size, sendto, recvfrom, distance, blockcount, i;
int *new_rcounts = NULL, *new_rdispls = NULL, *new_scounts = NULL, *new_sdispls = NULL;
ptrdiff_t slb, rlb, sext, rext;
char *tmpsend = NULL, *tmprecv = NULL;
struct ompi_datatype_t *new_rdtype, *new_sdtype;
@ -223,10 +220,7 @@ int ompi_coll_tuned_allgatherv_intra_ring(void *sbuf, int scount,
struct ompi_communicator_t *comm,
mca_coll_base_module_t *module)
{
int line = -1;
int rank, size;
int sendto, recvfrom, i, recvdatafrom, senddatafrom;
int err = 0;
int line = -1, rank, size, sendto, recvfrom, i, recvdatafrom, senddatafrom, err = 0;
ptrdiff_t slb, rlb, sext, rext;
char *tmpsend = NULL, *tmprecv = NULL;
@ -356,12 +350,9 @@ ompi_coll_tuned_allgatherv_intra_neighborexchange(void *sbuf, int scount,
struct ompi_communicator_t *comm,
mca_coll_base_module_t *module)
{
int line = -1;
int rank, size;
int line = -1, rank, size, i, even_rank, err = 0;
int neighbor[2], offset_at_step[2], recv_data_from[2], send_data_from;
int new_scounts[2], new_sdispls[2], new_rcounts[2], new_rdispls[2];
int i, even_rank;
int err = 0;
ptrdiff_t slb, rlb, sext, rext;
char *tmpsend = NULL, *tmprecv = NULL;
struct ompi_datatype_t *new_rdtype, *new_sdtype;
@ -507,9 +498,7 @@ int ompi_coll_tuned_allgatherv_intra_two_procs(void *sbuf, int scount,
struct ompi_communicator_t *comm,
mca_coll_base_module_t *module)
{
int line = -1, err = 0;
int rank;
int remote;
int line = -1, err = 0, rank, remote;
char *tmpsend = NULL, *tmprecv = NULL;
ptrdiff_t sext, rext, lb;
@ -593,10 +582,8 @@ ompi_coll_tuned_allgatherv_intra_basic_default(void *sbuf, int scount,
struct ompi_communicator_t *comm,
mca_coll_base_module_t *module)
{
int i, size, rank ;
int err;
MPI_Aint extent;
MPI_Aint lb;
int i, size, rank, err;
MPI_Aint extent, lb;
char *send_buf = NULL;
struct ompi_datatype_t *newtype, *send_type;

Просмотреть файл

@ -50,8 +50,7 @@ ompi_coll_tuned_allreduce_intra_nonoverlapping(void *sbuf, void *rbuf, int count
struct ompi_communicator_t *comm,
mca_coll_base_module_t *module)
{
int err;
int rank;
int err, rank;
rank = ompi_comm_rank(comm);
@ -128,8 +127,7 @@ ompi_coll_tuned_allreduce_intra_recursivedoubling(void *sbuf, void *rbuf,
struct ompi_communicator_t *comm,
mca_coll_base_module_t *module)
{
int ret, line;
int rank, size, adjsize, remote, distance;
int ret, line, rank, size, adjsize, remote, distance;
int newrank, newremote, extra_ranks;
char *tmpsend = NULL, *tmprecv = NULL, *tmpswap = NULL, *inplacebuf = NULL;
ptrdiff_t true_lb, true_extent, lb, extent;
@ -345,13 +343,10 @@ ompi_coll_tuned_allreduce_intra_ring(void *sbuf, void *rbuf, int count,
struct ompi_communicator_t *comm,
mca_coll_base_module_t *module)
{
int ret, line;
int rank, size, k, recv_from, send_to;
int ret, line, rank, size, k, recv_from, send_to, block_count, inbi;
int early_segcount, late_segcount, split_rank, max_segcount;
int block_count, inbi;
size_t typelng;
char *tmpsend = NULL, *tmprecv = NULL;
char *inbuf[2] = {NULL, NULL};
char *tmpsend = NULL, *tmprecv = NULL, *inbuf[2] = {NULL, NULL};
ptrdiff_t true_lb, true_extent, lb, extent;
ptrdiff_t block_offset, max_real_segsize;
ompi_request_t *reqs[2] = {NULL, NULL};
@ -624,15 +619,11 @@ ompi_coll_tuned_allreduce_intra_ring_segmented(void *sbuf, void *rbuf, int count
mca_coll_base_module_t *module,
uint32_t segsize)
{
int ret, line;
int rank, size, k, recv_from, send_to;
int ret, line, rank, size, k, recv_from, send_to;
int early_blockcount, late_blockcount, split_rank;
int segcount, max_segcount;
int num_phases, phase;
int block_count, inbi;
int segcount, max_segcount, num_phases, phase, block_count, inbi;
size_t typelng;
char *tmpsend = NULL, *tmprecv = NULL;
char *inbuf[2] = {NULL, NULL};
char *tmpsend = NULL, *tmprecv = NULL, *inbuf[2] = {NULL, NULL};
ptrdiff_t true_lb, true_extent, lb, extent;
ptrdiff_t block_offset, max_real_segsize;
ompi_request_t *reqs[2] = {NULL, NULL};
@ -889,8 +880,7 @@ ompi_coll_tuned_allreduce_intra_basic_linear(void *sbuf, void *rbuf, int count,
struct ompi_communicator_t *comm,
mca_coll_base_module_t *module)
{
int err;
int rank;
int err, rank;
rank = ompi_comm_rank(comm);

Просмотреть файл

@ -36,9 +36,7 @@ int ompi_coll_tuned_alltoall_intra_pairwise(void *sbuf, int scount,
struct ompi_communicator_t *comm,
mca_coll_base_module_t *module)
{
int line = -1, err = 0;
int rank, size, step;
int sendto, recvfrom;
int line = -1, err = 0, rank, size, step, sendto, recvfrom;
void * tmpsend, *tmprecv;
ptrdiff_t lb, sext, rext;
@ -91,13 +89,10 @@ int ompi_coll_tuned_alltoall_intra_bruck(void *sbuf, int scount,
struct ompi_communicator_t *comm,
mca_coll_base_module_t *module)
{
int i, k, line = -1;
int rank, size;
int i, k, line = -1, rank, size, err = 0, weallocated = 0;
int sendto, recvfrom, distance, *displs = NULL, *blen = NULL;
char *tmpbuf = NULL, *tmpbuf_free = NULL;
ptrdiff_t rlb, slb, tlb, sext, rext, tsext;
int err = 0;
int weallocated = 0;
struct ompi_datatype_t *new_ddt;
#ifdef blahblah
mca_coll_tuned_module_t *tuned_module = (mca_coll_tuned_module_t*) module;
@ -256,15 +251,9 @@ int ompi_coll_tuned_alltoall_intra_linear_sync(void *sbuf, int scount,
mca_coll_base_module_t *module,
int max_outstanding_reqs)
{
int line, error;
int ri, si;
int rank;
int size;
int nreqs, nrreqs, nsreqs, total_reqs;
char *psnd;
char *prcv;
ptrdiff_t slb, sext;
ptrdiff_t rlb, rext;
int line, error, ri, si, rank, size, nreqs, nrreqs, nsreqs, total_reqs;
char *psnd, *prcv;
ptrdiff_t slb, sext, rlb, rext;
ompi_request_t **reqs = NULL;
@ -403,9 +392,7 @@ int ompi_coll_tuned_alltoall_intra_two_procs(void *sbuf, int scount,
struct ompi_communicator_t *comm,
mca_coll_base_module_t *module)
{
int line = -1, err = 0;
int rank;
int remote;
int line = -1, err = 0, rank, remote;
void * tmpsend, *tmprecv;
ptrdiff_t sext, rext, lb;
@ -474,21 +461,10 @@ int ompi_coll_tuned_alltoall_intra_basic_linear(void *sbuf, int scount,
struct ompi_communicator_t *comm,
mca_coll_base_module_t *module)
{
int i;
int rank;
int size;
int err;
int nreqs;
char *psnd;
char *prcv;
MPI_Aint lb;
MPI_Aint sndinc;
MPI_Aint rcvinc;
ompi_request_t **req;
ompi_request_t **sreq;
ompi_request_t **rreq;
int i, rank, size, err, nreqs;
char *psnd, *prcv;
MPI_Aint lb, sndinc, rcvinc;
ompi_request_t **req, **sreq, **rreq;
mca_coll_tuned_module_t *tuned_module = (mca_coll_tuned_module_t*) module;
mca_coll_tuned_comm_t *data = tuned_module->tuned_data;

Просмотреть файл

@ -38,9 +38,7 @@ ompi_coll_tuned_alltoallv_intra_pairwise(void *sbuf, int *scounts, int *sdisps,
struct ompi_communicator_t *comm,
mca_coll_base_module_t *module)
{
int line = -1, err = 0;
int rank, size, step;
int sendto, recvfrom;
int line = -1, err = 0, rank, size, step, sendto, recvfrom;
void *psnd, *prcv;
ptrdiff_t sext, rext;
@ -115,9 +113,8 @@ ompi_coll_tuned_alltoallv_intra_basic_linear(void *sbuf, int *scounts, int *sdis
struct ompi_communicator_t *comm,
mca_coll_base_module_t *module)
{
int i, size, rank, err;
int i, size, rank, err, nreqs;
char *psnd, *prcv;
int nreqs;
ptrdiff_t sext, rext;
MPI_Request *preq;
mca_coll_tuned_module_t *tuned_module = (mca_coll_tuned_module_t*) module;

Просмотреть файл

@ -52,10 +52,7 @@
int ompi_coll_tuned_barrier_intra_doublering(struct ompi_communicator_t *comm,
mca_coll_base_module_t *module)
{
int rank, size;
int err=0, line=0;
int left, right;
int rank, size, err = 0, line = 0, left, right;
rank = ompi_comm_rank(comm);
size = ompi_comm_size(comm);
@ -124,9 +121,7 @@ int ompi_coll_tuned_barrier_intra_doublering(struct ompi_communicator_t *comm,
int ompi_coll_tuned_barrier_intra_recursivedoubling(struct ompi_communicator_t *comm,
mca_coll_base_module_t *module)
{
int rank, size, adjsize;
int err, line;
int mask, remote;
int rank, size, adjsize, err, line, mask, remote;
rank = ompi_comm_rank(comm);
size = ompi_comm_size(comm);
@ -208,9 +203,7 @@ int ompi_coll_tuned_barrier_intra_recursivedoubling(struct ompi_communicator_t *
int ompi_coll_tuned_barrier_intra_bruck(struct ompi_communicator_t *comm,
mca_coll_base_module_t *module)
{
int rank, size;
int distance, to, from;
int err, line = 0;
int rank, size, distance, to, from, err, line = 0;
rank = ompi_comm_rank(comm);
size = ompi_comm_size(comm);
@ -280,12 +273,12 @@ int ompi_coll_tuned_barrier_intra_two_procs(struct ompi_communicator_t *comm,
static int ompi_coll_tuned_barrier_intra_basic_linear(struct ompi_communicator_t *comm,
mca_coll_base_module_t *module)
{
int i, err;
int size = ompi_comm_size(comm);
int rank = ompi_comm_rank(comm);
int i, err, rank, size;
rank = ompi_comm_rank(comm);
size = ompi_comm_size(comm);
/* All non-root send & receive zero-length message. */
if (rank > 0) {
err = MCA_PML_CALL(send (NULL, 0, MPI_BYTE, 0,
MCA_COLL_BASE_TAG_BARRIER,
@ -345,8 +338,7 @@ static int ompi_coll_tuned_barrier_intra_basic_linear(struct ompi_communicator_t
int ompi_coll_tuned_barrier_intra_tree(struct ompi_communicator_t *comm,
mca_coll_base_module_t *module)
{
int rank, size, depth;
int err, jump, partner;
int rank, size, depth, err, jump, partner;
rank = ompi_comm_rank(comm);
size = ompi_comm_size(comm);

Просмотреть файл

@ -39,20 +39,16 @@ ompi_coll_tuned_bcast_intra_generic( void* buffer,
uint32_t count_by_segment,
ompi_coll_tree_t* tree )
{
int err = 0, line, i;
int rank, size;
int segindex;
int err = 0, line, i, rank, size, segindex, req_index;
int num_segments; /* Number of segments */
int sendcount; /* number of elements sent in this segment */
size_t realsegsize;
size_t realsegsize, type_size;
char *tmpbuf;
size_t type_size;
ptrdiff_t extent, lb;
ompi_request_t *recv_reqs[2] = {MPI_REQUEST_NULL, MPI_REQUEST_NULL};
#if !defined(COLL_TUNED_BCAST_USE_BLOCKING)
ompi_request_t **send_reqs = NULL;
#endif
int req_index;
size = ompi_comm_size(comm);
rank = ompi_comm_rank(comm);
@ -378,16 +374,13 @@ ompi_coll_tuned_bcast_intra_split_bintree ( void* buffer,
mca_coll_base_module_t *module,
uint32_t segsize )
{
int err=0, line;
int rank, size;
int segindex, i, lr, pair;
int segcount[2]; /* Number of elements sent with each segment */
int err=0, line, rank, size, segindex, i, lr, pair;
uint32_t counts[2];
int segcount[2]; /* Number of elements sent with each segment */
int num_segments[2]; /* Number of segmenets */
int sendcount[2]; /* the same like segcount, except for the last segment */
size_t realsegsize[2];
size_t realsegsize[2], type_size;
char *tmpbuf[2];
size_t type_size;
ptrdiff_t type_extent, lb;
ompi_request_t *base_req, *new_req;
ompi_coll_tree_t *tree;
@ -646,14 +639,10 @@ ompi_coll_tuned_bcast_intra_basic_linear (void *buff, int count,
struct ompi_communicator_t *comm,
mca_coll_base_module_t *module)
{
int i;
int size;
int rank;
int err;
int i, size, rank, err;
mca_coll_tuned_module_t *tuned_module = (mca_coll_tuned_module_t*) module;
mca_coll_tuned_comm_t *data = tuned_module->tuned_data;
ompi_request_t **preq;
ompi_request_t **reqs = data->mcct_reqs;
ompi_request_t **preq, **reqs = data->mcct_reqs;
size = ompi_comm_size(comm);

Просмотреть файл

@ -98,8 +98,6 @@ ompi_coll_msg_rule_t* ompi_coll_tuned_mk_msg_rules (int n_msg_rules, int alg_rul
* Debug / IO routines
*
*/
int ompi_coll_tuned_dump_msg_rule (ompi_coll_msg_rule_t* msg_p)
{
if (!msg_p) {
@ -193,8 +191,6 @@ int ompi_coll_tuned_dump_all_rules (ompi_coll_alg_rule_t* alg_p, int n_rules)
* Memory free routines
*
*/
int ompi_coll_tuned_free_msg_rules_in_com_rule (ompi_coll_com_rule_t* com_p)
{
int rc=0;
@ -224,7 +220,6 @@ int ompi_coll_tuned_free_msg_rules_in_com_rule (ompi_coll_com_rule_t* com_p)
}
int ompi_coll_tuned_free_coms_in_alg_rule (ompi_coll_alg_rule_t* alg_p)
{
int rc=0;
@ -242,8 +237,7 @@ int ompi_coll_tuned_free_coms_in_alg_rule (ompi_coll_alg_rule_t* alg_p)
if (!com_p) {
OPAL_OUTPUT((ompi_coll_tuned_stream,"attempt to free NULL com_rules when com count was %d\n", alg_p->n_com_sizes));
}
else {
} else {
/* ok, memory exists for the com rules so free their message rules first */
for( i = 0; i < alg_p->n_com_sizes; i++ ) {
com_p = &(alg_p->com_rules[i]);
@ -274,8 +268,6 @@ int ompi_coll_tuned_free_all_rules (ompi_coll_alg_rule_t* alg_p, int n_algs)
return (rc);
}
/*
* query functions
* i.e. the functions that get me the algorithm, topo fanin/out and segment size fast

Просмотреть файл

@ -41,15 +41,8 @@ ompi_coll_tuned_gather_intra_binomial(void *sbuf, int scount,
struct ompi_communicator_t *comm,
mca_coll_base_module_t *module)
{
int line = -1;
int i;
int rank;
int vrank;
int size;
int total_recv = 0;
char *ptmp = NULL;
char *tempbuf = NULL;
int err;
int line = -1, i, rank, vrank, size, total_recv = 0, err;
char *ptmp = NULL, *tempbuf = NULL;
ompi_coll_tree_t* bmtree;
MPI_Status status;
MPI_Aint sextent, slb, strue_lb, strue_extent;
@ -216,18 +209,13 @@ ompi_coll_tuned_gather_intra_linear_sync(void *sbuf, int scount,
mca_coll_base_module_t *module,
int first_segment_size)
{
int i;
int ret, line;
int rank, size;
int first_segment_count;
int i, ret, line, rank, size, first_segment_count;
MPI_Aint extent, lb;
size_t typelng;
MPI_Aint extent;
MPI_Aint lb;
size = ompi_comm_size(comm);
rank = ompi_comm_rank(comm);
OPAL_OUTPUT((ompi_coll_tuned_stream,
"ompi_coll_tuned_gather_intra_linear_sync rank %d, segment %d", rank, first_segment_size));
@ -259,9 +247,9 @@ ompi_coll_tuned_gather_intra_linear_sync(void *sbuf, int scount,
root, MCA_COLL_BASE_TAG_GATHER,
MCA_PML_BASE_SEND_STANDARD, comm));
if (ret != MPI_SUCCESS) { line = __LINE__; goto error_hndl; }
}
else {
} else {
/* Root process,
- For every non-root node:
- post irecv for the first segment of the message
@ -369,14 +357,9 @@ ompi_coll_tuned_gather_intra_basic_linear(void *sbuf, int scount,
struct ompi_communicator_t *comm,
mca_coll_base_module_t *module)
{
int i;
int err;
int rank;
int size;
int i, err, rank, size;
char *ptmp;
MPI_Aint incr;
MPI_Aint extent;
MPI_Aint lb;
MPI_Aint incr, extent, lb;
size = ompi_comm_size(comm);
rank = ompi_comm_rank(comm);
@ -517,13 +500,10 @@ ompi_coll_tuned_gather_intra_do_forced(void *sbuf, int scount,
rbuf, rcount, rdtype,
root, comm, module);
case (3):
{
const int first_segment_size = data->user_forced[GATHER].segsize;
return ompi_coll_tuned_gather_intra_linear_sync (sbuf, scount, sdtype,
rbuf, rcount, rdtype,
root, comm, module,
first_segment_size);
}
data->user_forced[GATHER].segsize);
default:
OPAL_OUTPUT((ompi_coll_tuned_stream,
"coll:tuned:gather_intra_do_forced attempt to select algorithm %d when only 0-%d is valid?",

Просмотреть файл

@ -42,8 +42,6 @@ static int tuned_module_enable(mca_coll_base_module_t *module,
int ompi_coll_tuned_init_query(bool enable_progress_threads,
bool enable_mpi_threads)
{
/* Nothing to do */
return OMPI_SUCCESS;
}

Просмотреть файл

@ -483,9 +483,7 @@ int ompi_coll_tuned_reduce_intra_in_order_binary( void *sendbuf, void *recvbuf,
uint32_t segsize,
int max_outstanding_reqs )
{
int ret;
int rank, size, io_root;
int segcount = count;
int ret, rank, size, io_root, segcount = count;
void *use_this_sendbuf = NULL, *use_this_recvbuf = NULL;
size_t typelng;
mca_coll_tuned_module_t *tuned_module = (mca_coll_tuned_module_t*) module;
@ -603,10 +601,8 @@ ompi_coll_tuned_reduce_intra_basic_linear(void *sbuf, void *rbuf, int count,
{
int i, rank, err, size;
ptrdiff_t true_lb, true_extent, lb, extent;
char *free_buffer = NULL;
char *pml_buffer = NULL;
char *inplace_temp = NULL;
char *inbuf;
char *free_buffer = NULL, *pml_buffer = NULL;
char *inplace_temp = NULL, *inbuf;
/* Initialize */

Просмотреть файл

@ -45,14 +45,9 @@ int ompi_coll_tuned_reduce_scatter_intra_nonoverlapping(void *sbuf, void *rbuf,
struct ompi_communicator_t *comm,
mca_coll_base_module_t *module)
{
int err, i;
int rank, size;
int total_count;
int *displs = NULL;
char *tmprbuf = NULL;
char *tmprbuf_free = NULL;
int err, i, rank, size, total_count, *displs = NULL;
const int root = 0;
char *tmprbuf = NULL, *tmprbuf_free = NULL;
rank = ompi_comm_rank(comm);
size = ompi_comm_size(comm);
@ -133,8 +128,7 @@ ompi_coll_tuned_reduce_scatter_intra_basic_recursivehalving(void *sbuf,
mca_coll_base_module_t *module)
{
int i, rank, size, count, err = OMPI_SUCCESS;
int tmp_size, remain = 0, tmp_rank;
int *disps = NULL;
int tmp_size, remain = 0, tmp_rank, *disps = NULL;
ptrdiff_t true_lb, true_extent, lb, extent, buf_size;
char *recv_buf = NULL, *recv_buf_free = NULL;
char *result_buf = NULL, *result_buf_free = NULL;
@ -457,18 +451,13 @@ ompi_coll_tuned_reduce_scatter_intra_ring(void *sbuf, void *rbuf, int *rcounts,
struct ompi_communicator_t *comm,
mca_coll_base_module_t *module)
{
int ret, line;
int rank, size, i, k, recv_from, send_to;
int total_count, max_block_count;
int inbi;
int *displs = NULL;
size_t typelng;
char *tmpsend = NULL, *tmprecv = NULL;
char *inbuf_free[2] = {NULL, NULL};
char *inbuf[2] = {NULL, NULL};
char *accumbuf = NULL, *accumbuf_free = NULL;
int ret, line, rank, size, i, k, recv_from, send_to, total_count, max_block_count;
int inbi, *displs = NULL;
char *tmpsend = NULL, *tmprecv = NULL, *accumbuf = NULL, *accumbuf_free = NULL;
char *inbuf_free[2] = {NULL, NULL}, *inbuf[2] = {NULL, NULL};
ptrdiff_t true_lb, true_extent, lb, extent, max_real_segsize;
ompi_request_t *reqs[2] = {NULL, NULL};
size_t typelng;
size = ompi_comm_size(comm);
rank = ompi_comm_rank(comm);

Просмотреть файл

@ -39,15 +39,8 @@ ompi_coll_tuned_scatter_intra_binomial(void *sbuf, int scount,
struct ompi_communicator_t *comm,
mca_coll_base_module_t *module)
{
int line = -1;
int i;
int rank;
int vrank;
int size;
int total_send = 0;
char *ptmp = NULL;
char *tempbuf = NULL;
int err;
int line = -1, i, rank, vrank, size, total_send = 0, err;
char *ptmp, *tempbuf = NULL;
ompi_coll_tree_t* bmtree;
MPI_Status status;
MPI_Aint sextent, slb, strue_lb, strue_extent;
@ -71,6 +64,7 @@ ompi_coll_tuned_scatter_intra_binomial(void *sbuf, int scount,
ompi_datatype_get_true_extent(rdtype, &rtrue_lb, &rtrue_extent);
vrank = (rank - root + size) % size;
ptmp = (char *) rbuf; /* by default suppose leaf nodes, just use rbuf */
if (rank == root) {
if (0 == root) {
@ -123,9 +117,6 @@ ompi_coll_tuned_scatter_intra_binomial(void *sbuf, int scount,
scount = rcount;
sextent = rextent;
total_send = scount;
} else {
/* leaf nodes, just use rbuf */
ptmp = (char *) rbuf;
}
if (!(vrank % 2)) {
@ -209,8 +200,8 @@ ompi_coll_tuned_scatter_intra_basic_linear(void *sbuf, int scount,
mca_coll_base_module_t *module)
{
int i, rank, size, err;
char *ptmp;
ptrdiff_t lb, incr;
char *ptmp;
/* Initialize */

Просмотреть файл

@ -77,13 +77,10 @@ ompi_coll_tuned_topo_build_tree( int fanout,
struct ompi_communicator_t* comm,
int root )
{
int rank, size;
int schild, sparent;
int rank, size, schild, sparent, shiftedrank, i;
int level; /* location of my rank in the tree structure of size */
int delta; /* number of nodes on my level */
int slimit; /* total number of nodes on levels above me */
int shiftedrank;
int i;
ompi_coll_tree_t* tree;
OPAL_OUTPUT((ompi_coll_tuned_stream, "coll:tuned:topo_build_tree Building fo %d rt %d", fanout, root));
@ -192,9 +189,7 @@ ompi_coll_tuned_topo_build_tree( int fanout,
ompi_coll_tree_t*
ompi_coll_tuned_topo_build_in_order_bintree( struct ompi_communicator_t* comm )
{
int rank, size;
int myrank, rightsize, delta;
int parent, lchild, rchild;
int rank, size, myrank, rightsize, delta, parent, lchild, rchild;
ompi_coll_tree_t* tree;
/*
@ -329,14 +324,8 @@ ompi_coll_tree_t*
ompi_coll_tuned_topo_build_bmtree( struct ompi_communicator_t* comm,
int root )
{
int childs = 0;
int rank;
int size;
int mask = 1;
int index;
int remote;
int childs = 0, rank, size, mask = 1, index, remote, i;
ompi_coll_tree_t *bmtree;
int i;
OPAL_OUTPUT((ompi_coll_tuned_stream,"coll:tuned:topo:build_bmtree rt %d", root));
@ -411,13 +400,8 @@ ompi_coll_tree_t*
ompi_coll_tuned_topo_build_in_order_bmtree( struct ompi_communicator_t* comm,
int root )
{
int childs = 0;
int rank, vrank;
int size;
int mask = 1;
int remote;
int childs = 0, rank, vrank, size, mask = 1, remote, i;
ompi_coll_tree_t *bmtree;
int i;
OPAL_OUTPUT((ompi_coll_tuned_stream,"coll:tuned:topo:build_in_order_bmtree rt %d", root));
@ -475,10 +459,7 @@ ompi_coll_tuned_topo_build_chain( int fanout,
struct ompi_communicator_t* comm,
int root )
{
int rank, size;
int srank; /* shifted rank */
int i,maxchainlen;
int mark,head,len;
int i, maxchainlen, mark, head, len, rank, size, srank /* shifted rank */;
ompi_coll_tree_t *chain;
OPAL_OUTPUT((ompi_coll_tuned_stream,"coll:tuned:topo:build_chain fo %d rt %d", fanout, root));