X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/e5a5b0f6ee35cb592f9345a9dafa0e29df8477ef..af1adb0177f8402c6fe071f6043d64e009d2b439:/src/surf/cpu_ti.hpp diff --git a/src/surf/cpu_ti.hpp b/src/surf/cpu_ti.hpp index 93417f705f..e8fdacebc6 100644 --- a/src/surf/cpu_ti.hpp +++ b/src/surf/cpu_ti.hpp @@ -10,7 +10,6 @@ #include "src/surf/cpu_interface.hpp" #include "src/surf/trace_mgr.hpp" -#include "surf/surf_routing.h" /* Epsilon */ #define EPSILON 0.000000001 @@ -97,9 +96,9 @@ public: double getRemains() override; CpuTi *cpu_; - int indexHeap_; + int indexHeap_ = -1; int suspended_ = 0; -public: + boost::intrusive::list_member_hook<> action_ti_hook; }; @@ -111,12 +110,12 @@ typedef boost::intrusive::list ActionTiList; ************/ class CpuTi : public Cpu { public: - CpuTi(CpuTiModel *model, simgrid::s4u::Host *host, xbt_dynar_t speedPerPstate, int core); + CpuTi(CpuTiModel *model, simgrid::s4u::Host *host, std::vector *speedPerPstate, int core); ~CpuTi() override; void setSpeedTrace(tmgr_trace_t trace) override; - void apply_event(tmgr_trace_iterator_t event, double value) override; + void apply_event(tmgr_trace_event_t event, double value) override; void updateActionsFinishTime(double now); void updateRemainingAmount(double now); @@ -134,7 +133,6 @@ public: double currentFrequency_; -public: boost::intrusive::list_member_hook<> cpu_ti_hook; }; @@ -148,8 +146,8 @@ class CpuTiModel : public CpuModel { public: CpuTiModel(); ~CpuTiModel() override; - Cpu *createCpu(simgrid::s4u::Host *host, xbt_dynar_t speedPerPstate, int core) override; - double next_occuring_event(double now) override; + Cpu *createCpu(simgrid::s4u::Host *host, std::vector* speedPerPstate, int core) override; + double nextOccuringEvent(double now) override; void updateActionsState(double now, double delta) override; ActionList *runningActionSetThatDoesNotNeedBeingChecked_;