Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
fix a gramatical error all over our variables
[simgrid.git] / src / surf / plugins / host_energy.cpp
index 8e3fa2d..f0e7c9b 100644 (file)
@@ -171,12 +171,12 @@ void HostEnergy::update()
 
     XBT_DEBUG("[update_energy of %s] period=[%.2f-%.2f]; current power peak=%.0E flop/s; consumption change: %.2f J -> "
               "%.2f J",
-              host->get_cname(), start_time, finish_time, host->pimpl_cpu->getSpeed(1.0), previous_energy,
+              host->get_cname(), start_time, finish_time, host->pimpl_cpu->get_speed(1.0), previous_energy,
               energy_this_step);
   }
 
   /* Save data for the upcoming time interval: whether it's on/off and the pstate if it's on */
-  this->pstate = host->is_on() ? host->getPstate() : pstate_off;
+  this->pstate = host->is_on() ? host->get_pstate() : pstate_off;
 }
 
 HostEnergy::HostEnergy(simgrid::s4u::Host* ptr) : host(ptr), last_updated(surf_get_clock())
@@ -235,7 +235,7 @@ double HostEnergy::getCurrentWattsValue()
     cpu_load = host->pimpl_cpu->get_constraint()->get_usage() / current_speed;
 
   /** Divide by the number of cores here **/
-  cpu_load /= host->pimpl_cpu->get_cores_count();
+  cpu_load /= host->pimpl_cpu->get_core_count();
 
   if (cpu_load > 1) // A machine with a load > 1 consumes as much as a fully loaded machine, not more
     cpu_load = 1;
@@ -286,7 +286,7 @@ double HostEnergy::getCurrentWattsValue(double cpu_load)
      * (maxCpuLoad is by definition 1)
      */
     double power_slope;
-    int coreCount         = host->getCoreCount();
+    int coreCount         = host->get_core_count();
     double coreReciprocal = static_cast<double>(1) / static_cast<double>(coreCount);
     if (coreCount > 1)
       power_slope = (max_power - min_power) / (1 - coreReciprocal);
@@ -320,14 +320,14 @@ void HostEnergy::initWattsRangeList()
 
   std::vector<std::string> all_power_values;
   boost::split(all_power_values, all_power_values_str, boost::is_any_of(","));
-  XBT_DEBUG("%s: profile: %s, cores: %d", host->get_cname(), all_power_values_str, host->getCoreCount());
+  XBT_DEBUG("%s: profile: %s, cores: %d", host->get_cname(), all_power_values_str, host->get_core_count());
 
   int i = 0;
   for (auto const& current_power_values_str : all_power_values) {
     /* retrieve the power values associated with the current pstate */
     std::vector<std::string> current_power_values;
     boost::split(current_power_values, current_power_values_str, boost::is_any_of(":"));
-    if (host->getCoreCount() == 1) {
+    if (host->get_core_count() == 1) {
       xbt_assert(current_power_values.size() == 2 || current_power_values.size() == 3,
                  "Power properties incorrectly defined for host %s."
                  "It should be 'Idle:FullSpeed' power values because you have one core only.",