ModelChecker(struct model_params params);
~ModelChecker();
- /** Stores the context for the main model-checking system thread (call
- * once)
- * @param ctxt The system context structure
- */
- void set_system_context(ucontext_t *ctxt) { system_context = ctxt; }
-
/** @returns the context for the main model-checking system thread */
- ucontext_t * get_system_context(void) { return system_context; }
-
- void check_current_action(void);
+ ucontext_t * get_system_context() { return &system_context; }
/** Prints an execution summary with trace information. */
void print_summary();
Thread * schedule_next_thread();
- int add_thread(Thread *t);
+ void add_thread(Thread *t);
void remove_thread(Thread *t);
Thread * get_thread(thread_id_t tid) { return thread_map->get(id_to_int(tid)); }
* @param act The ModelAction created by the user-thread action
*/
void set_current_action(ModelAction *act) { current_action = act; }
+ void check_current_action();
bool take_step();
ModelAction *diverge;
thread_id_t nextThread;
- ucontext_t *system_context;
+ ucontext_t system_context;
action_list_t *action_trace;
HashTable<int, Thread *, int> *thread_map;