diff options
author | Simon J. Gerraty <sjg@FreeBSD.org> | 2014-11-19 01:07:58 +0000 |
---|---|---|
committer | Simon J. Gerraty <sjg@FreeBSD.org> | 2014-11-19 01:07:58 +0000 |
commit | 9268022b74279434ed6300244e3f977e56a8ceb5 (patch) | |
tree | 377ac0ac449528621eb192cd245adadb5fd53668 /lib/libstdthreads | |
parent | 29c34e9d2781cf25403647fb5af7d7ddb23be7e1 (diff) | |
parent | 8c3d6a4ab2a4a95d864d9a32d0157d7de90498a4 (diff) | |
download | src-test-9268022b74279434ed6300244e3f977e56a8ceb5.tar.gz src-test-9268022b74279434ed6300244e3f977e56a8ceb5.zip |
Merge from head@274682
Notes
Notes:
svn path=/projects/bmake/; revision=274683
Diffstat (limited to 'lib/libstdthreads')
-rw-r--r-- | lib/libstdthreads/threads.h | 27 |
1 files changed, 18 insertions, 9 deletions
diff --git a/lib/libstdthreads/threads.h b/lib/libstdthreads/threads.h index aba9ca13df3cc..6f322a5af13e0 100644 --- a/lib/libstdthreads/threads.h +++ b/lib/libstdthreads/threads.h @@ -79,15 +79,24 @@ int cnd_broadcast(cnd_t *); void cnd_destroy(cnd_t *); int cnd_init(cnd_t *); int cnd_signal(cnd_t *); -int cnd_timedwait(cnd_t *__restrict, mtx_t *__restrict, - const struct timespec *__restrict); -int cnd_wait(cnd_t *, mtx_t *); -void mtx_destroy(mtx_t *); -int mtx_init(mtx_t *, int); -int mtx_lock(mtx_t *); -int mtx_timedlock(mtx_t *__restrict, const struct timespec *__restrict); -int mtx_trylock(mtx_t *); -int mtx_unlock(mtx_t *); +int cnd_timedwait(cnd_t *__restrict, mtx_t *__restrict __mtx, + const struct timespec *__restrict) + __requires_exclusive(*__mtx); +int cnd_wait(cnd_t *, mtx_t *__mtx) + __requires_exclusive(*__mtx); +void mtx_destroy(mtx_t *__mtx) + __requires_unlocked(*__mtx); +int mtx_init(mtx_t *__mtx, int) + __requires_unlocked(*__mtx); +int mtx_lock(mtx_t *__mtx) + __locks_exclusive(*__mtx); +int mtx_timedlock(mtx_t *__restrict __mtx, + const struct timespec *__restrict) + __trylocks_exclusive(thrd_success, *__mtx); +int mtx_trylock(mtx_t *__mtx) + __trylocks_exclusive(thrd_success, *__mtx); +int mtx_unlock(mtx_t *__mtx) + __unlocks(*__mtx); int thrd_create(thrd_t *, thrd_start_t, void *); thrd_t thrd_current(void); int thrd_detach(thrd_t); |