X-Git-Url: http://bilbo.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/e30d391831c58e590aa83dce5f30f218cc3f53ce..171293b2177631594dafc0a8449ee370aebdd305:/src/surf/surf_interface.cpp diff --git a/src/surf/surf_interface.cpp b/src/surf/surf_interface.cpp index 2ed96e5e92..db2ad1fb11 100644 --- a/src/surf/surf_interface.cpp +++ b/src/surf/surf_interface.cpp @@ -4,7 +4,6 @@ * under the terms of the license (GNU LGPL) which comes with this package. */ #include "surf_interface.hpp" -#include "instr/instr_interface.hpp" // TRACE_is_enabled(). FIXME: remove by subscribing tracing to the surf signals #include "mc/mc.h" #include "simgrid/s4u/Engine.hpp" #include "simgrid/sg_config.hpp" @@ -12,6 +11,7 @@ #include "src/surf/HostImpl.hpp" #include "src/surf/xml/platf.hpp" #include "surf/surf.hpp" +#include "xbt/module.h" #include #include @@ -36,19 +36,15 @@ std::vector host_that_restart; std::set watched_hosts; extern std::map storage_types; -namespace simgrid { -namespace surf { - -simgrid::xbt::signal surfExitCallbacks; -} -} - +#include // FIXME: this plug-in should not be linked to the core #include // FIXME: this plug-in should not be linked to the core #include // FIXME: this plug-in should not be linked to the core s_surf_model_description_t surf_plugin_description[] = { - {"Energy", "Cpu energy consumption.", &sg_host_energy_plugin_init}, - {"Load", "Cpu load.", &sg_host_load_plugin_init}, + {"host_energy", "Cpu energy consumption.", &sg_host_energy_plugin_init}, + {"link_energy", "Link energy consumption.", &sg_link_energy_plugin_init}, + {"host_dvfs", "Dvfs support", &sg_host_dvfs_plugin_init}, + {"host_load", "Cpu load.", &sg_host_load_plugin_init}, {nullptr, nullptr, nullptr} /* this array must be nullptr terminated */ }; @@ -311,10 +307,7 @@ void surf_init(int *argc, char **argv) void surf_exit() { - TRACE_end(); /* Just in case it was not called by the upper layer (or there is no upper layer) */ - simgrid::s4u::Engine::shutdown(); - sg_link_exit(); for (auto const& e : storage_types) { simgrid::surf::StorageType* stype = e.second; delete stype->properties; @@ -326,11 +319,8 @@ void surf_exit() delete model; delete all_existing_models; - - if (future_evt_set) { - delete future_evt_set; - future_evt_set = nullptr; - } + delete future_evt_set; + future_evt_set = nullptr; tmgr_finalize(); sg_platf_exit();