From: Christian Heinrich Date: Wed, 18 Apr 2018 16:49:02 +0000 (+0200) Subject: [SMPI] Replay: Add comments to classes X-Git-Tag: v3.20~408 X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/commitdiff_plain/b13a264343d5efaa1eb9cec5cf0e1dd588efb6f0?ds=sidebyside [SMPI] Replay: Add comments to classes --- diff --git a/src/smpi/internals/smpi_replay.cpp b/src/smpi/internals/smpi_replay.cpp index e6fe8bc34e..8459a7f268 100644 --- a/src/smpi/internals/smpi_replay.cpp +++ b/src/smpi/internals/smpi_replay.cpp @@ -157,6 +157,9 @@ public: } }; +/** + * Base class for all parsers. + */ class ActionArgParser { public: virtual ~ActionArgParser() = default; @@ -500,6 +503,12 @@ public: } }; +/** + * Base class for all ReplayActions. + * Note that this class actually implements the behavior of each action + * while the parsing of the replay arguments is done in the @ActionArgParser class. + * In other words: The logic goes here, the setup is done by the ActionArgParser. + */ template class ReplayAction { protected: const std::string name; @@ -947,7 +956,6 @@ void smpi_replay_init(int* argc, char*** argv) xbt_replay_action_register("comm_size", [](simgrid::xbt::ReplayAction& action) { simgrid::smpi::replay::CommunicatorAction().execute(action); }); xbt_replay_action_register("comm_split",[](simgrid::xbt::ReplayAction& action) { simgrid::smpi::replay::CommunicatorAction().execute(action); }); xbt_replay_action_register("comm_dup", [](simgrid::xbt::ReplayAction& action) { simgrid::smpi::replay::CommunicatorAction().execute(action); }); - xbt_replay_action_register("send", [](simgrid::xbt::ReplayAction& action) { simgrid::smpi::replay::SendAction("send", storage[simgrid::s4u::this_actor::get_pid()-1]).execute(action); }); xbt_replay_action_register("Isend", [](simgrid::xbt::ReplayAction& action) { simgrid::smpi::replay::SendAction("Isend", storage[simgrid::s4u::this_actor::get_pid()-1]).execute(action); }); xbt_replay_action_register("recv", [](simgrid::xbt::ReplayAction& action) { simgrid::smpi::replay::RecvAction("recv", storage[simgrid::s4u::this_actor::get_pid()-1]).execute(action); });