diff options
author | Alexey Botchkov <holyfoot@mysql.com> | 2010-03-01 11:44:11 +0400 |
---|---|---|
committer | Alexey Botchkov <holyfoot@mysql.com> | 2010-03-01 11:44:11 +0400 |
commit | b184d466acee921247541fd0a42eb62d23b07dec (patch) | |
tree | b279c5c0db5401c31f58206324ab0ae3c25c2af8 | |
parent | a8d2da233644af86f7f60ffd8bcf71f4fdba1719 (diff) | |
parent | 40e12231fe7fdcfacc388b9be1986be48e6021ee (diff) | |
download | mariadb-git-b184d466acee921247541fd0a42eb62d23b07dec.tar.gz |
merging.
-rwxr-xr-x | CMakeLists.txt | 38 | ||||
-rw-r--r-- | mysql-test/suite/sys_vars/r/optimizer_search_depth_basic.result | 10 | ||||
-rw-r--r-- | storage/perfschema/pfs_instr.cc | 2 |
3 files changed, 33 insertions, 17 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 036d0cdb9d6..d20939f33ac 100755 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -32,26 +32,32 @@ IF(DEFINED CMAKE_BUILD_TYPE) SET(HAVE_CMAKE_BUILD_TYPE TRUE) ENDIF() SET(CUSTOM_C_FLAGS $ENV{CFLAGS}) -IF(NOT CUSTOM_C_FLAGS) - SET(CUSTOM_C_FLAGS ${CMAKE_C_FLAGS}) -ENDIF() -OPTION(WITH_DEBUG "Use dbug" OFF) +OPTION(WITH_DEBUG "Use dbug/safemutex" OFF) OPTION(WITH_DEBUG_FULL "Use dbug and safemalloc/safemutex. Slow" OFF) -IF(NOT HAVE_CMAKE_BUILD_TYPE) - IF(BUILD_CONFIG OR NOT CUSTOM_C_FLAGS) - IF(WITH_DEBUG) - SET(CMAKE_BUILD_TYPE "Debug" CACHE STRING "Debug build" FORCE) - ELSE() - SET(CMAKE_BUILD_TYPE "RelWithDebInfo" CACHE STRING - "RelWithDebInfo build" FORCE) - ENDIF() - ENDIF() -ENDIF() -IF(WITH_DEBUG_FULL) - SET(WITH_DEBUG ON CACHE BOOL "Use DBUG") +# We choose to provide WITH_DEBUG as alias to standard CMAKE_BUILD_TYPE=Debug +# which turns out to be not trivial, as this involves synchronization +# between CMAKE_BUILD_TYPE and WITH_DEBUG. Besides, we have to deal with cases +# where WITH_DEBUG is reset from ON to OFF and here we need to reset +# CMAKE_BUILD_TYPE to either none or default RelWithDebInfo + +SET(BUILDTYPE_DOCSTRING + "Choose the type of build, options are: None(CMAKE_CXX_FLAGS or + CMAKE_C_FLAGS used) Debug Release RelWithDebInfo MinSizeRel") + +IF(WITH_DEBUG OR WITH_DEBUG_FULL) + SET(CMAKE_BUILD_TYPE "Debug" CACHE STRING ${BUILDTYPE_DOCSTRING} FORCE) + SET(OLD_WITH_DEBUG 1 CACHE INTERNAL "" FORCE) +ELSEIF(NOT HAVE_CMAKE_BUILD_TYPE OR OLD_WITH_DEBUG) + IF(CUSTOM_C_FLAGS) + SET(CMAKE_BUILD_TYPE "" CACHE STRING ${BUILDTYPE_DOCSTRING} FORCE) + ELSE(CMAKE_BUILD_TYPE MATCHES "Debug" OR NOT HAVE_CMAKE_BUILD_TYPE) + SET(CMAKE_BUILD_TYPE "RelWithDebInfo" CACHE STRING + ${BUILDTYPE_DOCSTRING} FORCE) + ENDIF() + SET(OLD_WITH_DEBUG 0 CACHE INTERNAL "" FORCE) ENDIF() IF(BUILD_CONFIG) diff --git a/mysql-test/suite/sys_vars/r/optimizer_search_depth_basic.result b/mysql-test/suite/sys_vars/r/optimizer_search_depth_basic.result index 4d94fb02be7..de448d3e2fc 100644 --- a/mysql-test/suite/sys_vars/r/optimizer_search_depth_basic.result +++ b/mysql-test/suite/sys_vars/r/optimizer_search_depth_basic.result @@ -10,6 +10,7 @@ SELECT @start_session_value; SET @@global.optimizer_search_depth = 100; Warnings: Warning 1292 Truncated incorrect optimizer_search_depth value: '100' +Warning 1287 'optimizer-search-depth=63' is deprecated and will be removed in a future release. Please use a search depth less than 63 instead SET @@global.optimizer_search_depth = DEFAULT; SELECT @@global.optimizer_search_depth; @@global.optimizer_search_depth @@ -17,6 +18,7 @@ SELECT @@global.optimizer_search_depth; SET @@session.optimizer_search_depth = 200; Warnings: Warning 1292 Truncated incorrect optimizer_search_depth value: '200' +Warning 1287 'optimizer-search-depth=63' is deprecated and will be removed in a future release. Please use a search depth less than 63 instead SET @@session.optimizer_search_depth = DEFAULT; SELECT @@session.optimizer_search_depth; @@session.optimizer_search_depth @@ -44,6 +46,8 @@ SELECT @@global.optimizer_search_depth; @@global.optimizer_search_depth 62 SET @@global.optimizer_search_depth = 63; +Warnings: +Warning 1287 'optimizer-search-depth=63' is deprecated and will be removed in a future release. Please use a search depth less than 63 instead SELECT @@global.optimizer_search_depth; @@global.optimizer_search_depth 63 @@ -61,6 +65,8 @@ SELECT @@session.optimizer_search_depth; @@session.optimizer_search_depth 62 SET @@session.optimizer_search_depth = 63; +Warnings: +Warning 1287 'optimizer-search-depth=63' is deprecated and will be removed in a future release. Please use a search depth less than 63 instead SELECT @@session.optimizer_search_depth; @@session.optimizer_search_depth 63 @@ -68,6 +74,7 @@ SELECT @@session.optimizer_search_depth; SET @@global.optimizer_search_depth = 64; Warnings: Warning 1292 Truncated incorrect optimizer_search_depth value: '64' +Warning 1287 'optimizer-search-depth=63' is deprecated and will be removed in a future release. Please use a search depth less than 63 instead SELECT @@global.optimizer_search_depth; @@global.optimizer_search_depth 63 @@ -80,6 +87,7 @@ SELECT @@global.optimizer_search_depth; SET @@global.optimizer_search_depth = 65536; Warnings: Warning 1292 Truncated incorrect optimizer_search_depth value: '65536' +Warning 1287 'optimizer-search-depth=63' is deprecated and will be removed in a future release. Please use a search depth less than 63 instead SELECT @@global.optimizer_search_depth; @@global.optimizer_search_depth 63 @@ -96,6 +104,7 @@ SELECT @@global.optimizer_search_depth; SET @@session.optimizer_search_depth = 64; Warnings: Warning 1292 Truncated incorrect optimizer_search_depth value: '64' +Warning 1287 'optimizer-search-depth=63' is deprecated and will be removed in a future release. Please use a search depth less than 63 instead SELECT @@session.optimizer_search_depth; @@session.optimizer_search_depth 63 @@ -110,6 +119,7 @@ ERROR 42000: Incorrect argument type to variable 'optimizer_search_depth' SET @@session.optimizer_search_depth = 65550; Warnings: Warning 1292 Truncated incorrect optimizer_search_depth value: '65550' +Warning 1287 'optimizer-search-depth=63' is deprecated and will be removed in a future release. Please use a search depth less than 63 instead SELECT @@session.optimizer_search_depth; @@session.optimizer_search_depth 63 diff --git a/storage/perfschema/pfs_instr.cc b/storage/perfschema/pfs_instr.cc index 557ec1c14b5..28b54cc6979 100644 --- a/storage/perfschema/pfs_instr.cc +++ b/storage/perfschema/pfs_instr.cc @@ -66,7 +66,7 @@ ulong events_waits_history_per_thread; /** Number of instruments class per thread. */ ulong instr_class_per_thread; /** Number of locker lost. @sa LOCKER_STACK_SIZE. */ -ulong locker_lost; +ulong locker_lost= 0; /** Mutex instrumentation instances array. |