Commit 376c140a authored by Augustin Degomme's avatar Augustin Degomme

leak--

parent 284ad496
Pipeline #193595 failed with stages
in 27 minutes and 14 seconds
......@@ -47,11 +47,6 @@ Topo_Cart::Topo_Cart(MPI_Comm comm_old, int ndims, const int dims[], const int p
*comm_cart = MPI_COMM_NULL;
return;
}
oldGroup = comm_old->group();
newGroup = new Group(newSize);
for (int i = 0 ; i < newSize ; i++) {
newGroup->set_mapping(oldGroup->actor(i), i);
}
nnodes_ = newSize;
......@@ -65,8 +60,15 @@ Topo_Cart::Topo_Cart(MPI_Comm comm_old, int ndims, const int dims[], const int p
position_[i] = rank / nranks;
rank = rank % nranks;
}
if(comm_cart != nullptr)
if(comm_cart != nullptr){
oldGroup = comm_old->group();
newGroup = new Group(newSize);
for (int i = 0 ; i < newSize ; i++) {
newGroup->set_mapping(oldGroup->actor(i), i);
}
*comm_cart = new Comm(newGroup, this);
}
} else {
if(comm_cart != nullptr){
if (rank == 0) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment