SMAUG
Simulating Machine Learning Applications on gem5-Aladdin
|
Scheduler is responsible for running the Network. More...
#include <scheduler.h>
Scheduler is responsible for running the Network.
Definition at line 12 of file scheduler.h.
Public Member Functions | |
Scheduler (Network *_network, Workspace *_workspace) | |
Tensor * | runNetwork () |
Runs the Network to completion. More... | |
Protected Member Functions | |
Tensor * | scheduleReady () |
Runs the operators in the ready queue. More... | |
void | maybeRunOperator (Operator *op) |
If none of the inputs to the current Operator are dead, then this will run the Operator; otherwise, otherwise, all of the Operator's outputs will be marked as dead tensors. More... | |
void | updateChildren (Operator *op) |
After an Operator is run, this updates the number of pending inputs on all its children. More... | |
Protected Attributes | |
Network * | network |
Workspace * | workspace |
std::list< Operator * > | readyQueue |
The queue of all Operators ready to be executed. | |
|
protected |
Tensor * smaug::Scheduler::runNetwork | ( | ) |
Runs the Network to completion.
The final output tensor is returned.
Definition at line 13 of file scheduler.cpp.
|
protected |
Runs the operators in the ready queue.
This may add new operators to the ready queue by calling updateChildren().
Definition at line 59 of file scheduler.cpp.
|
protected |
After an Operator is run, this updates the number of pending inputs on all its children.
Any child Operator with no more pending inputs is then added to the ready queue.
Definition at line 81 of file scheduler.cpp.