24 #ifndef ASYNC_TERMINATOR_HPP
25 #define ASYNC_TERMINATOR_HPP
27 #include <graphlab/parallel/pthread_tools.hpp>
29 #include <graphlab/rpc/dc.hpp>
30 #include <graphlab/rpc/dc_dist_object_base.hpp>
31 #include <graphlab/rpc/dc_dist_object.hpp>
106 const dc_impl::dc_dist_object_base* attach = NULL);
174 size_t total_calls_sent;
175 size_t total_calls_received;
178 oarc << total_calls_sent << total_calls_received << last_change;
181 void load(iarchive &iarc) {
182 iarc >> total_calls_sent >> total_calls_received >> last_change;
187 dc_dist_object<async_consensus> rmi;
188 const dc_impl::dc_dist_object_base* attachedobj;
190 size_t last_calls_sent;
191 size_t last_calls_received;
212 atomic<size_t> trying_to_sleep;
217 std::vector<char> critical;
220 std::vector<char> sleeping;
228 std::vector<conditional> cond;
231 void receive_the_token(token &tok);
232 void pass_the_token();