VTK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Types | Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes | Friends | List of all members
vtkExecutionScheduler Class Reference

Scheduling execution with thread/computing resources distributing. More...

#include <vtkExecutionScheduler.h>

Inherits vtkObject.

Collaboration diagram for vtkExecutionScheduler:
[legend]

Public Types

typedef vtkObject Superclass
 

Public Member Functions

virtual int IsA (const char *type)
 
vtkExecutionSchedulerNewInstance () const
 
void PrintSelf (ostream &os, vtkIndent indent)
 
void Schedule (vtkExecutiveCollection *execs, vtkInformation *info)
 
void SchedulePropagate (vtkExecutiveCollection *execs, vtkInformation *info)
 
void WaitUntilDone (vtkExecutiveCollection *execs)
 
void WaitUntilReleased (vtkExecutiveCollection *execs)
 
void WaitUntilAllDone ()
 
void WaitForTaskDone (vtkExecutive *exec)
 
void WaitForInputsReleased (vtkExecutive *exec)
 
vtkThreadMessagerGetTaskDoneMessager (vtkExecutive *exec)
 
vtkThreadMessagerGetInputsReleasedMessager (vtkExecutive *exec)
 
vtkMutexLock * GetInputsReleasedLock (vtkExecutive *exec)
 
void ReleaseResources (vtkExecutive *exec)
 
void ReacquireResources (vtkExecutive *exec)
 
void RescheduleNetwork (vtkExecutive *sink)
 
void RescheduleFrom (vtkExecutive *sink, vtkComputingResources *resources)
 

Static Public Member Functions

static vtkExecutionSchedulerNew ()
 
static int IsTypeOf (const char *type)
 
static vtkExecutionSchedulerSafeDownCast (vtkObjectBase *o)
 
static vtkExecutionSchedulerGetGlobalScheduler ()
 
static vtkInformationIntegerKey * TASK_PRIORITY ()
 

Protected Member Functions

virtual vtkObjectBase * NewInstanceInternal () const
 
 vtkExecutionScheduler ()
 
 ~vtkExecutionScheduler ()
 

Protected Attributes

vtkComputingResourcesResources
 
vtkThreadMessagerScheduleMessager
 
vtkThreadMessagerResourceMessager
 
vtkMutexLock * ScheduleLock
 
vtkMultiThreader * ScheduleThreader
 
int ScheduleThreadId
 
implementation *const Implementation
 

Friends

class implementation
 
void * vtkExecutionScheduler_ScheduleThread (void *data)
 
void * vtkExecutionScheduler_ExecuteThread (void *data)
 
class vtkExecutionSchedulerManager
 
static void ClassInitialize ()
 
static void ClassFinalize ()
 

Detailed Description

Scheduling execution with thread/computing resources distributing.

This is a class for balancing the computing resources throughout the network

See Also
vtkComputingResources vtkThreadedStreamingPipeline
Events:
vtkCommand::UpdateEvent

Definition at line 60 of file vtkExecutionScheduler.h.

Member Typedef Documentation

Definition at line 64 of file vtkExecutionScheduler.h.

Constructor & Destructor Documentation

vtkExecutionScheduler::vtkExecutionScheduler ( )
protected
vtkExecutionScheduler::~vtkExecutionScheduler ( )
protected

Member Function Documentation

static vtkExecutionScheduler* vtkExecutionScheduler::New ( )
static
static int vtkExecutionScheduler::IsTypeOf ( const char *  type)
static
virtual int vtkExecutionScheduler::IsA ( const char *  type)
virtual
static vtkExecutionScheduler* vtkExecutionScheduler::SafeDownCast ( vtkObjectBase *  o)
static
virtual vtkObjectBase* vtkExecutionScheduler::NewInstanceInternal ( ) const
protectedvirtual
vtkExecutionScheduler* vtkExecutionScheduler::NewInstance ( ) const
void vtkExecutionScheduler::PrintSelf ( ostream &  os,
vtkIndent  indent 
)
static vtkExecutionScheduler* vtkExecutionScheduler::GetGlobalScheduler ( )
static

Return the global instance of the scheduler

static vtkInformationIntegerKey* vtkExecutionScheduler::TASK_PRIORITY ( )
static

Key to store the priority of a task

