Public Types | Public Member Functions

graphlab::multiqueue_fifo_scheduler< Graph > Class Template Reference
[Schedulers]

#include <multiqueue_fifo_scheduler.hpp>

Inheritance diagram for graphlab::multiqueue_fifo_scheduler< Graph >:
graphlab::ischeduler< Graph >

List of all members.

Public Types

typedef Graph graph_type
typedef ischeduler< Graph > base
typedef base::iengine_type iengine_type
typedef base::update_task_type update_task_type
typedef base::update_function_type update_function_type
typedef base::callback_type callback_type
typedef base::monitor_type monitor_type
typedef std::queue
< update_task_type > 
taskqueue_t
typedef task_count_termination terminator_type

Public Member Functions

 multiqueue_fifo_scheduler (iengine_type *engine, Graph &g, size_t ncpus)
callback_typeget_callback (size_t cpuid)
void start ()
sched_status::status_enum get_next_task (size_t cpuid, update_task_type &ret_task)
void add_task (update_task_type task, double priority)
void add_tasks (const std::vector< vertex_id_t > &vertices, update_function_type func, double priority)
void add_task_to_all (update_function_type func, double priority)
void completed_task (size_t cpuid, const update_task_type &task)
bool is_task_scheduled (update_task_type task)
void print ()
terminator_typeget_terminator ()
void set_options (const scheduler_options &opts)
metrics get_metrics ()
void reset_metrics ()

Detailed Description

template<typename Graph>
class graphlab::multiqueue_fifo_scheduler< Graph >

This class defines a simple First-In-First_Out scheduler

Definition at line 52 of file multiqueue_fifo_scheduler.hpp.


Member Typedef Documentation

template<typename Graph >
typedef task_count_termination graphlab::multiqueue_fifo_scheduler< Graph >::terminator_type

Defines the preferred terminator algorithm

Reimplemented from graphlab::ischeduler< Graph >.

Definition at line 66 of file multiqueue_fifo_scheduler.hpp.


Member Function Documentation

template<typename Graph >
void graphlab::multiqueue_fifo_scheduler< Graph >::add_task ( update_task_type  task,
double  priority 
) [inline, virtual]

Adds an update task with a particular priority. This function may be called at anytime.

Implements graphlab::ischeduler< Graph >.

Definition at line 158 of file multiqueue_fifo_scheduler.hpp.

template<typename Graph >
void graphlab::multiqueue_fifo_scheduler< Graph >::add_task_to_all ( update_function_type  func,
double  priority 
) [inline, virtual]

Creates a collection of tasks on all the vertices in the graph, with the same update function and priority This function may be called at anytime.

Implements graphlab::ischeduler< Graph >.

Definition at line 209 of file multiqueue_fifo_scheduler.hpp.

template<typename Graph >
void graphlab::multiqueue_fifo_scheduler< Graph >::add_tasks ( const std::vector< vertex_id_t > &  vertices,
update_function_type  func,
double  priority 
) [inline, virtual]

Creates a collection of tasks on all the vertices in 'vertices', and all with the same update function and priority This function may be called at anytime.

Implements graphlab::ischeduler< Graph >.

Definition at line 200 of file multiqueue_fifo_scheduler.hpp.

template<typename Graph >
void graphlab::multiqueue_fifo_scheduler< Graph >::completed_task ( size_t  cpuid,
const update_task_type &  task 
) [inline, virtual]

This is called after a task has been executed

Implements graphlab::ischeduler< Graph >.

Definition at line 217 of file multiqueue_fifo_scheduler.hpp.

template<typename Graph >
callback_type& graphlab::multiqueue_fifo_scheduler< Graph >::get_callback ( size_t  cpuid  )  [inline, virtual]

This function returns a reference to the scheduling callback to be used for a particular cpu. This callback will be passed to update functions, and is the main interface which allow the update functions to create new tasks.

Implements graphlab::ischeduler< Graph >.

Definition at line 100 of file multiqueue_fifo_scheduler.hpp.

template<typename Graph >
metrics graphlab::multiqueue_fifo_scheduler< Graph >::get_metrics (  )  [inline, virtual]

Return the metrics information logged by the engine.

See also:
dump_metrics reset_metrics

Reimplemented from graphlab::ischeduler< Graph >.

Definition at line 243 of file multiqueue_fifo_scheduler.hpp.

template<typename Graph >
sched_status::status_enum graphlab::multiqueue_fifo_scheduler< Graph >::get_next_task ( size_t  cpuid,
update_task_type &  ret_task 
) [inline, virtual]

Get the next element in the queue

Implements graphlab::ischeduler< Graph >.

Definition at line 107 of file multiqueue_fifo_scheduler.hpp.

template<typename Graph >
terminator_type& graphlab::multiqueue_fifo_scheduler< Graph >::get_terminator (  )  [inline]

Returns a reference to the terminator

Reimplemented from graphlab::ischeduler< Graph >.

Definition at line 237 of file multiqueue_fifo_scheduler.hpp.

template<typename Graph >
void graphlab::multiqueue_fifo_scheduler< Graph >::reset_metrics (  )  [inline, virtual]

Clears all logged metrics

See also:
dump_metrics get_metrics

Reimplemented from graphlab::ischeduler< Graph >.

Definition at line 248 of file multiqueue_fifo_scheduler.hpp.

template<typename Graph >
void graphlab::multiqueue_fifo_scheduler< Graph >::start (  )  [inline, virtual]

Called by engine before starting the schedule. This function will only be called once throughout the lifetime of the scheduler.

Implements graphlab::ischeduler< Graph >.

Definition at line 104 of file multiqueue_fifo_scheduler.hpp.


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