Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
SMPI: simplifies the process destruction
authorMartin Quinson <martin.quinson@loria.fr>
Tue, 11 Apr 2017 22:09:06 +0000 (00:09 +0200)
committerMartin Quinson <martin.quinson@loria.fr>
Wed, 12 Apr 2017 05:53:04 +0000 (07:53 +0200)
src/smpi/smpi_pmpi.cpp
src/smpi/smpi_process.cpp
src/smpi/smpi_process.hpp
src/smpi/smpi_replay.cpp

index a35f124..85fd0e5 100644 (file)
@@ -57,7 +57,6 @@ int PMPI_Finalize()
 
   TRACE_smpi_collective_out(rank, -1, __FUNCTION__);
   TRACE_smpi_finalize(smpi_process()->index());
-  smpi_process()->destroy();
   return MPI_SUCCESS;
 }
 
@@ -113,7 +112,6 @@ int PMPI_Is_thread_main(int *flag)
 int PMPI_Abort(MPI_Comm comm, int errorcode)
 {
   smpi_bench_end();
-  smpi_process()->destroy();
   // FIXME: should kill all processes in comm instead
   simcall_process_kill(SIMIX_process_self());
   return MPI_SUCCESS;
index c0f7c39..4691886 100644 (file)
@@ -88,18 +88,12 @@ void Process::set_data(int index, int* argc, char*** argv)
     XBT_DEBUG("<%d> New process in the game: %p", index_, SIMIX_process_self());
 }
 
-void Process::destroy()
+/** @brief Prepares the current process for termination. */
+void Process::finalize()
 {
-  if(smpi_privatize_global_variables == SMPI_PRIVATIZE_MMAP){
-    smpi_switch_data_segment(index_);
-  }
   state_ = SMPI_FINALIZED;
   XBT_DEBUG("<%d> Process left the game", index_);
-}
 
-/** @brief Prepares the current process for termination. */
-void Process::finalize()
-{
     // This leads to an explosion of the search graph which cannot be reduced:
     if(MC_is_active() || MC_record_replay_is_active())
       return;
index 10d6bb6..173e357 100644 (file)
@@ -44,7 +44,6 @@ class Process {
 #endif
   public:
     explicit Process(int index);
-    void destroy();
     void set_data(int index, int* argc, char*** argv);
     void finalize();
     int finalized();
index f406072..ada1fec 100644 (file)
@@ -988,6 +988,5 @@ void smpi_replay_run(int *argc, char***argv){
 
   TRACE_smpi_collective_out(rank, -1, operation);
   TRACE_smpi_finalize(smpi_process()->index());
-  smpi_process()->destroy();
   xbt_free(operation);
 }