Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Quick and dirty support of SendRecv in time-independent traces
[simgrid.git] / src / smpi / include / smpi_replay.hpp
index 1f00a19..c5c5289 100644 (file)
@@ -58,7 +58,7 @@ public:
   void parse(xbt::ReplayAction& action, const std::string& name) override;
 };
 
-class SendRecvParser : public ActionArgParser {
+class SendOrRecvParser : public ActionArgParser {
 public:
   /* communication partner; if we send, this is the receiver and vice versa */
   int partner;
@@ -103,6 +103,18 @@ public:
   MPI_Datatype datatype2;
 };
 
+class SendRecvParser : public ActionArgParser {
+public:
+  int dst;
+  int src;
+  int sendcount;
+  int recvcount;
+  MPI_Datatype datatype1;
+  MPI_Datatype datatype2;
+
+  void parse(xbt::ReplayAction& action, const std::string& name) override;
+};
+
 class BcastArgParser : public CollCommParser {
 public:
   void parse(xbt::ReplayAction& action, const std::string& name) override;
@@ -219,7 +231,7 @@ public:
   void kernel(xbt::ReplayAction& action) override;
 };
 
-class SendAction : public ReplayAction<SendRecvParser> {
+class SendAction : public ReplayAction<SendOrRecvParser> {
   RequestStorage& req_storage;
 
 public:
@@ -227,7 +239,7 @@ public:
   void kernel(xbt::ReplayAction& action) override;
 };
 
-class RecvAction : public ReplayAction<SendRecvParser> {
+class RecvAction : public ReplayAction<SendOrRecvParser> {
   RequestStorage& req_storage;
 
 public:
@@ -282,6 +294,12 @@ public:
   void kernel(xbt::ReplayAction& action) override;
 };
 
+class SendRecvAction : public ReplayAction<SendRecvParser> {
+public:
+  explicit SendRecvAction() : ReplayAction("sendrecv") {}
+  void kernel(xbt::ReplayAction& action) override;
+};
+
 class BarrierAction : public ReplayAction<ActionArgParser> {
 public:
   explicit BarrierAction() : ReplayAction("barrier") {}