/bionic/libc/bionic/ |
D | pthread_mutex.cpp | 148 static inline __always_inline int PIMutexTryLock(PIMutex& mutex) { in PIMutexTryLock() argument 152 if (__predict_true(atomic_compare_exchange_strong_explicit(&mutex.owner_tid, in PIMutexTryLock() 160 if (mutex.type == PTHREAD_MUTEX_NORMAL) { in PIMutexTryLock() 163 if (mutex.type == PTHREAD_MUTEX_ERRORCHECK) { in PIMutexTryLock() 166 if (mutex.counter == 0xffff) { in PIMutexTryLock() 169 mutex.counter++; in PIMutexTryLock() 177 static int __attribute__((noinline)) PIMutexTimedLock(PIMutex& mutex, in PIMutexTimedLock() argument 180 int ret = PIMutexTryLock(mutex); in PIMutexTimedLock() 186 ret = -__futex_pi_lock_ex(&mutex.owner_tid, mutex.shared, use_realtime_clock, abs_timeout); in PIMutexTimedLock() 191 static int PIMutexUnlock(PIMutex& mutex) { in PIMutexUnlock() argument [all …]
|
D | pthread_cond.cpp | 184 static int __pthread_cond_timedwait(pthread_cond_internal_t* cond, pthread_mutex_t* mutex, in __pthread_cond_timedwait() argument 197 pthread_mutex_unlock(mutex); in __pthread_cond_timedwait() 205 pthread_mutex_lock(mutex); in __pthread_cond_timedwait() 221 int pthread_cond_wait(pthread_cond_t* cond_interface, pthread_mutex_t* mutex) { in pthread_cond_wait() argument 223 return __pthread_cond_timedwait(cond, mutex, false, nullptr); in pthread_cond_wait() 226 int pthread_cond_timedwait(pthread_cond_t *cond_interface, pthread_mutex_t * mutex, in pthread_cond_timedwait() argument 230 return __pthread_cond_timedwait(cond, mutex, cond->use_realtime_clock(), abstime); in pthread_cond_timedwait() 234 pthread_mutex_t* mutex, in pthread_cond_timedwait_monotonic_np() argument 236 return __pthread_cond_timedwait(__get_internal_cond(cond_interface), mutex, false, abs_timeout); in pthread_cond_timedwait_monotonic_np() 239 int pthread_cond_clockwait(pthread_cond_t* cond_interface, pthread_mutex_t* mutex, clockid_t clock, in pthread_cond_clockwait() argument [all …]
|
/bionic/benchmarks/ |
D | pthread_benchmark.cpp | 69 pthread_mutex_t mutex = PTHREAD_MUTEX_INITIALIZER; in BM_pthread_mutex_lock() local 72 pthread_mutex_lock(&mutex); in BM_pthread_mutex_lock() 73 pthread_mutex_unlock(&mutex); in BM_pthread_mutex_lock() 80 pthread_mutex_t mutex = PTHREAD_ERRORCHECK_MUTEX_INITIALIZER_NP; in BM_pthread_mutex_lock_ERRORCHECK() local 83 pthread_mutex_lock(&mutex); in BM_pthread_mutex_lock_ERRORCHECK() 84 pthread_mutex_unlock(&mutex); in BM_pthread_mutex_lock_ERRORCHECK() 92 pthread_mutex_t mutex = PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP; in BM_pthread_mutex_lock_RECURSIVE() local 95 pthread_mutex_lock(&mutex); in BM_pthread_mutex_lock_RECURSIVE() 96 pthread_mutex_unlock(&mutex); in BM_pthread_mutex_lock_RECURSIVE() 104 pthread_mutex_t mutex; member [all …]
|
D | atomic_benchmark.cpp | 46 static std::mutex mtx; 144 std::lock_guard<std::mutex> _(mtx); in BM_atomic_fetch_add_cs()
|
D | util.h | 29 extern std::mutex g_map_lock;
|
D | bionic_benchmarks.cpp | 88 std::mutex g_map_lock;
|
/bionic/libfdtrack/ |
D | fdtrack.cpp | 54 std::mutex mutex; member 55 std::vector<unwindstack::FrameData> backtrace GUARDED_BY(mutex); 133 std::lock_guard<std::mutex> lock(entry->mutex); in fd_hook() 144 std::lock_guard<std::mutex> lock(entry->mutex); in fd_hook() 161 if (!entry->mutex.try_lock()) { in fdtrack_iterate() 167 entry->mutex.unlock(); in fdtrack_iterate() 173 entry->mutex.unlock(); in fdtrack_iterate() 185 entry->mutex.unlock(); in fdtrack_iterate()
|
/bionic/libc/malloc_debug/ |
D | PointerData.cpp | 61 std::mutex PointerData::pointer_mutex_; 65 std::mutex PointerData::frame_mutex_; 74 std::mutex PointerData::free_pointer_mutex_; 171 std::lock_guard<std::mutex> frame_guard(frame_mutex_); in AddBacktrace() 195 std::lock_guard<std::mutex> frame_guard(frame_mutex_); in RemoveBacktrace() 218 std::lock_guard<std::mutex> pointer_guard(pointer_mutex_); in Add() 227 std::lock_guard<std::mutex> pointer_guard(pointer_mutex_); in Remove() 245 std::lock_guard<std::mutex> pointer_guard(pointer_mutex_); in GetFrames() 258 std::lock_guard<std::mutex> frame_guard(frame_mutex_); in GetFrames() 273 std::lock_guard<std::mutex> frame_guard(frame_mutex_); in LogBacktrace() [all …]
|
D | PointerData.h | 183 static std::mutex pointer_mutex_; 186 static std::mutex frame_mutex_; 192 static std::mutex free_pointer_mutex_;
|
D | RecordData.cpp | 135 std::lock_guard<std::mutex> entries_lock(entries_lock_); in WriteEntries() 192 std::lock_guard<std::mutex> entries_lock(entries_lock_); in AddEntryOnly()
|
D | MapData.h | 71 std::mutex m_;
|
D | RecordData.h | 173 std::mutex entries_lock_;
|
D | MapData.cpp | 183 std::lock_guard<std::mutex> lock(m_); in find()
|
D | malloc_debug.cpp | 1105 static std::mutex g_dump_lock; 1137 std::lock_guard<std::mutex> guard(g_dump_lock); in debug_write_malloc_leak_info() 1153 std::lock_guard<std::mutex> guard(g_dump_lock); in debug_dump_heap()
|
/bionic/libc/dns/resolv/ |
D | res_data.cpp | 30 pthread_mutex_lock(&mutex); in GlobalStateAccessor() 38 pthread_mutex_unlock(&mutex); in ~GlobalStateAccessor() 50 static pthread_mutex_t mutex; member in GlobalStateAccessor 54 pthread_mutex_t GlobalStateAccessor::mutex = PTHREAD_MUTEX_INITIALIZER; member in GlobalStateAccessor
|
/bionic/tests/ |
D | pthread_test.cpp | 345 pthread_mutex_t mutex; member 350 ASSERT_EQ(0, pthread_mutex_init(&data.mutex, nullptr)); in main() 351 ASSERT_EQ(0, pthread_mutex_lock(&data.mutex)); in main() 357 ASSERT_EQ(0, pthread_mutex_lock(&data.mutex)); in main() 358 ASSERT_EQ(0, pthread_mutex_unlock(&data.mutex)); in main() 372 pthread_mutex_unlock(&data->mutex); in thread_fn() 1510 pthread_mutex_t mutex; member in pthread_CondWakeupTest 1522 std::function<int (pthread_cond_t* cond, pthread_mutex_t* mutex)> wait_function; 1526 ASSERT_EQ(0, pthread_mutex_init(&mutex, nullptr)); in SetUp() 1538 std::function<int(pthread_cond_t* cond, pthread_mutex_t* mutex)> wait_function) { in StartWaitingThread() [all …]
|
D | dlfcn_test.cpp | 1416 std::mutex mtx; in TEST() 1429 std::unique_lock<std::mutex> lock(mtx); in TEST() 1457 std::unique_lock<std::mutex> lock(mtx); in TEST() 1497 std::unique_lock<std::mutex> lock(mtx); in TEST()
|
/bionic/tools/versioner/src/ |
D | DeclarationDatabase.h | 199 std::mutex mutex; variable
|
D | Driver.cpp | 176 static std::mutex cc1_init_mutex; in generateTargetCC1Flags() 177 std::unique_lock<std::mutex> lock(cc1_init_mutex); in generateTargetCC1Flags()
|
D | DeclarationDatabase.cpp | 340 std::unique_lock<std::mutex> lock(this->mutex); in parseAST()
|
/bionic/libc/malloc_debug/tests/ |
D | malloc_debug_system_tests.cpp | 158 std::lock_guard<std::mutex> guard(data_lock_); in LogReader() 189 std::lock_guard<std::mutex> guard(data_lock_); in GetLog() 196 std::mutex data_lock_;
|
/bionic/docs/ |
D | status.md | 131 * `pthread_mutexattr_getprotocol`/`pthread_mutexattr_setprotocol` (mutex priority inheritance) 374 for example, calling a `pthread_mutex_` function on a destroyed mutex,
|
D | elf-tls.md | 509 [elf_tls.cpp][tls_modules-libc]). `__tls_get_addr` in libc.so acquires the `TlsModules::mutex` and
|