Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
[DVFS] Added 'override' specifier
authorChristian Heinrich <franz-christian.heinrich@inria.fr>
Tue, 13 Feb 2018 16:29:51 +0000 (17:29 +0100)
committerChristian Heinrich <franz-christian.heinrich@inria.fr>
Tue, 13 Feb 2018 18:53:17 +0000 (19:53 +0100)
src/surf/plugins/host_dvfs.cpp

index 2f21dcc..7f20af0 100644 (file)
@@ -62,16 +62,16 @@ class Performance : public Governor {
 public:
   explicit Performance(simgrid::s4u::Host* ptr) : Governor(ptr) {}
 
-  void update() { host->setPstate(0); }
-  std::string getName() { return "Performance"; }
+  void update() override { host->setPstate(0); }
+  std::string getName() override { return "Performance"; }
 };
 
 class Powersave : public Governor {
 public:
   explicit Powersave(simgrid::s4u::Host* ptr) : Governor(ptr) {}
 
-  void update() { host->setPstate(host->getPstatesCount() - 1); }
-  std::string getName() { return "Powersave"; }
+  void update() override { host->setPstate(host->getPstatesCount() - 1); }
+  std::string getName() override { return "Powersave"; }
 };
 
 class OnDemand : public Governor {
@@ -80,8 +80,8 @@ class OnDemand : public Governor {
 public:
   explicit OnDemand(simgrid::s4u::Host* ptr) : Governor(ptr) {}
 
-  std::string getName() { return "OnDemand"; }
-  void update()
+  std::string getName() override { return "OnDemand"; }
+  void update() override
   {
     double load = sg_host_get_current_load(host);
 
@@ -113,8 +113,8 @@ class Conservative : public Governor {
 public:
   explicit Conservative(simgrid::s4u::Host* ptr) : Governor(ptr) {}
 
-  virtual std::string getName() { return "Conservative"; }
-  virtual void update()
+  virtual std::string getName() override { return "Conservative"; }
+  virtual void update() override
   {
     double load = sg_host_get_current_load(host)*host->getCoreCount();
     int pstate  = host->getPstate();