1 #ifndef __THREADS_INTERNAL_H__
2 #define __THREADS_INTERNAL_H__
6 #include "libthreads.h"
8 typedef enum thread_state {
19 Thread(thrd_t *t, void (*func)(), void *a);
23 int switch_to_master(ModelAction *act);
25 thread_state get_state() { return state; }
26 void set_state(thread_state s) { state = s; }
28 void set_id(thread_id_t i) { *user_thread = i; }
29 thrd_t get_thrd_t() { return *user_thread; }
33 void (*start_routine)();
41 Thread *thread_current();
43 static inline thread_id_t thrd_to_id(thrd_t t)
48 #endif /* __THREADS_INTERNAL_H__ */