From c52513a95d2f503e125b425e37fabaf11c046e9c Mon Sep 17 00:00:00 2001 From: "Lucas M. Schnorr" Date: Tue, 28 Mar 2017 09:39:28 +0200 Subject: [PATCH] tracing TODO marks --- src/surf/plugins/host_energy.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/surf/plugins/host_energy.cpp b/src/surf/plugins/host_energy.cpp index d64ed6f12a..17fd032048 100644 --- a/src/surf/plugins/host_energy.cpp +++ b/src/surf/plugins/host_energy.cpp @@ -143,6 +143,8 @@ void HostEnergy::update() double energy_this_step = instantaneous_consumption * (finish_time - start_time); + //TODO Trace: Trace energy_this_step from start_time to finish_time in host->name() + this->total_energy = previous_energy + energy_this_step; this->last_updated = finish_time; this->pstate = host->pstate(); @@ -275,6 +277,9 @@ static void onCreation(simgrid::s4u::Host& host) { if (dynamic_cast(&host)) // Ignore virtual machines return; + + //TODO Trace: set to zero the energy variable associated to host->name() + host.extension_set(new HostEnergy(&host)); } -- 2.20.1