From: Frederic Suter Date: Thu, 16 Mar 2017 18:41:07 +0000 (+0100) Subject: code killed by container usage X-Git-Tag: v3_15~84 X-Git-Url: http://bilbo.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/commitdiff_plain/c751cd28aa259c0de238a785fcdde9b099625d0b code killed by container usage --- diff --git a/examples/s4u/actions-comm/s4u_actions-comm.cpp b/examples/s4u/actions-comm/s4u_actions-comm.cpp index d62c029e11..1cbdbfbaa2 100644 --- a/examples/s4u/actions-comm/s4u_actions-comm.cpp +++ b/examples/s4u/actions-comm/s4u_actions-comm.cpp @@ -85,8 +85,6 @@ public: int main(int argc, char *argv[]) { simgrid::s4u::Engine* e = new simgrid::s4u::Engine(&argc, argv); - /* Explicit initialization of the action module is required now*/ - simgrid::xbt::replay_init(); xbt_assert(argc > 2, "Usage: %s platform_file deployment_file [action_files]\n" "\t# if all actions are in the same file\n" @@ -120,7 +118,5 @@ int main(int argc, char *argv[]) XBT_INFO("Simulation time %g", e->getClock()); - simgrid::xbt::replay_exit(); /* Explicit finalization of the action module */ - return 0; } diff --git a/include/xbt/replay.hpp b/include/xbt/replay.hpp index a317f34c92..be41b1c99a 100644 --- a/include/xbt/replay.hpp +++ b/include/xbt/replay.hpp @@ -22,9 +22,6 @@ typedef std::vector ReplayAction; static std::unordered_map*> action_queues; XBT_PUBLIC_DATA(std::ifstream*) action_fs; -XBT_PUBLIC(bool) replay_is_active(); -XBT_PUBLIC(void) replay_init(); -XBT_PUBLIC(void) replay_exit(); XBT_PUBLIC(int) replay_runner(int argc, char* argv[]); } } diff --git a/src/msg/msg_actions.cpp b/src/msg/msg_actions.cpp index 916aa87422..4d9d7ef381 100644 --- a/src/msg/msg_actions.cpp +++ b/src/msg/msg_actions.cpp @@ -14,13 +14,12 @@ SG_BEGIN_DECL() void MSG_action_init() { - simgrid::xbt::replay_init(); MSG_function_register_default(simgrid::xbt::replay_runner); } void MSG_action_exit() { - simgrid::xbt::replay_exit(); + // Nothing to do anymore here } /** \ingroup msg_trace_driven diff --git a/src/smpi/smpi_global.cpp b/src/smpi/smpi_global.cpp index c5b7734db1..9ca25bed45 100644 --- a/src/smpi/smpi_global.cpp +++ b/src/smpi/smpi_global.cpp @@ -212,7 +212,7 @@ bool smpi_process_get_replaying(){ if (index != MPI_UNDEFINED) return process_data[index_to_process_data[index]]->replaying; else - return !simgrid::xbt::replay_is_active(); + return false; } int smpi_global_size() diff --git a/src/smpi/smpi_replay.cpp b/src/smpi/smpi_replay.cpp index 031d0d8824..7eabab4fac 100644 --- a/src/smpi/smpi_replay.cpp +++ b/src/smpi/smpi_replay.cpp @@ -909,7 +909,6 @@ void smpi_replay_run(int *argc, char***argv){ TRACE_smpi_collective_in(rank, -1, operation, extra); TRACE_smpi_collective_out(rank, -1, operation); xbt_free(operation); - simgrid::xbt::replay_init(); xbt_replay_action_register("init", action_init); xbt_replay_action_register("finalize", action_finalize); xbt_replay_action_register("comm_size", action_comm_size); @@ -973,7 +972,6 @@ void smpi_replay_run(int *argc, char***argv){ if(active_processes==0){ /* Last process alive speaking: end the simulated timer */ XBT_INFO("Simulation time %f", smpi_process_simulated_elapsed()); - simgrid::xbt::replay_exit(); xbt_free(sendbuffer); xbt_free(recvbuffer); } diff --git a/src/xbt/xbt_replay.cpp b/src/xbt/xbt_replay.cpp index 40b5cee45a..856d50937b 100644 --- a/src/xbt/xbt_replay.cpp +++ b/src/xbt/xbt_replay.cpp @@ -18,8 +18,6 @@ XBT_LOG_NEW_DEFAULT_SUBCATEGORY(replay,xbt,"Replay trace reader"); -bool is_replay_active = false; - namespace simgrid { namespace xbt { @@ -70,22 +68,6 @@ bool ReplayReader::get(ReplayAction* action) } } -void replay_init() -{ - if (!is_replay_active) { - is_replay_active = true; - } -} - -void replay_exit() -{ -} - -bool replay_is_active() -{ - return is_replay_active; -} - static ReplayAction* get_action(char* name) { ReplayAction* action; @@ -218,7 +200,5 @@ int replay_runner(int argc, char* argv[]) */ void xbt_replay_action_register(const char* action_name, action_fun function) { - if (!is_replay_active) // If the user registers a function before the start - simgrid::xbt::replay_init(); simgrid::xbt::action_funs.insert({std::string(action_name), function}); }