From: Brian Norris Date: Thu, 24 May 2012 18:32:55 +0000 (-0700) Subject: add more classes to snapshotting region X-Git-Tag: pldi2013~392^2~43 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=9fd8ac15f03e8ca01a20563e06c44b8b93090892;p=model-checker.git add more classes to snapshotting region Classes that don't use MyAlloc or MEMALLOC are snapshotted by default. --- diff --git a/model.cc b/model.cc index 47b1b4d..28880dd 100644 --- a/model.cc +++ b/model.cc @@ -45,7 +45,7 @@ ModelChecker::~ModelChecker() void ModelChecker::reset_to_initial_state() { DEBUG("+++ Resetting to initial state +++\n"); - std::map, MyAlloc< std::pair< int, class Thread * > > >::iterator it; + std::map::iterator it; for (it = thread_map.begin(); it != thread_map.end(); it++) delete (*it).second; thread_map.clear(); diff --git a/model.h b/model.h index 99ec69e..9d2fd5a 100644 --- a/model.h +++ b/model.h @@ -63,7 +63,7 @@ private: ucontext_t *system_context; action_list_t *action_trace; - std::map, MyAlloc< std::pair< const int, class Thread * > > > thread_map; + std::map thread_map; class NodeStack *node_stack; ModelAction *next_backtrack; }; diff --git a/nodestack.h b/nodestack.h index 3a0ee74..bd64c4a 100644 --- a/nodestack.h +++ b/nodestack.h @@ -39,7 +39,7 @@ private: std::vector backtrack; }; -typedef std::list node_list_t; +typedef std::list > node_list_t; class NodeStack { public: diff --git a/schedule.h b/schedule.h index c99748c..f496536 100644 --- a/schedule.h +++ b/schedule.h @@ -16,9 +16,9 @@ public: Thread * get_current_thread(void); void print(); - MEMALLOC + SNAPSHOTALLOC private: - std::list > readyList; + std::list readyList; Thread *current; }; diff --git a/threads.h b/threads.h index ebe33a3..e52c324 100644 --- a/threads.h +++ b/threads.h @@ -33,7 +33,7 @@ public: friend void thread_startup(); - MEMALLOC + SNAPSHOTALLOC private: int create_context(); Thread *parent;