diff options
author | rsc <devnull@localhost> | 2006-06-04 16:07:25 +0000 |
---|---|---|
committer | rsc <devnull@localhost> | 2006-06-04 16:07:25 +0000 |
commit | 26eba9db1a39acdc2cfaac7914fad2bda9f06f5a (patch) | |
tree | 24c31985574f67cb48affd29ab6ff1bc08432af1 /src/libthread | |
parent | 17558fbe2d50f3ca908edae3b1836c71b5d9fe00 (diff) | |
download | plan9port-26eba9db1a39acdc2cfaac7914fad2bda9f06f5a.tar.gz plan9port-26eba9db1a39acdc2cfaac7914fad2bda9f06f5a.tar.bz2 plan9port-26eba9db1a39acdc2cfaac7914fad2bda9f06f5a.zip |
sparc
Diffstat (limited to 'src/libthread')
-rw-r--r-- | src/libthread/sparc-ucontext.h | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/src/libthread/sparc-ucontext.h b/src/libthread/sparc-ucontext.h new file mode 100644 index 00000000..0031d2a4 --- /dev/null +++ b/src/libthread/sparc-ucontext.h @@ -0,0 +1,24 @@ +#define setcontext(u) _setmcontext(&(u)->mc) +#define getcontext(u) _getmcontext(&(u)->mc) +typedef struct mcontext mcontext_t; +typedef struct ucontext ucontext_t; +struct mcontext +{ + int r[16]; +}; + +struct ucontext +{ + struct { + void *ss_sp; + uint ss_size; + } uc_stack; + sigset_t uc_sigmask; + mcontext_t mc; +}; + +void makecontext(ucontext_t*, void(*)(void), int, ...); +int swapcontext(ucontext_t*, ucontext_t*); +int _getmcontext(mcontext_t*); +void _setmcontext(mcontext_t*); + |