Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Merge branch 'master' of scm.gforge.inria.fr:/gitroot/simgrid/simgrid
[simgrid.git] / src / mc / remote / Client.cpp
index f515ae4..ca22d20 100644 (file)
@@ -5,6 +5,7 @@
 
 #include <cerrno>
 #include <cstdlib>
+#include <cstring>
 
 #include <sys/ptrace.h>
 #include <sys/socket.h>
@@ -76,7 +77,7 @@ Client* Client::initialize()
 #error "no ptrace equivalent coded for this platform"
 #endif
   if (errno != 0 || raise(SIGSTOP) != 0)
-    xbt_die("Could not wait for the model-checker");
+    xbt_die("Could not wait for the model-checker (errno = %d: %s)", errno, strerror(errno));
 
   instance_->handleMessages();
   return instance_.get();
@@ -114,7 +115,7 @@ void Client::handleSimcall(s_mc_message_simcall_handle_t* message)
 void Client::handleRestore(s_mc_message_restore_t* message)
 {
 #if HAVE_SMPI
-  smpi_really_switch_data_segment(simgrid::s4u::Actor::byPid(message->index));
+  smpi_really_switch_data_segment(simgrid::s4u::Actor::by_pid(message->index));
 #endif
 }
 void Client::handleActorEnabled(s_mc_message_actor_enabled_t* msg)
@@ -258,8 +259,8 @@ void Client::declareStack(void* stack, size_t size, smx_actor_t process, ucontex
   region.size    = size;
   region.block   = ((char*)stack - (char*)heap->heapbase) / BLOCKSIZE + 1;
 #if HAVE_SMPI
-  if (smpi_privatize_global_variables == SMPI_PRIVATIZE_MMAP && process)
-    region.process_index = process->pid - 1;
+  if (smpi_privatize_global_variables == SmpiPrivStrategies::MMAP && process)
+    region.process_index = process->pid_ - 1;
   else
 #endif
     region.process_index = -1;