Pthread cleanup stubs
authorBarret Rhoden <brho@cs.berkeley.edu>
Mon, 4 May 2015 16:21:48 +0000 (12:21 -0400)
committerBarret Rhoden <brho@cs.berkeley.edu>
Wed, 6 May 2015 21:14:32 +0000 (17:14 -0400)
commit051ee717201edc5cb37dfe653145ef37c5efc80e
tree8fab12056fbe3186f25e9ee02c3040892b8185cf
parentf2bef82bcd7e6e11e3fed7c3e2ef6b17d90731cb
Pthread cleanup stubs

These cleanup stubs are similar to our waserror/poperror.  They interact
with pthread_cancel and exit.  If a thread exits or is cancelled, it's
cleanup functions are called.  Additionally, cleanup_pop takes a bool,
and when it's TRUE, it'll run the handler even when returning normally.

If someone wants to implement these and pthread_cancel, be my guest.
user/pthread/pthread.c
user/pthread/pthread.h