Lines Matching refs:mutex
67 JEMALLOC_EXPORT int _pthread_mutex_init_calloc_cb(pthread_mutex_t *mutex,
72 _pthread_mutex_init_calloc_cb(pthread_mutex_t *mutex,
78 mutex, calloc_cb));
83 malloc_mutex_init(malloc_mutex_t *mutex)
87 if (!InitializeCriticalSectionAndSpinCount(&mutex->lock,
91 mutex->lock = 0;
94 mutex->postponed_next = postponed_mutexes;
95 postponed_mutexes = mutex;
97 if (_pthread_mutex_init_calloc_cb(&mutex->lock, base_calloc) !=
107 if (pthread_mutex_init(&mutex->lock, &attr) != 0) {
117 malloc_mutex_prefork(malloc_mutex_t *mutex)
120 malloc_mutex_lock(mutex);
124 malloc_mutex_postfork_parent(malloc_mutex_t *mutex)
127 malloc_mutex_unlock(mutex);
131 malloc_mutex_postfork_child(malloc_mutex_t *mutex)
135 malloc_mutex_unlock(mutex);
137 if (malloc_mutex_init(mutex)) {
138 malloc_printf("<jemalloc>: Error re-initializing mutex in "