void vtkExecutionScheduler::Schedule ( vtkExecutiveCollection execs,
vtkInformation *  info 
)

Put the current set of executives (modules) to the be scheduled given its dependency graph which will be used to compute the set topological orders

void vtkExecutionScheduler::SchedulePropagate ( vtkExecutiveCollection execs,
vtkInformation *  info 
)

Put the current set of executives (modules) to the be scheduled given its dependency graph which will be used to compute the set topological orders. Then wait for their execution to be complete

void vtkExecutionScheduler::WaitUntilDone ( vtkExecutiveCollection execs)

Wait until the current set of executives (modules) have finished executing

void vtkExecutionScheduler::WaitUntilReleased ( vtkExecutiveCollection execs)

Wait until the current set of executives (modules) have their inputs released

void vtkExecutionScheduler::WaitUntilAllDone ( )

Wait for all tasks to be done

void vtkExecutionScheduler::WaitForTaskDone ( vtkExecutive exec)

Wait for a task that is on the scheduling queue to be done. If the task is not there, this will return immediately. If the exec is NULL, any task that is done will trigger this the return

void vtkExecutionScheduler::WaitForInputsReleased ( vtkExecutive exec)

Similar to WaitForTaskDone but return whenever input connections of a task are released instead of done computing. But exec cannot be NULL.

vtkThreadMessager* vtkExecutionScheduler::GetTaskDoneMessager ( vtkExecutive exec)

Return the thread messager reserved for the given exec to notify when it is done

vtkThreadMessager* vtkExecutionScheduler::GetInputsReleasedMessager ( vtkExecutive exec)

Return the thread messager reserved for the given exec to notify when it releases its inputs

vtkMutexLock* vtkExecutionScheduler::GetInputsReleasedLock ( vtkExecutive exec)

Return the mutex lock reserved for the given exec to notify when it releases its inputs

void vtkExecutionScheduler::ReleaseResources ( vtkExecutive exec)

Release the resources that are being used by the given exec

void vtkExecutionScheduler::ReacquireResources ( vtkExecutive exec)

Re-acquire the resource released earlier by ReleaseResource

void vtkExecutionScheduler::RescheduleNetwork ( vtkExecutive sink)

Redistribute the thread resources over the network from a sink with a maximum resource

void vtkExecutionScheduler::RescheduleFrom ( vtkExecutive sink,
vtkComputingResources resources 
)

Redistribute the thread resources from a sink given a certain amount of resource

static void vtkExecutionScheduler::ClassInitialize ( )
staticprotected

and clean up of the vtkExecutionScheduler singleton.

static void vtkExecutionScheduler::ClassFinalize ( )
staticprotected

and clean up of the vtkExecutionScheduler singleton.

Friends And Related Function Documentation

friend class implementation
friend

Definition at line 143 of file vtkExecutionScheduler.h.

friend class vtkExecutionSchedulerManager
friend

and clean up of the vtkExecutionScheduler singleton.

Definition at line 159 of file vtkExecutionScheduler.h.

void* vtkExecutionScheduler_ScheduleThread ( void *  data)
friend

The scheduling thread that is responsible for queueing up module execution in the right order

void* vtkExecutionScheduler_ExecuteThread ( void *  data)
friend

Execute thread function that is responsible for forking process for each module

Member Data Documentation

vtkComputingResources* vtkExecutionScheduler::Resources
protected

Definition at line 133 of file vtkExecutionScheduler.h.

vtkThreadMessager* vtkExecutionScheduler::ScheduleMessager
protected

Definition at line 134 of file vtkExecutionScheduler.h.

vtkThreadMessager* vtkExecutionScheduler::ResourceMessager
protected

Definition at line 135 of file vtkExecutionScheduler.h.

vtkMutexLock* vtkExecutionScheduler::ScheduleLock
protected

Definition at line 136 of file vtkExecutionScheduler.h.

vtkMultiThreader* vtkExecutionScheduler::ScheduleThreader
protected

Definition at line 137 of file vtkExecutionScheduler.h.

int vtkExecutionScheduler::ScheduleThreadId
protected

Definition at line 138 of file vtkExecutionScheduler.h.

implementation* const vtkExecutionScheduler::Implementation
protected

Definition at line 141 of file vtkExecutionScheduler.h.


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