1
1
Этот коммит содержится в:
George Bosilca 2014-11-24 01:48:09 -05:00
родитель 2e00e335b9
Коммит fb6ecdfd18

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

@ -54,7 +54,7 @@ int mca_topo_base_dist_graph_distribute(mca_topo_base_module_t* module,
* In addition we compute 3 arrays (that are allocated in one go): * In addition we compute 3 arrays (that are allocated in one go):
* - cnt: the number of elements for a peer * - cnt: the number of elements for a peer
* - pos: the position of the first element for a peer * - pos: the position of the first element for a peer
* - idx: temporaru indexes and message count after the reduce. * - idx: temporary indexes and message count after the reduce.
*/ */
cnt = (mca_topo_base_dist_graph_elem_t*)calloc(3 * csize, sizeof(mca_topo_base_dist_graph_elem_t)); cnt = (mca_topo_base_dist_graph_elem_t*)calloc(3 * csize, sizeof(mca_topo_base_dist_graph_elem_t));
if( NULL == cnt ) { if( NULL == cnt ) {
@ -118,8 +118,8 @@ int mca_topo_base_dist_graph_distribute(mca_topo_base_module_t* module,
comm->c_coll.coll_allreduce_module); comm->c_coll.coll_allreduce_module);
/** /**
* At this point in the indexes array we have: * At this point in the indexes array we have:
* - indexes[0] total number of in edges * - idx[0].in total number of IN edges
* - indexes[1] total number of out edges * - idx[0].out total number of OUT edges
*/ */
topo = OBJ_NEW(mca_topo_base_comm_dist_graph_2_2_0_t); topo = OBJ_NEW(mca_topo_base_comm_dist_graph_2_2_0_t);
if( NULL == topo ) { if( NULL == topo ) {
@ -134,7 +134,7 @@ int mca_topo_base_dist_graph_distribute(mca_topo_base_module_t* module,
if (NULL == topo->in) { if (NULL == topo->in) {
err = OMPI_ERR_OUT_OF_RESOURCE; err = OMPI_ERR_OUT_OF_RESOURCE;
goto bail_out; goto bail_out;
} }
if (MPI_UNWEIGHTED != weights) { if (MPI_UNWEIGHTED != weights) {
topo->inw = (int*)malloc(sizeof(int) * topo->indegree); topo->inw = (int*)malloc(sizeof(int) * topo->indegree);
if (NULL == topo->inw) { if (NULL == topo->inw) {
@ -148,7 +148,7 @@ int mca_topo_base_dist_graph_distribute(mca_topo_base_module_t* module,
if (NULL == topo->out) { if (NULL == topo->out) {
err = OMPI_ERR_OUT_OF_RESOURCE; err = OMPI_ERR_OUT_OF_RESOURCE;
goto bail_out; goto bail_out;
} }
if (MPI_UNWEIGHTED != weights) { if (MPI_UNWEIGHTED != weights) {
topo->outw = (int*)malloc(sizeof(int) * topo->outdegree); topo->outw = (int*)malloc(sizeof(int) * topo->outdegree);
if (NULL == topo->outw) { if (NULL == topo->outw) {