SimGrid  3.12
Versatile Simulation of Distributed Systems
CpuAction Class Reference

SURF Cpu action interface class. More...

#include <cpu_interface.hpp>

Inheritance diagram for CpuAction:
Action

Public Member Functions

 CpuAction (Model *model, double cost, bool failed)
 CpuAction constructor. More...
 
 CpuAction (Model *model, double cost, bool failed, lmm_variable_t var)
 CpuAction constructor. More...
 
virtual void setAffinity (Cpu *cpu, unsigned long mask)
 Set the affinity of the current CpuAction. More...
 
void setState (e_surf_action_state_t state)
 Set the state of the current Action.
 
- Public Member Functions inherited from Action
 Action (Model *model, double cost, bool failed)
 Action constructor. More...
 
 Action (Model *model, double cost, bool failed, lmm_variable_t var)
 Action constructor. More...
 
virtual ~Action ()
 Destructor.
 
void finish ()
 Mark that the action is now finished.
 
e_surf_action_state_t getState ()
 Get the state of the current Action. More...
 
double getBound ()
 Get the bound of the current Action.
 
void setBound (double bound)
 Set the bound of the current Action.
 
double getStartTime ()
 Get the start time of the current action.
 
double getFinishTime ()
 Get the finish time of the current action.
 
void * getData ()
 Get the user data associated to the current action.
 
void setData (void *data)
 Set the user data associated to the current action.
 
double getCost ()
 Get the cost of the current action.
 
void setCost (double cost)
 Set the cost of the current action.
 
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.
 
virtual double getRemains ()
 Get the remaining time of the current action after updating the resource.
 
double getRemainsNoUpdate ()
 Get the remaining time of the current action without updating the resource.
 
void setFinishTime (double value)
 Set the finish time of the current action.
 
void ref ()
 Add a reference to the current action (refcounting)
 
virtual int unref ()
 Unref that action (and destroy it if refcount reaches 0) More...
 
virtual void cancel ()
 Cancel the current Action if running.
 
virtual void suspend ()
 Suspend the current Action.
 
virtual void resume ()
 Resume the current Action.
 
virtual bool isSuspended ()
 Returns true if the current action is running.
 
double getMaxDuration ()
 Get the maximum duration of the current action.
 
virtual void setMaxDuration (double duration)
 Set the maximum duration of the current Action.
 
char * getCategory ()
 Get the tracing category associated to the current action.
 
void setCategory (const char *category)
 Set the tracing category of the current Action.
 
double getPriority ()
 Get the priority of the current Action.
 
virtual void setPriority (double priority)
 Set the priority of the current Action.
 
ActionList * getStateSet ()
 Get the state set in which the action is.
 

Additional Inherited Members

- Protected Attributes inherited from Action
double m_priority
 
double m_remains
 
double m_finish
 

Detailed Description

SURF Cpu action interface class.

A CpuAction represent the execution of code on a Cpu

Constructor & Destructor Documentation

CpuAction::CpuAction ( Model model,
double  cost,
bool  failed 
)
inline

CpuAction constructor.

Parameters
modelThe CpuModel associated to this CpuAction
cost[TODO]
failed[TODO]
CpuAction::CpuAction ( Model model,
double  cost,
bool  failed,
lmm_variable_t  var 
)
inline

CpuAction constructor.

Parameters
modelThe CpuModel associated to this CpuAction
cost[TODO]
failed[TODO]
varThe lmm variable associated to this CpuAction if it is part of a LMM component

Member Function Documentation

void CpuAction::setAffinity ( Cpu cpu,
unsigned long  mask 
)
virtual

Set the affinity of the current CpuAction.

[TODO]

Parameters
cpu[TODO]
mask[TODO]

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