/bionic/libc/bionic/ |
pthread-rwlocks.c | 112 int pthread_rwlock_init(pthread_rwlock_t *rwlock, const pthread_rwlockattr_t *attr) 120 if (rwlock == NULL) 133 ret = pthread_mutex_init(&rwlock->lock, lock_attr); 137 ret = pthread_cond_init(&rwlock->cond, cond_attr); 139 pthread_mutex_destroy(&rwlock->lock); 143 rwlock->numLocks = 0; 144 rwlock->pendingReaders = 0; 145 rwlock->pendingWriters = 0; 146 rwlock->writerThreadId = 0; 151 int pthread_rwlock_destroy(pthread_rwlock_t *rwlock) [all...] |
/external/llvm/lib/Support/ |
RWMutex.cpp | 52 // pthread_rwlock_init does have an address, then rwlock support is enabled. 66 pthread_rwlock_t* rwlock = 71 bzero(rwlock, sizeof(pthread_rwlock_t)); 74 // Initialize the rwlock 75 int errorcode = pthread_rwlock_init(rwlock, NULL); 80 data_ = rwlock; 89 pthread_rwlock_t* rwlock = static_cast<pthread_rwlock_t*>(data_); 90 assert(rwlock != 0); 91 pthread_rwlock_destroy(rwlock); 92 free(rwlock); [all...] |
/external/valgrind/main/drd/tests/ |
trylock.c | 23 pthread_rwlock_t rwlock; local 30 r = pthread_rwlock_init(&rwlock, NULL); assert(r == 0); 31 fprintf(stderr, "Locking rwlock via pthread_rwlock_wrlock().\n"); 32 r = pthread_rwlock_wrlock(&rwlock); assert(r == 0); 33 r = pthread_rwlock_unlock(&rwlock); assert(r == 0); 34 fprintf(stderr, "Locking rwlock via pthread_rwlock_trywrlock().\n"); 35 r = pthread_rwlock_trywrlock(&rwlock); assert(r == 0); 36 r = pthread_rwlock_unlock(&rwlock); assert(r == 0); 37 fprintf(stderr, "Locking rwlock via pthread_rwlock_timedwrlock().\n"); 39 r = pthread_rwlock_timedwrlock(&rwlock, &abs_timeout); assert(r == 0) [all...] |
hold_lock.c | 30 pthread_rwlock_t rwlock; local 58 fprintf(stderr, "Locking rwlock exclusively ...\n"); 60 pthread_rwlock_init(&rwlock, 0); 61 pthread_rwlock_wrlock(&rwlock); 63 pthread_rwlock_unlock(&rwlock); 64 pthread_rwlock_destroy(&rwlock); 66 fprintf(stderr, "Locking rwlock shared ...\n"); 68 pthread_rwlock_init(&rwlock, 0); 69 pthread_rwlock_rdlock(&rwlock); 71 pthread_rwlock_rdlock(&rwlock); [all...] |
trylock.stderr.exp | 2 Locking rwlock via pthread_rwlock_wrlock(). 3 Locking rwlock via pthread_rwlock_trywrlock(). 4 Locking rwlock via pthread_rwlock_timedwrlock(). 5 Locking rwlock via pthread_rwlock_rdlock(). 6 Locking rwlock via pthread_rwlock_tryrdlock(). 7 Locking rwlock via pthread_rwlock_timedrdlock(). 9 Recursive writer locking not allowed: rwlock 0x......... 12 rwlock 0x........ was first observed at:
|
rwlock_type_checking.stderr.exp | 2 Attempt to use a user-defined rwlock as a POSIX rwlock: rwlock 0x......... 5 rwlock 0x........ was first observed at: 8 Attempt to use a POSIX rwlock as a user-defined rwlock: rwlock 0x......... 10 rwlock 0x........ was first observed at:
|
hold_lock_2.stderr.exp | 3 Locking rwlock exclusively ... 4 Locking rwlock shared ... 8 Lock on rwlock 0x........ was held during ... ms (threshold: 500 ms). 11 rwlock 0x........ was first observed at:
|
tc12_rwl_trivial.stderr.exp | 2 Reader-writer lock not locked by calling thread: rwlock 0x......... 5 rwlock 0x........ was first observed at:
|
/external/valgrind/main/drd/ |
drd_rwlock.h | 44 struct rwlock_info* DRD_(rwlock_pre_init)(const Addr rwlock, 46 void DRD_(rwlock_post_destroy)(const Addr rwlock, const RwLockT rwlock_type); 47 void DRD_(rwlock_pre_rdlock)(const Addr rwlock, const RwLockT rwlock_type); 48 void DRD_(rwlock_post_rdlock)(const Addr rwlock, const RwLockT rwlock_type, 50 void DRD_(rwlock_pre_wrlock)(const Addr rwlock, const RwLockT rwlock_type); 51 void DRD_(rwlock_post_wrlock)(const Addr rwlock, const RwLockT rwlock_type, 53 void DRD_(rwlock_pre_unlock)(const Addr rwlock, const RwLockT rwlock_type);
|
drd.h | 180 #define ANNOTATE_RWLOCK_CREATE(rwlock) \ 183 rwlock, 0, 0, 0, 0); 186 #define ANNOTATE_RWLOCK_DESTROY(rwlock) \ 189 rwlock, 0, 0, 0, 0); 196 #define ANNOTATE_RWLOCK_ACQUIRED(rwlock, is_w) \ 199 rwlock, is_w, 0, 0, 0) 205 #define ANNOTATE_READERLOCK_ACQUIRED(rwlock) ANNOTATE_RWLOCK_ACQUIRED(rwlock, 0) 211 #define ANNOTATE_WRITERLOCK_ACQUIRED(rwlock) ANNOTATE_RWLOCK_ACQUIRED(rwlock, 1 [all...] |
drd_rwlock.c | 198 * Compare the type of the rwlock specified at initialization time with 206 /* The code below has to be updated if additional rwlock types are added. */ 220 ? "Attempt to use a user-defined rwlock as a POSIX rwlock" 221 : "Attempt to use a POSIX rwlock as a user-defined rwlock", 229 void DRD_(rwlock_initialize)(struct rwlock_info* const p, const Addr rwlock, 232 tl_assert(rwlock != 0); 233 tl_assert(p->a1 == rwlock); 241 0, 0, VG_(malloc), "drd.rwlock.ri.1", VG_(free)) [all...] |
/bionic/libc/kernel/common/linux/ |
spinlock.h | 50 #define _raw_read_lock(rwlock) __raw_read_lock(&(rwlock)->raw_lock) 51 #define _raw_read_trylock(rwlock) __raw_read_trylock(&(rwlock)->raw_lock) 52 #define _raw_read_unlock(rwlock) __raw_read_unlock(&(rwlock)->raw_lock) 53 #define _raw_write_lock(rwlock) __raw_write_lock(&(rwlock)->raw_lock) 54 #define _raw_write_trylock(rwlock) __raw_write_trylock(&(rwlock)->raw_lock [all...] |
/development/ndk/platforms/android-3/include/linux/ |
spinlock.h | 50 #define _raw_read_lock(rwlock) __raw_read_lock(&(rwlock)->raw_lock) 51 #define _raw_read_trylock(rwlock) __raw_read_trylock(&(rwlock)->raw_lock) 52 #define _raw_read_unlock(rwlock) __raw_read_unlock(&(rwlock)->raw_lock) 53 #define _raw_write_lock(rwlock) __raw_write_lock(&(rwlock)->raw_lock) 54 #define _raw_write_trylock(rwlock) __raw_write_trylock(&(rwlock)->raw_lock [all...] |
/prebuilt/ndk/android-ndk-r4/platforms/android-3/arch-arm/usr/include/linux/ |
spinlock.h | 50 #define _raw_read_lock(rwlock) __raw_read_lock(&(rwlock)->raw_lock) 51 #define _raw_read_trylock(rwlock) __raw_read_trylock(&(rwlock)->raw_lock) 52 #define _raw_read_unlock(rwlock) __raw_read_unlock(&(rwlock)->raw_lock) 53 #define _raw_write_lock(rwlock) __raw_write_lock(&(rwlock)->raw_lock) 54 #define _raw_write_trylock(rwlock) __raw_write_trylock(&(rwlock)->raw_lock [all...] |
/prebuilt/ndk/android-ndk-r4/platforms/android-4/arch-arm/usr/include/linux/ |
spinlock.h | 50 #define _raw_read_lock(rwlock) __raw_read_lock(&(rwlock)->raw_lock) 51 #define _raw_read_trylock(rwlock) __raw_read_trylock(&(rwlock)->raw_lock) 52 #define _raw_read_unlock(rwlock) __raw_read_unlock(&(rwlock)->raw_lock) 53 #define _raw_write_lock(rwlock) __raw_write_lock(&(rwlock)->raw_lock) 54 #define _raw_write_trylock(rwlock) __raw_write_trylock(&(rwlock)->raw_lock [all...] |
/prebuilt/ndk/android-ndk-r4/platforms/android-5/arch-arm/usr/include/linux/ |
spinlock.h | 50 #define _raw_read_lock(rwlock) __raw_read_lock(&(rwlock)->raw_lock) 51 #define _raw_read_trylock(rwlock) __raw_read_trylock(&(rwlock)->raw_lock) 52 #define _raw_read_unlock(rwlock) __raw_read_unlock(&(rwlock)->raw_lock) 53 #define _raw_write_lock(rwlock) __raw_write_lock(&(rwlock)->raw_lock) 54 #define _raw_write_trylock(rwlock) __raw_write_trylock(&(rwlock)->raw_lock [all...] |
/prebuilt/ndk/android-ndk-r4/platforms/android-5/arch-x86/usr/include/linux/ |
spinlock.h | 50 #define _raw_read_lock(rwlock) __raw_read_lock(&(rwlock)->raw_lock) 51 #define _raw_read_trylock(rwlock) __raw_read_trylock(&(rwlock)->raw_lock) 52 #define _raw_read_unlock(rwlock) __raw_read_unlock(&(rwlock)->raw_lock) 53 #define _raw_write_lock(rwlock) __raw_write_lock(&(rwlock)->raw_lock) 54 #define _raw_write_trylock(rwlock) __raw_write_trylock(&(rwlock)->raw_lock [all...] |
/prebuilt/ndk/android-ndk-r4/platforms/android-8/arch-arm/usr/include/linux/ |
spinlock.h | 50 #define _raw_read_lock(rwlock) __raw_read_lock(&(rwlock)->raw_lock) 51 #define _raw_read_trylock(rwlock) __raw_read_trylock(&(rwlock)->raw_lock) 52 #define _raw_read_unlock(rwlock) __raw_read_unlock(&(rwlock)->raw_lock) 53 #define _raw_write_lock(rwlock) __raw_write_lock(&(rwlock)->raw_lock) 54 #define _raw_write_trylock(rwlock) __raw_write_trylock(&(rwlock)->raw_lock [all...] |
/prebuilt/ndk/android-ndk-r4/platforms/android-8/arch-x86/usr/include/linux/ |
spinlock.h | 50 #define _raw_read_lock(rwlock) __raw_read_lock(&(rwlock)->raw_lock) 51 #define _raw_read_trylock(rwlock) __raw_read_trylock(&(rwlock)->raw_lock) 52 #define _raw_read_unlock(rwlock) __raw_read_unlock(&(rwlock)->raw_lock) 53 #define _raw_write_lock(rwlock) __raw_write_lock(&(rwlock)->raw_lock) 54 #define _raw_write_trylock(rwlock) __raw_write_trylock(&(rwlock)->raw_lock [all...] |
/prebuilt/ndk/android-ndk-r5/platforms/android-3/arch-arm/usr/include/linux/ |
spinlock.h | 50 #define _raw_read_lock(rwlock) __raw_read_lock(&(rwlock)->raw_lock) 51 #define _raw_read_trylock(rwlock) __raw_read_trylock(&(rwlock)->raw_lock) 52 #define _raw_read_unlock(rwlock) __raw_read_unlock(&(rwlock)->raw_lock) 53 #define _raw_write_lock(rwlock) __raw_write_lock(&(rwlock)->raw_lock) 54 #define _raw_write_trylock(rwlock) __raw_write_trylock(&(rwlock)->raw_lock [all...] |
/prebuilt/ndk/android-ndk-r6/platforms/android-3/arch-arm/usr/include/linux/ |
spinlock.h | 50 #define _raw_read_lock(rwlock) __raw_read_lock(&(rwlock)->raw_lock) 51 #define _raw_read_trylock(rwlock) __raw_read_trylock(&(rwlock)->raw_lock) 52 #define _raw_read_unlock(rwlock) __raw_read_unlock(&(rwlock)->raw_lock) 53 #define _raw_write_lock(rwlock) __raw_write_lock(&(rwlock)->raw_lock) 54 #define _raw_write_trylock(rwlock) __raw_write_trylock(&(rwlock)->raw_lock [all...] |
/prebuilt/ndk/android-ndk-r6/platforms/android-3/arch-x86/usr/include/linux/ |
spinlock.h | 50 #define _raw_read_lock(rwlock) __raw_read_lock(&(rwlock)->raw_lock) 51 #define _raw_read_trylock(rwlock) __raw_read_trylock(&(rwlock)->raw_lock) 52 #define _raw_read_unlock(rwlock) __raw_read_unlock(&(rwlock)->raw_lock) 53 #define _raw_write_lock(rwlock) __raw_write_lock(&(rwlock)->raw_lock) 54 #define _raw_write_trylock(rwlock) __raw_write_trylock(&(rwlock)->raw_lock [all...] |
/bionic/libc/kernel/arch-x86/asm/ |
spinlock_32.h | 16 #include <asm/rwlock.h>
|
/development/ndk/platforms/android-9/arch-x86/include/asm/ |
spinlock_32.h | 16 #include <asm/rwlock.h>
|
/external/kernel-headers/original/linux/ |
spinlock.h | 5 * include/linux/spinlock.h - generic spinlock/rwlock declarations 7 * here's the role of the various spinlock/rwlock related include files: 154 # define _raw_read_lock(rwlock) __raw_read_lock(&(rwlock)->raw_lock) 155 # define _raw_read_trylock(rwlock) __raw_read_trylock(&(rwlock)->raw_lock) 156 # define _raw_read_unlock(rwlock) __raw_read_unlock(&(rwlock)->raw_lock) 157 # define _raw_write_lock(rwlock) __raw_write_lock(&(rwlock)->raw_lock [all...] |