SimGrid  3.18
Versatile Simulation of Distributed Systems
simgrid::surf::CpuCas01Action Class Reference

#include <cpu_cas01.hpp>

Inheritance diagram for simgrid::surf::CpuCas01Action:
simgrid::surf::CpuAction simgrid::surf::Action

Public Member Functions

 CpuCas01Action (Model *model, double cost, bool failed, double speed, lmm_constraint_t constraint, int coreAmount)
 
 CpuCas01Action (Model *model, double cost, bool failed, double speed, lmm_constraint_t constraint)
 
 ~CpuCas01Action () override
 
int requestedCore ()
 
- Public Member Functions inherited from simgrid::surf::CpuAction
 CpuAction (simgrid::surf::Model *model, double cost, bool failed)
 
 CpuAction (simgrid::surf::Model *model, double cost, bool failed, lmm_variable_t var)
 
void setState (simgrid::surf::Action::State state) override
 Set the state of the current Action. More...
 
void updateRemainingLazy (double now) override
 
std::list< Cpu * > cpus ()
 returns a list of all CPUs that this action is using More...
 
void suspend () override
 Suspend the current Action. More...
 
void resume () override
 Resume the current Action. More...
 
- Public Member Functions inherited from simgrid::surf::Action
 Action (simgrid::surf::Model *model, double cost, bool failed)
 Action constructor. More...
 
 Action (simgrid::surf::Model *model, double cost, bool failed, lmm_variable_t var)
 Action constructor. More...
 
virtual ~Action ()
 Destructor. More...
 
void finish (Action::State state)
 Mark that the action is now finished. More...
 
Action::State getState () const
 Get the state of the current Action. More...
 
double getBound () const
 Get the bound of the current Action. More...
 
void setBound (double bound)
 Set the bound of the current Action. More...
 
double getStartTime () const
 Get the start time of the current action. More...
 
double getFinishTime () const
 Get the finish time of the current action. More...
 
voidgetData () const
 Get the user data associated to the current action. More...
 
void setData (void *data)
 Set the user data associated to the current action. More...
 
double getCost () const
 Get the cost of the current action. More...
 
void setCost (double cost)
 Set the cost of the current action. More...
 
void updateMaxDuration (double delta)
 Update the maximum duration of the current action. More...
 
void updateRemains (double delta)
 Update the remaining time of the current action. More...
 
void setRemains (double value)
 Set the remaining time of the current action. More...
 
virtual double getRemains ()
 Get the remaining time of the current action after updating the resource. More...
 
double getRemainsNoUpdate () const
 Get the remaining time of the current action without updating the resource. More...
 
void setFinishTime (double value)
 Set the finish time of the current action. More...
 
void ref ()
 Add a reference to the current action (refcounting) More...
 
virtual int unref ()
 Unref that action (and destroy it if refcount reaches 0) More...
 
virtual void cancel ()
 Cancel the current Action if running. More...
 
virtual bool isSuspended ()
 Returns true if the current action is running. More...
 
double getMaxDuration () const
 Get the maximum duration of the current action. More...
 
virtual void setMaxDuration (double duration)
 Set the maximum duration of the current Action. More...
 
char * getCategory () const
 Get the tracing category associated to the current action. More...
 
void setCategory (const char *category)
 Set the tracing category of the current Action. More...
 
double getPriority () const
 Get the priority of the current Action. More...
 
virtual void setSharingWeight (double priority)
 Set the priority of the current Action. More...
 
void setSharingWeightNoUpdate (double weight)
 
ActionListgetStateSet () const
 Get the state set in which the action is. More...
 
simgrid::surf::ModelgetModel () const
 
void heapInsert (heap_type &heap, double key, enum heap_action_type hat)
 
void heapRemove (heap_type &heap)
 
void heapUpdate (heap_type &heap, double key, enum heap_action_type hat)
 
void clearHeapHandle ()
 
lmm_variable_t getVariable () const
 
void setVariable (lmm_variable_t var)
 
double getLastUpdate () const
 
void refreshLastUpdate ()
 
double getLastValue () const
 
void setLastValue (double val)
 
enum heap_action_type getHat () const
 
bool is_linked () const
 

Friends

CpuActionCpuCas01::execution_start (double size)
 
CpuActionCpuCas01::sleep (double duration)
 

Additional Inherited Members

- Public Types inherited from simgrid::surf::Action
enum  State {
  State::ready = 0, State::running, State::failed, State::done,
  State::to_free, State::not_in_the_system
}
 
typedef boost::intrusive::member_hook< Action, boost::intrusive::list_member_hook<>, &Action::action_hookActionOptions
 
typedef boost::intrusive::list< Action, ActionOptionsActionList
 
- Public Attributes inherited from simgrid::surf::Action
boost::intrusive::list_member_hook action_hook
 
boost::intrusive::list_member_hook action_lmm_hook
 
- Static Public Attributes inherited from simgrid::surf::CpuAction
static simgrid::xbt::signal< void(simgrid::surf::CpuAction *, simgrid::surf::Action::State)> onStateChange
 Signal emitted when the action state changes (ready/running/done, etc) Signature: void(CpuAction *action, simgrid::surf::Action::State previous) More...
 
static simgrid::xbt::signal< void(simgrid::surf::CpuAction *)> onShareChange
 Signal emitted when the action share changes (amount of flops it gets) Signature: void(CpuAction *action) More...
 
- Protected Attributes inherited from simgrid::surf::Action
ActionListstateSet_
 
int refcount_ = 1
 
int suspended_ = 0
 

Constructor & Destructor Documentation

◆ CpuCas01Action() [1/2]

simgrid::surf::CpuCas01Action::CpuCas01Action ( Model model,
double  cost,
bool  failed,
double  speed,
lmm_constraint_t  constraint,
int  coreAmount 
)

◆ CpuCas01Action() [2/2]

simgrid::surf::CpuCas01Action::CpuCas01Action ( Model model,
double  cost,
bool  failed,
double  speed,
lmm_constraint_t  constraint 
)

◆ ~CpuCas01Action()

simgrid::surf::CpuCas01Action::~CpuCas01Action ( )
overridedefault

Member Function Documentation

◆ requestedCore()

int simgrid::surf::CpuCas01Action::requestedCore ( )

Friends And Related Function Documentation

◆ CpuCas01::execution_start

CpuAction* CpuCas01::execution_start ( double  size)
friend

◆ CpuCas01::sleep

CpuAction* CpuCas01::sleep ( double  duration)
friend

The documentation for this class was generated from the following files: