Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
[HostLoad] Load is currently 0 because of integer division. Fix that.
[simgrid.git] / src / surf / plugins / host_load.cpp
index 9b2a880..ebe41f4 100644 (file)
@@ -76,7 +76,7 @@ void HostLoad::update()
 
 double HostLoad::getCurrentLoad()
 {
 
 double HostLoad::getCurrentLoad()
 {
-  return current_flops / (host->getSpeed() * host->getCoreCount());
+  return current_flops / static_cast<double>(host->getSpeed() * host->getCoreCount());
 }
 
 double HostLoad::getAverageLoad()
 }
 
 double HostLoad::getAverageLoad()