A
lgorithmique
N
umérique
D
istribuée
Public GIT Repository
projects
/
simgrid.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
leaks -- with smp algos
[simgrid.git]
/
src
/
smpi
/
smpi_global.cpp
diff --git
a/src/smpi/smpi_global.cpp
b/src/smpi/smpi_global.cpp
index
c2f843f
..
76cd8d7
100644
(file)
--- a/
src/smpi/smpi_global.cpp
+++ b/
src/smpi/smpi_global.cpp
@@
-117,7
+117,7
@@
void smpi_process_init(int *argc, char ***argv)
data->argc = argc;
data->argv = argv;
// set the process attached to the mailbox
data->argc = argc;
data->argv = argv;
// set the process attached to the mailbox
- simcall_
rdv
_set_receiver(data->mailbox_small, proc);
+ simcall_
mbox
_set_receiver(data->mailbox_small, proc);
XBT_DEBUG("<%d> New process in the game: %p", index, proc);
}
xbt_assert(smpi_process_data(),
XBT_DEBUG("<%d> New process in the game: %p", index, proc);
}
xbt_assert(smpi_process_data(),
@@
-412,8
+412,8
@@
void smpi_global_init(void)
//process_data[i]->index = i;
process_data[i]->argc = NULL;
process_data[i]->argv = NULL;
//process_data[i]->index = i;
process_data[i]->argc = NULL;
process_data[i]->argv = NULL;
- process_data[i]->mailbox = simcall_
rdv
_create(get_mailbox_name(name, i));
- process_data[i]->mailbox_small = simcall_
rdv
_create(get_mailbox_name_small(name, i));
+ process_data[i]->mailbox = simcall_
mbox
_create(get_mailbox_name(name, i));
+ process_data[i]->mailbox_small = simcall_
mbox
_create(get_mailbox_name_small(name, i));
process_data[i]->mailboxes_mutex = xbt_mutex_init();
process_data[i]->timer = xbt_os_timer_new();
if (MC_is_active())
process_data[i]->mailboxes_mutex = xbt_mutex_init();
process_data[i]->timer = xbt_os_timer_new();
if (MC_is_active())
@@
-460,16
+460,18
@@
void smpi_global_destroy(void)
smpi_comm_destroy(process_data[i]->comm_intra);
}
xbt_os_timer_free(process_data[i]->timer);
smpi_comm_destroy(process_data[i]->comm_intra);
}
xbt_os_timer_free(process_data[i]->timer);
- simcall_rdv_destroy(process_data[i]->mailbox);
- simcall_rdv_destroy(process_data[i]->mailbox_small);
xbt_mutex_destroy(process_data[i]->mailboxes_mutex);
xbt_free(process_data[i]);
}
xbt_free(process_data);
process_data = NULL;
xbt_mutex_destroy(process_data[i]->mailboxes_mutex);
xbt_free(process_data[i]);
}
xbt_free(process_data);
process_data = NULL;
- if (MPI_COMM_WORLD != MPI_COMM_UNINITIALIZED)
+ if (MPI_COMM_WORLD != MPI_COMM_UNINITIALIZED){
+ smpi_comm_cleanup_smp(MPI_COMM_WORLD);
+ smpi_comm_cleanup_attributes(MPI_COMM_WORLD);
xbt_free(MPI_COMM_WORLD);
xbt_free(MPI_COMM_WORLD);
+ }
+
MPI_COMM_WORLD = MPI_COMM_NULL;
xbt_free(index_to_process_data);
MPI_COMM_WORLD = MPI_COMM_NULL;
xbt_free(index_to_process_data);