summaryrefslogtreecommitdiff
path: root/configure.cmake
diff options
context:
space:
mode:
authorDmitry Lenev <dlenev@mysql.com>2010-02-28 07:35:09 +0300
committerDmitry Lenev <dlenev@mysql.com>2010-02-28 07:35:09 +0300
commitdcaa14485222fa6d69ebccc794e73c5586657e39 (patch)
tree72819bde0c313c8ef3b67a20ff9ac4fe00833093 /configure.cmake
parente5f595601422ead2ddff450dc77e7062a7959911 (diff)
downloadmariadb-git-dcaa14485222fa6d69ebccc794e73c5586657e39.tar.gz
Fix for bug #51105 "MDL deadlock in rqg_mdl_stability test
on Windows". On platforms where read-write lock implementation does not prefer readers by default (Windows, Solaris) server might have deadlocked while detecting MDL deadlock. MDL deadlock detector relies on the fact that read-write locks which are used in its implementation prefer readers (see new comment for MDL_lock::m_rwlock for details). So far MDL code assumed that default implementation of read/write locks for the system has this property. Indeed, this turned out ot be wrong, for example, for Windows or Solaris. Thus MDL deadlock detector might have deadlocked on these systems. This fix simply adds portable implementation of read/write lock which prefer readers and changes MDL code to use this new type of synchronization primitive. No test case is added as existing rqg_mdl_stability test can serve as one.
Diffstat (limited to 'configure.cmake')
-rw-r--r--configure.cmake1
1 files changed, 1 insertions, 0 deletions
diff --git a/configure.cmake b/configure.cmake
index 243d3b03b45..31e38aaa2cd 100644
--- a/configure.cmake
+++ b/configure.cmake
@@ -308,6 +308,7 @@ CHECK_FUNCTION_EXISTS (pthread_condattr_setclock HAVE_PTHREAD_CONDATTR_SETCLOCK)
CHECK_FUNCTION_EXISTS (pthread_init HAVE_PTHREAD_INIT)
CHECK_FUNCTION_EXISTS (pthread_key_delete HAVE_PTHREAD_KEY_DELETE)
CHECK_FUNCTION_EXISTS (pthread_rwlock_rdlock HAVE_PTHREAD_RWLOCK_RDLOCK)
+CHECK_FUNCTION_EXISTS (pthread_rwlockattr_setkind_np HAVE_PTHREAD_RWLOCKATTR_SETKIND_NP)
CHECK_FUNCTION_EXISTS (pthread_sigmask HAVE_PTHREAD_SIGMASK)
CHECK_FUNCTION_EXISTS (pthread_threadmask HAVE_PTHREAD_THREADMASK)
CHECK_FUNCTION_EXISTS (pthread_yield_np HAVE_PTHREAD_YIELD_NP)