Searched refs:rwlock (Results 1 - 2 of 2) sorted by relevance

/system/core/include/utils/
H A DRWLock.h62 inline AutoRLock(RWLock& rwlock) : mLock(rwlock) { mLock.readLock(); } argument
70 inline AutoWLock(RWLock& rwlock) : mLock(rwlock) { mLock.writeLock(); } argument
/system/extras/tests/bionic/libc/common/
H A Dtest_pthread_rwlock.c109 /* perform a simple init/lock/unlock/destroy test on a rwlock of given attributes */
141 /* simple init/lock/unlock/destroy on all rwlock types */
231 * - main thread creates a rwlock and rdlocks it
235 * then unlock the rwlock.
237 * - thread 1 tryrdlocks() the rwlock. It shall acquire the lock
240 * - thread 2 trywrlocks() the rwlock. In case of failure (EBUSY), it waits
242 * it succeeds. It then unlocks the rwlock.
247 * to which thread is going to acquire the rwlock first.
250 pthread_rwlock_t rwlock[1]; member in struct:__anon278
262 TZERO(pthread_rwlock_tryrdlock(s->rwlock));
[all...]

Completed in 6625 milliseconds