projects
/
model-checker.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
8fecd5d
)
thread: remove dead Thread code
author
Brian Norris
<banorris@uci.edu>
Fri, 27 Apr 2012 06:36:26 +0000
(23:36 -0700)
committer
Brian Norris
<banorris@uci.edu>
Fri, 27 Apr 2012 06:36:26 +0000
(23:36 -0700)
threads.cc
patch
|
blob
|
history
threads.h
patch
|
blob
|
history
diff --git
a/threads.cc
b/threads.cc
index dc7202e3aaa08e4e9dc00d8d6a40e6c04834180e..d799144f67e1df86dcaacaa217da2f3f799b5cdd 100644
(file)
--- a/
threads.cc
+++ b/
threads.cc
@@
-33,10
+33,6
@@
int Thread::create_context()
if (ret)
return ret;
if (ret)
return ret;
- /* start_routine == NULL means this is our initial context */
- if (!start_routine)
- return 0;
-
/* Initialize new managed context */
stack = stack_allocate(STACK_SIZE);
context.uc_stack.ss_sp = stack;
/* Initialize new managed context */
stack = stack_allocate(STACK_SIZE);
context.uc_stack.ss_sp = stack;
@@
-93,20
+89,6
@@
Thread::Thread(thrd_t *t, void (*func)(), void *a) {
*user_thread = id;
}
*user_thread = id;
}
-Thread::Thread(thrd_t *t) {
- /* system thread */
- user_thread = t;
- start_routine = NULL;
- arg = NULL;
-
- create_context();
- stack = NULL;
- state = THREAD_CREATED;
- id = model->get_next_id();
- *user_thread = id;
- model->set_system_context(&context);
-}
-
Thread::~Thread()
{
complete();
Thread::~Thread()
{
complete();
diff --git
a/threads.h
b/threads.h
index 490081afe882c41b0bfec641740f43c4e99d90ed..69bd115c4a88243657ce8f92088962f97249dccb 100644
(file)
--- a/
threads.h
+++ b/
threads.h
@@
-19,7
+19,6
@@
public:
void * operator new(size_t size);
void operator delete(void *ptr);
Thread(thrd_t *t, void (*func)(), void *a);
void * operator new(size_t size);
void operator delete(void *ptr);
Thread(thrd_t *t, void (*func)(), void *a);
- Thread(thrd_t *t);
~Thread();
void complete();
~Thread();
void complete();