GraphLab: Distributed Graph-Parallel API  2.1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
scheduler_list.hpp
1 /**
2  * Copyright (c) 2009 Carnegie Mellon University.
3  * All rights reserved.
4  *
5  * Licensed under the Apache License, Version 2.0 (the "License");
6  * you may not use this file except in compliance with the License.
7  * You may obtain a copy of the License at
8  *
9  * http://www.apache.org/licenses/LICENSE-2.0
10  *
11  * Unless required by applicable law or agreed to in writing,
12  * software distributed under the License is distributed on an "AS
13  * IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
14  * express or implied. See the License for the specific language
15  * governing permissions and limitations under the License.
16  *
17  * For more about this software visit:
18  *
19  * http://www.graphlab.ml.cmu.edu
20  *
21  */
22 
23 
24 #ifndef GRAPHLAB_SCHEDULER_LIST_HPP
25 #define GRAPHLAB_SCHEDULER_LIST_HPP
26 #include <string>
27 #include <vector>
28 #include <iostream>
29 #include <boost/preprocessor.hpp>
30 
31 #define __SCHEDULER_LIST__ \
32  (("fifo", fifo_scheduler, \
33  "Standard FIFO task queue, poor parallelism, but task evaluation " \
34  "sequence is highly predictable. " \
35  "Useful for debugging and testing.")) \
36  (("sweep", sweep_scheduler, \
37  "very fast dynamic scheduler. Scans all vertices in sequence, " \
38  "running all update tasks on each vertex evaluated.")) \
39  (("priority", priority_scheduler, \
40  "Standard Priority queue, poor parallelism, but task evaluation " \
41  "sequence is highly predictable. Useful for debugging")) \
42  (("queued_fifo", queued_fifo_scheduler, \
43  "This scheduler maintains a shared FIFO queue of FIFO queues. " \
44  "Each thread maintains its own smaller in and out queues. When a " \
45  "threads out queue is too large (greater than \"queuesize\") then " \
46  "the thread puts its out queue at the end of the master queue."))
47 
48 #include <graphlab/scheduler/fifo_scheduler.hpp>
49 #include <graphlab/scheduler/sweep_scheduler.hpp>
50 #include <graphlab/scheduler/priority_scheduler.hpp>
51 #include <graphlab/scheduler/queued_fifo_scheduler.hpp>
52 
53 
54 namespace graphlab {
55  /// get all the scheduler names
56  std::vector<std::string> get_scheduler_names();
57 
58  /// get all the scheduler names concated into a string
59  std::string get_scheduler_names_str();
60 
61  /// Display the scheduler options for a particular scheduler
62  void print_scheduler_info(std::string s, std::ostream &out);
63 }
64 
65 #endif
66