Home | History | Annotate | Download | only in drd

Lines Matching refs:rwlock

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));
267 "Destroying locked rwlock",
283 DRD_(rwlock_get_or_allocate)(const Addr rwlock, const RwLockT rwlock_type)
287 tl_assert(offsetof(DrdClientobj, rwlock) == 0);
288 p = &(DRD_(clientobj_get)(rwlock, ClientRwlock)->rwlock);
295 if (DRD_(clientobj_present)(rwlock, rwlock + 1))
299 .addr = rwlock,
309 p = &(DRD_(clientobj_add)(rwlock, ClientRwlock)->rwlock);
310 DRD_(rwlock_initialize)(p, rwlock, rwlock_type);
314 static struct rwlock_info* DRD_(rwlock_get)(const Addr rwlock)
316 tl_assert(offsetof(DrdClientobj, rwlock) == 0);
317 return &(DRD_(clientobj_get)(rwlock, ClientRwlock)->rwlock);
321 struct rwlock_info* DRD_(rwlock_pre_init)(const Addr rwlock,
331 rwlock);
334 p = DRD_(rwlock_get)(rwlock);
351 p = DRD_(rwlock_get_or_allocate)(rwlock, rwlock_type);
357 void DRD_(rwlock_post_destroy)(const Addr rwlock, const RwLockT rwlock_type)
361 p = DRD_(rwlock_get)(rwlock);
366 .addr = rwlock,
378 DRD_(clientobj_remove)(rwlock, ClientRwlock);
387 void DRD_(rwlock_pre_rdlock)(const Addr rwlock, const RwLockT rwlock_type)
396 rwlock);
399 p = DRD_(rwlock_get_or_allocate)(rwlock, rwlock_type);
416 void DRD_(rwlock_post_rdlock)(const Addr rwlock, const RwLockT rwlock_type,
428 rwlock);
431 p = DRD_(rwlock_get)(rwlock);
456 void DRD_(rwlock_pre_wrlock)(const Addr rwlock, const RwLockT rwlock_type)
460 p = DRD_(rwlock_get)(rwlock);
467 rwlock);
471 p = DRD_(rwlock_get_or_allocate)(rwlock, rwlock_type);
487 * Update rwlock_info state when locking the pthread_rwlock_t rwlock.
491 void DRD_(rwlock_post_wrlock)(const Addr rwlock, const RwLockT rwlock_type,
498 p = DRD_(rwlock_get)(rwlock);
505 rwlock);
524 * Update rwlock_info state when unlocking the pthread_rwlock_t rwlock.
526 * @param rwlock Pointer to pthread_rwlock_t data structure in the client space.
528 * @return New value of the rwlock recursion count.
533 void DRD_(rwlock_pre_unlock)(const Addr rwlock, const RwLockT rwlock_type)
545 rwlock);
548 p = DRD_(rwlock_get)(rwlock);
553 .addr = rwlock,
587 rwlock, p->acquired_at, held, DRD_(s_shared_threshold_ms) };
591 "rwlock",
598 * This pthread_rwlock_unlock() call really unlocks the rwlock. Save
600 * when this rwlock is locked again.
617 rwlock, p->acquired_at, held,
622 "rwlock",
629 * This pthread_rwlock_unlock() call really unlocks the rwlock. Save
631 * when this rwlock is locked again.