3 WaitObj::WaitObj(thread_id_t tid) :
10 int WaitObj::lookup_dist(thread_id_t other_id)
12 if (dist_table.contains(other_id))
13 return dist_table.get(other_id);
18 void WaitObj::print_waiting_for()
20 if (waiting_for.getSize() == 0)
23 model_print("thread %d is waiting for: ", tid);
24 thrd_id_set_iter * it = waiting_for.iterator();
26 while (it->hasNext()) {
27 thread_id_t thread_id = it->next();
28 model_print("%d ", thread_id);
33 void WaitObj::print_waited_by()
35 if (waited_by.getSize() == 0)
38 model_print("thread %d is waited by: ", tid);
39 thrd_id_set_iter * it = waited_by.iterator();
41 while (it->hasNext()) {
42 thread_id_t thread_id = it->next();
43 model_print("%d ", thread_id);