add more classes to snapshotting region
authorBrian Norris <banorris@uci.edu>
Thu, 24 May 2012 18:32:55 +0000 (11:32 -0700)
committerBrian Norris <banorris@uci.edu>
Fri, 25 May 2012 23:14:22 +0000 (16:14 -0700)
Classes that don't use MyAlloc or MEMALLOC are snapshotted by default.

model.cc
model.h
nodestack.h
schedule.h
threads.h

index 47b1b4d..28880dd 100644 (file)
--- 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<int, class Thread *, std::less< int >, MyAlloc< std::pair< int, class Thread * > > >::iterator it;
+       std::map<int, class Thread *>::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 (file)
--- a/model.h
+++ b/model.h
@@ -63,7 +63,7 @@ private:
 
        ucontext_t *system_context;
        action_list_t *action_trace;
-       std::map<int, class Thread *, std::less< int >, MyAlloc< std::pair< const int, class Thread * > > > thread_map;
+       std::map<int, class Thread *> thread_map;
        class NodeStack *node_stack;
        ModelAction *next_backtrack;
 };
index 3a0ee74..bd64c4a 100644 (file)
@@ -39,7 +39,7 @@ private:
        std::vector<bool> backtrack;
 };
 
-typedef std::list<class Node *> node_list_t;
+typedef std::list<class Node *, MyAlloc< class Node * > > node_list_t;
 
 class NodeStack {
 public:
index c99748c..f496536 100644 (file)
@@ -16,9 +16,9 @@ public:
        Thread * get_current_thread(void);
        void print();
 
-       MEMALLOC
+       SNAPSHOTALLOC
 private:
-       std::list<Thread *, MyAlloc< Thread * > > readyList;
+       std::list<Thread *> readyList;
        Thread *current;
 };
 
index ebe33a3..e52c324 100644 (file)
--- a/threads.h
+++ b/threads.h
@@ -33,7 +33,7 @@ public:
 
        friend void thread_startup();
 
-       MEMALLOC
+       SNAPSHOTALLOC
 private:
        int create_context();
        Thread *parent;