Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
surf/Cbinding: kill an unused and misnamed function
authorMartin Quinson <martin.quinson@loria.fr>
Sun, 8 Jul 2018 09:34:00 +0000 (11:34 +0200)
committerMartin Quinson <martin.quinson@loria.fr>
Sun, 8 Jul 2018 09:34:00 +0000 (11:34 +0200)
src/include/surf/surf.hpp
src/surf/surf_c_bindings.cpp
teshsuite/surf/surf_usage2/surf_usage2.cpp

index 7fb194e..146f104 100644 (file)
 
 /** @{ @ingroup SURF_c_bindings */
 
 
 /** @{ @ingroup SURF_c_bindings */
 
-/**
- * @brief Get the size of the running action set of a model
- *
- * @param model The model
- * @return The size of the running action set
- */
-XBT_PUBLIC int surf_model_running_action_set_size(simgrid::kernel::resource::Model* model);
-
 /**
  * @brief [brief description]
  * @details [long description]
 /**
  * @brief [brief description]
  * @details [long description]
index 22f7a3a..6830528 100644 (file)
@@ -152,11 +152,6 @@ double surf_solve(double max_date)
 /*********
  * MODEL *
  *********/
 /*********
  * MODEL *
  *********/
-int surf_model_running_action_set_size(simgrid::kernel::resource::Model* model)
-{
-  return model->get_started_action_set()->size();
-}
-
 void surf_cpu_action_set_bound(simgrid::kernel::resource::Action* action, double bound)
 {
   static_cast<simgrid::surf::CpuAction*>(action)->set_bound(bound);
 void surf_cpu_action_set_bound(simgrid::kernel::resource::Action* action, double bound)
 {
   static_cast<simgrid::surf::CpuAction*>(action)->set_bound(bound);
index c1ab1b9..ad7afbc 100644 (file)
@@ -46,7 +46,7 @@ int main(int argc, char **argv)
     XBT_INFO("Next Event : %g", now);
 
     for (auto const& model : *all_existing_models) {
     XBT_INFO("Next Event : %g", now);
 
     for (auto const& model : *all_existing_models) {
-      if (surf_model_running_action_set_size(model)) {
+      if (model->get_started_action_set()->size() != 0) {
         XBT_DEBUG("\t Running that model");
         running = 1;
       }
         XBT_DEBUG("\t Running that model");
         running = 1;
       }