Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Merge branch 'master' of git+ssh://scm.gforge.inria.fr//gitroot/simgrid/simgrid
[simgrid.git] / src / smpi / mpi / smpi_datatype.cpp
index 42372173590c9a10a8185945e9f0f14b17aece5e..d60ea40d3eba91e9655f1b934a93f9861a6e6728 100644 (file)
@@ -198,6 +198,12 @@ bool Datatype::is_basic()
   return (flags_ & DT_FLAG_BASIC);
 }
 
+bool Datatype::is_replayable()
+{
+  return ((this==MPI_BYTE)||(this==MPI_DOUBLE)||(this==MPI_INT)||
+          (this==MPI_CHAR)||(this==MPI_SHORT)||(this==MPI_LONG)||(this==MPI_FLOAT));
+}
+
 size_t Datatype::size(){
   return size_;
 }
@@ -271,7 +277,7 @@ int Datatype::copy(void *sendbuf, int sendcount, MPI_Datatype sendtype,
 // FIXME Handle the case of a partial shared malloc.
 
   if(smpi_privatize_global_variables == SMPI_PRIVATIZE_MMAP){
-    smpi_switch_data_segment(smpi_process()->index());
+    smpi_switch_data_segment(simgrid::s4u::Actor::self()->getPid());
   }
   /* First check if we really have something to do */
   if (recvcount > 0 && recvbuf != sendbuf) {