VTK
|
Scheduling execution with thread/computing resources distributing. More...
#include <vtkExecutionScheduler.h>
Public Types | |
typedef vtkObject | Superclass |
![]() | |
typedef vtkObjectBase | Superclass |
Public Member Functions | |
virtual const char * | GetClassName () |
virtual int | IsA (const char *type) |
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) |
vtkThreadMessager * | GetTaskDoneMessager (vtkExecutive *exec) |
vtkThreadMessager * | GetInputsReleasedMessager (vtkExecutive *exec) |
vtkMutexLock * | GetInputsReleasedLock (vtkExecutive *exec) |
void | ReleaseResources (vtkExecutive *exec) |
void | ReacquireResources (vtkExecutive *exec) |
void | RescheduleNetwork (vtkExecutive *sink) |
void | RescheduleFrom (vtkExecutive *sink, vtkComputingResources *resources) |
![]() | |
virtual void | DebugOn () |
virtual void | DebugOff () |
unsigned char | GetDebug () |
void | SetDebug (unsigned char debugFlag) |
virtual void | Modified () |
virtual unsigned long | GetMTime () |
unsigned long | AddObserver (unsigned long event, vtkCommand *, float priority=0.0f) |
unsigned long | AddObserver (const char *event, vtkCommand *, float priority=0.0f) |
vtkCommand * | GetCommand (unsigned long tag) |
void | RemoveObserver (vtkCommand *) |
void | RemoveObservers (unsigned long event, vtkCommand *) |
void | RemoveObservers (const char *event, vtkCommand *) |
int | HasObserver (unsigned long event, vtkCommand *) |
int | HasObserver (const char *event, vtkCommand *) |
void | RemoveObserver (unsigned long tag) |
void | RemoveObservers (unsigned long event) |
void | RemoveObservers (const char *event) |
void | RemoveAllObservers () |
int | HasObserver (unsigned long event) |
int | HasObserver (const char *event) |
template<class U , class T > | |
unsigned long | AddObserver (unsigned long event, U observer, void(T::*callback)(), float priority=0.0f) |
template<class U , class T > | |
unsigned long | AddObserver (unsigned long event, U observer, void(T::*callback)(vtkObject *, unsigned long, void *), float priority=0.0f) |
int | InvokeEvent (unsigned long event, void *callData) |
int | InvokeEvent (const char *event, void *callData) |
int | InvokeEvent (unsigned long event) |
int | InvokeEvent (const char *event) |
![]() | |
const char * | GetClassName () const |
virtual void | Delete () |
virtual void | FastDelete () |
void | Print (ostream &os) |
virtual void | Register (vtkObjectBase *o) |
virtual void | UnRegister (vtkObjectBase *o) |
void | SetReferenceCount (int) |
void | PrintRevisions (ostream &os) |
virtual void | PrintHeader (ostream &os, vtkIndent indent) |
virtual void | PrintTrailer (ostream &os, vtkIndent indent) |
int | GetReferenceCount () |
Static Public Member Functions | |
static vtkExecutionScheduler * | New () |
static int | IsTypeOf (const char *type) |
static vtkExecutionScheduler * | SafeDownCast (vtkObject *o) |
static vtkExecutionScheduler * | GetGlobalScheduler () |
static vtkInformationIntegerKey * | TASK_PRIORITY () |
![]() | |
static int | IsTypeOf (const char *type) |
static vtkObject * | SafeDownCast (vtkObject *o) |
static vtkObject * | New () |
static void | BreakOnError () |
static void | SetGlobalWarningDisplay (int val) |
static void | GlobalWarningDisplayOn () |
static void | GlobalWarningDisplayOff () |
static int | GetGlobalWarningDisplay () |
![]() | |
static int | IsTypeOf (const char *name) |
static vtkObjectBase * | New () |
Protected Member Functions | |
vtkExecutionScheduler () | |
~vtkExecutionScheduler () | |
![]() | |
vtkObject () | |
virtual | ~vtkObject () |
virtual void | RegisterInternal (vtkObjectBase *, int check) |
virtual void | UnRegisterInternal (vtkObjectBase *, int check) |
void | InternalGrabFocus (vtkCommand *mouseEvents, vtkCommand *keypressEvents=NULL) |
void | InternalReleaseFocus () |
![]() | |
vtkObjectBase () | |
virtual | ~vtkObjectBase () |
virtual void | CollectRevisions (ostream &os) |
virtual void | ReportReferences (vtkGarbageCollector *) |
vtkObjectBase (const vtkObjectBase &) | |
void | operator= (const vtkObjectBase &) |
Protected Attributes | |
vtkComputingResources * | Resources |
vtkThreadMessager * | ScheduleMessager |
vtkThreadMessager * | ResourceMessager |
vtkMutexLock * | ScheduleLock |
vtkMultiThreader * | ScheduleThreader |
int | ScheduleThreadId |
implementation *const | Implementation |
![]() | |
unsigned char | Debug |
vtkTimeStamp | MTime |
vtkSubjectHelper * | SubjectHelper |
![]() | |
int | ReferenceCount |
vtkWeakPointerBase ** | WeakPointers |
Friends | |
class | implementation |
void * | vtkExecutionScheduler_ScheduleThread (void *data) |
void * | vtkExecutionScheduler_ExecuteThread (void *data) |
class | vtkExecutionSchedulerManager |
static void | ClassInitialize () |
static void | ClassFinalize () |
Scheduling execution with thread/computing resources distributing.
This is a class for balancing the computing resources throughout the network
Definition at line 62 of file vtkExecutionScheduler.h.
Definition at line 66 of file vtkExecutionScheduler.h.
|
protected |
|
protected |
|
static |
|
virtual |
Reimplemented from vtkObject.
|
static |
|
virtual |
Return 1 if this class is the same type of (or a subclass of) the named class. Returns 0 otherwise. This method works in combination with vtkTypeMacro found in vtkSetGet.h.
Reimplemented from vtkObject.
|
static |
|
virtual |
|
static |
Return the global instance of the scheduler
|
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
|
staticprotected |
and clean up of the vtkExecutionScheduler singleton.
|
staticprotected |
and clean up of the vtkExecutionScheduler singleton.
|
friend |
Definition at line 145 of file vtkExecutionScheduler.h.
|
friend |
and clean up of the vtkExecutionScheduler singleton.
Definition at line 161 of file vtkExecutionScheduler.h.
|
friend |
The scheduling thread that is responsible for queueing up module execution in the right order
|
friend |
Execute thread function that is responsible for forking process for each module
|
protected |
Definition at line 135 of file vtkExecutionScheduler.h.
|
protected |
Definition at line 136 of file vtkExecutionScheduler.h.
|
protected |
Definition at line 137 of file vtkExecutionScheduler.h.
|
protected |
Definition at line 138 of file vtkExecutionScheduler.h.
|
protected |
Definition at line 139 of file vtkExecutionScheduler.h.
|
protected |
Definition at line 140 of file vtkExecutionScheduler.h.
|
protected |
Definition at line 143 of file vtkExecutionScheduler.h.