- CpuTiAction() {};
- CpuTiAction(CpuTiModelPtr model, double cost, bool failed,
- CpuTiPtr cpu);
-
- void setState(e_surf_action_state_t state);
- int unref();
- void cancel();
- void recycle();
- void updateIndexHeap(int i);
- void suspend();
- void resume();
- bool isSuspended();
- void setMaxDuration(double duration);
- void setPriority(double priority);
- double getRemains();
- void setAffinity(CpuPtr /*cpu*/, unsigned long /*mask*/) {};
-
- CpuTiPtr p_cpu;
- int m_indexHeap;
- s_xbt_swag_hookup_t p_cpuListHookup;
- int m_suspended;
-private:
+ CpuTiModel();
+ ~CpuTiModel();
+ Cpu *createCpu(simgrid::s4u::Host *host, xbt_dynar_t speedPeak,
+ int pstate, double speedScale,
+ tmgr_trace_t speedTrace, int core,
+ int initiallyOn,
+ tmgr_trace_t state_trace) override;
+ double next_occuring_event(double now) override;
+ void updateActionsState(double now, double delta) override;
+ void addTraces() override;
+
+ ActionList *p_runningActionSetThatDoesNotNeedBeingChecked;
+ CpuTiList *p_modifiedCpu;
+ xbt_heap_t p_tiActionHeap;
+
+protected:
+ void NotifyResourceTurnedOn(simgrid::surf::Resource*){};
+ void NotifyResourceTurnedOff(simgrid::surf::Resource*){};
+
+ void NotifyActionCancel(Action*){};
+ void NotifyActionResume(Action*){};
+ void NotifyActionSuspend(Action*){};