From 1e6138c88c7f3bb1f0e8fb785080ac5abc24210c Mon Sep 17 00:00:00 2001 From: Jason Evans Date: Sat, 24 Mar 2012 19:36:27 -0700 Subject: [PATCH] Remove malloc_mutex_trylock(). Remove malloc_mutex_trylock(); it has not been used for quite some time. --- include/jemalloc/internal/mutex.h | 15 --------------- 1 file changed, 15 deletions(-) diff --git a/include/jemalloc/internal/mutex.h b/include/jemalloc/internal/mutex.h index 98f2cba5..ad4f9c24 100644 --- a/include/jemalloc/internal/mutex.h +++ b/include/jemalloc/internal/mutex.h @@ -41,7 +41,6 @@ void malloc_mutex_postfork_child(malloc_mutex_t *mutex); #ifndef JEMALLOC_ENABLE_INLINE void malloc_mutex_lock(malloc_mutex_t *mutex); -bool malloc_mutex_trylock(malloc_mutex_t *mutex); void malloc_mutex_unlock(malloc_mutex_t *mutex); #endif @@ -59,20 +58,6 @@ malloc_mutex_lock(malloc_mutex_t *mutex) } } -JEMALLOC_INLINE bool -malloc_mutex_trylock(malloc_mutex_t *mutex) -{ - - if (isthreaded) { -#ifdef JEMALLOC_OSSPIN - return (OSSpinLockTry(mutex) == false); -#else - return (pthread_mutex_trylock(mutex) != 0); -#endif - } else - return (false); -} - JEMALLOC_INLINE void malloc_mutex_unlock(malloc_mutex_t *mutex) {