Commit cc814068 authored by Davi Arnaut's avatar Davi Arnaut

Bug#34043: Server loops excessively in _checkchunk() when safemalloc is enabled

Post-merge fix: remove --with-debug=full, it was only used for safemalloc.

BUILD/compile-pentium-mysqlfs-debug:
  Remove build script for a feature that is long gone.
parent 0cbc2008
...@@ -52,7 +52,6 @@ EXTRA_DIST = FINISH.sh \ ...@@ -52,7 +52,6 @@ EXTRA_DIST = FINISH.sh \
compile-pentium-icc-yassl \ compile-pentium-icc-yassl \
compile-pentium-max \ compile-pentium-max \
compile-pentium-myodbc \ compile-pentium-myodbc \
compile-pentium-mysqlfs-debug \
compile-pentium-pgcc \ compile-pentium-pgcc \
compile-pentium-valgrind-max \ compile-pentium-valgrind-max \
compile-pentium64 \ compile-pentium64 \
......
...@@ -14,7 +14,6 @@ Usage: $0 [-h|-n] [configure-options] ...@@ -14,7 +14,6 @@ Usage: $0 [-h|-n] [configure-options]
-h, --help Show this help message. -h, --help Show this help message.
-n, --just-print Don't actually run any commands; just print them. -n, --just-print Don't actually run any commands; just print them.
-c, --just-configure Stop after running configure. -c, --just-configure Stop after running configure.
--with-debug=full Build with full debug.
--warning-mode=[old|pedantic|maintainer] --warning-mode=[old|pedantic|maintainer]
Influences the debug flags. Old is default. Influences the debug flags. Old is default.
--prefix=path Build with prefix 'path'. --prefix=path Build with prefix 'path'.
...@@ -30,8 +29,6 @@ parse_options() ...@@ -30,8 +29,6 @@ parse_options()
case "$1" in case "$1" in
--prefix=*) --prefix=*)
prefix=`get_key_value "$1"`;; prefix=`get_key_value "$1"`;;
--with-debug=full)
full_debug="=full";;
--warning-mode=*) --warning-mode=*)
warning_mode=`get_key_value "$1"`;; warning_mode=`get_key_value "$1"`;;
-c | --just-configure) -c | --just-configure)
...@@ -60,7 +57,6 @@ fi ...@@ -60,7 +57,6 @@ fi
prefix="/usr/local/mysql" prefix="/usr/local/mysql"
just_print= just_print=
just_configure= just_configure=
full_debug=
warning_mode= warning_mode=
maintainer_mode= maintainer_mode=
...@@ -116,7 +112,6 @@ else ...@@ -116,7 +112,6 @@ else
cxx_warnings="$warnings -Wno-unused-parameter" cxx_warnings="$warnings -Wno-unused-parameter"
# cxx_warnings="$cxx_warnings -Woverloaded-virtual -Wsign-promo" # cxx_warnings="$cxx_warnings -Woverloaded-virtual -Wsign-promo"
cxx_warnings="$cxx_warnings -Wctor-dtor-privacy -Wnon-virtual-dtor" cxx_warnings="$cxx_warnings -Wctor-dtor-privacy -Wnon-virtual-dtor"
# Added unless --with-debug=full
debug_extra_cflags="-O0 -g3 -gdwarf-2" debug_extra_cflags="-O0 -g3 -gdwarf-2"
fi fi
...@@ -141,11 +136,8 @@ base_cxxflags="-felide-constructors -fno-exceptions -fno-rtti" ...@@ -141,11 +136,8 @@ base_cxxflags="-felide-constructors -fno-exceptions -fno-rtti"
# Be as fast as we can be without losing our ability to backtrace. # Be as fast as we can be without losing our ability to backtrace.
fast_cflags="-O3 -fno-omit-frame-pointer" fast_cflags="-O3 -fno-omit-frame-pointer"
debug_configs="--with-debug$full_debug" debug_configs="--with-debug"
if [ -z "$full_debug" ] debug_cflags="$debug_cflags $debug_extra_cflags"
then
debug_cflags="$debug_cflags $debug_extra_cflags"
fi
# #
# Configuration options. # Configuration options.
......
...@@ -148,7 +148,6 @@ Usage: $0 [options] ...@@ -148,7 +148,6 @@ Usage: $0 [options]
--extended-help Show extended help message --extended-help Show extended help message
--without-debug Build non-debug version --without-debug Build non-debug version
--with-debug Build debug version --with-debug Build debug version
--with-debug=full Build with full debug.
--configure-only Stop after running configure. --configure-only Stop after running configure.
--use-autotools Start by running autoconf, automake,.. tools --use-autotools Start by running autoconf, automake,.. tools
--no-autotools Start from configure --no-autotools Start from configure
...@@ -262,10 +261,6 @@ extended_usage() ...@@ -262,10 +261,6 @@ extended_usage()
This flag prevents the use of GPL libraries which cannot be used This flag prevents the use of GPL libraries which cannot be used
under a commercial license, such as the readline library. under a commercial license, such as the readline library.
--with-debug[=full]
This option will ensure that the version is built with debug
information enabled; the optimisation level is decreased to -O.
--developer --developer
This option changes a number of things to make the version built This option changes a number of things to make the version built
more appropriate to the debugging and testing needs of developers. more appropriate to the debugging and testing needs of developers.
...@@ -658,11 +653,6 @@ parse_options() ...@@ -658,11 +653,6 @@ parse_options()
--datadir=*) --datadir=*)
datadir=`get_key_value "$1"` datadir=`get_key_value "$1"`
;; ;;
--with-debug=full)
full_debug="=full"
with_debug_flag="yes"
fast_flag="no"
;;
--without-debug) --without-debug)
with_debug_flag="no" with_debug_flag="no"
if test "x$fast_flag" != "xyes" ; then if test "x$fast_flag" != "xyes" ; then
...@@ -1044,10 +1034,7 @@ set_warning_flags() ...@@ -1044,10 +1034,7 @@ set_warning_flags()
# C++ warnings # C++ warnings
cxx_warnings="$warnings -Woverloaded-virtual -Wsign-promo -Wreorder" cxx_warnings="$warnings -Woverloaded-virtual -Wsign-promo -Wreorder"
cxx_warnings="$warnings -Wctor-dtor-privacy -Wnon-virtual-dtor" cxx_warnings="$warnings -Wctor-dtor-privacy -Wnon-virtual-dtor"
# Added unless --with-debug=full compiler_flags="$compiler_flags -Wuninitialized"
if test "x$full_debug" = "x" ; then
compiler_flags="$compiler_flags -Wuninitialized"
fi
elif test "x$warning_mode" = "xpedantic" ; then elif test "x$warning_mode" = "xpedantic" ; then
warnings="-W -Wall -ansi -pedantic -Wno-long-long -D_POSIX_SOURCE" warnings="-W -Wall -ansi -pedantic -Wno-long-long -D_POSIX_SOURCE"
c_warnings="$warnings" c_warnings="$warnings"
...@@ -1113,7 +1100,7 @@ set_base_configs() ...@@ -1113,7 +1100,7 @@ set_base_configs()
base_configs="$base_configs --localstatedir=$datadir" base_configs="$base_configs --localstatedir=$datadir"
fi fi
if test "x$with_debug_flag" = "xyes" ; then if test "x$with_debug_flag" = "xyes" ; then
base_configs="$base_configs --with-debug$full_debug" base_configs="$base_configs --with-debug"
fi fi
base_configs="$base_configs --enable-local-infile" base_configs="$base_configs --enable-local-infile"
base_configs="$base_configs --enable-thread-safe-client" base_configs="$base_configs --enable-thread-safe-client"
...@@ -1546,7 +1533,6 @@ gpl="yes" ...@@ -1546,7 +1533,6 @@ gpl="yes"
version_text= version_text=
developer_flag="no" developer_flag="no"
just_configure= just_configure=
full_debug=
warning_mode= warning_mode=
with_flags= with_flags=
error_inject_flag= error_inject_flag=
......
...@@ -4,16 +4,6 @@ path=`dirname $0` ...@@ -4,16 +4,6 @@ path=`dirname $0`
. "$path/SETUP.sh" . "$path/SETUP.sh"
extra_configs="$max_configs --with-ndb-test --with-ndb-ccflags='-DERROR_INSERT'" extra_configs="$max_configs --with-ndb-test --with-ndb-ccflags='-DERROR_INSERT'"
if [ "$full_debug" ] extra_flags="$fast_cflags $max_cflags -g"
then
extra_flags="$debug_cflags"
c_warnings="$c_warnings $debug_extra_warnings"
cxx_warnings="$cxx_warnings $debug_extra_warnings"
extra_configs="$debug_configs $extra_configs"
else
extra_flags="$fast_cflags"
fi
extra_flags="$extra_flags $max_cflags -g"
. "$path/FINISH.sh" . "$path/FINISH.sh"
#! /bin/sh #! /bin/sh
path=`dirname $0` path=`dirname $0`
set -- "$@" --with-debug=full
. "$path/SETUP.sh" . "$path/SETUP.sh"
extra_flags="$pentium_cflags $debug_cflags" extra_flags="$pentium_cflags $debug_cflags"
......
#! /bin/sh #! /bin/sh
path=`dirname $0` path=`dirname $0`
set -- "$@" --with-debug=full
. "$path/SETUP.sh" . "$path/SETUP.sh"
extra_flags="$pentium_cflags $debug_cflags" extra_flags="$pentium_cflags $debug_cflags"
......
#! /bin/sh #! /bin/sh
path=`dirname $0` path=`dirname $0`
set -- "$@" --with-debug=full
. "$path/SETUP.sh" . "$path/SETUP.sh"
extra_flags="$pentium_cflags $debug_cflags" extra_flags="$pentium_cflags $debug_cflags"
......
...@@ -6,6 +6,6 @@ path=`dirname $0` ...@@ -6,6 +6,6 @@ path=`dirname $0`
extra_flags="$pentium_cflags $debug_cflags" extra_flags="$pentium_cflags $debug_cflags"
extra_configs="$pentium_configs $debug_configs" extra_configs="$pentium_configs $debug_configs"
extra_configs="$extra_configs --with-debug=full --with-ssl=/usr" extra_configs="$extra_configs --with-debug --with-ssl=/usr"
. "$path/FINISH.sh" . "$path/FINISH.sh"
...@@ -6,6 +6,6 @@ path=`dirname $0` ...@@ -6,6 +6,6 @@ path=`dirname $0`
extra_flags="$pentium_cflags $debug_cflags" extra_flags="$pentium_cflags $debug_cflags"
extra_configs="$pentium_configs $debug_configs" extra_configs="$pentium_configs $debug_configs"
extra_configs="$extra_configs --with-debug=full --with-ssl" extra_configs="$extra_configs --with-debug --with-ssl"
. "$path/FINISH.sh" . "$path/FINISH.sh"
#! /bin/sh
path=`dirname $0`
. "$path/SETUP.sh"
extra_flags="$pentium_cflags $debug_cflags"
extra_configs="$pentium_configs $debug_configs $static_link"
extra_configs="$extra_configs --with-debug=full --with-mysqlfs --without-server --without-pstack"
. "$path/FINISH.sh"
#! /bin/sh #! /bin/sh
path=`dirname $0` path=`dirname $0`
set -- "$@" --with-debug=full
. "$path/SETUP.sh" . "$path/SETUP.sh"
extra_flags="$pentium64_cflags $debug_cflags" extra_flags="$pentium64_cflags $debug_cflags"
......
#! /bin/sh #! /bin/sh
path=`dirname $0` path=`dirname $0`
set -- "$@" --with-debug=full
. "$path/SETUP.sh" . "$path/SETUP.sh"
extra_flags="$pentium64_cflags $debug_cflags" extra_flags="$pentium64_cflags $debug_cflags"
......
...@@ -34,7 +34,6 @@ ENDIF() ...@@ -34,7 +34,6 @@ ENDIF()
SET(CUSTOM_C_FLAGS $ENV{CFLAGS}) SET(CUSTOM_C_FLAGS $ENV{CFLAGS})
OPTION(WITH_DEBUG "Use dbug/safemutex" OFF) OPTION(WITH_DEBUG "Use dbug/safemutex" OFF)
OPTION(WITH_DEBUG_FULL "Use dbug and safemutex. Slow." OFF)
# Distinguish between community and non-community builds, with the # Distinguish between community and non-community builds, with the
# default being a community build. This does not impact the feature # default being a community build. This does not impact the feature
...@@ -60,7 +59,7 @@ SET(BUILDTYPE_DOCSTRING ...@@ -60,7 +59,7 @@ SET(BUILDTYPE_DOCSTRING
"Choose the type of build, options are: None(CMAKE_CXX_FLAGS or "Choose the type of build, options are: None(CMAKE_CXX_FLAGS or
CMAKE_C_FLAGS used) Debug Release RelWithDebInfo MinSizeRel") CMAKE_C_FLAGS used) Debug Release RelWithDebInfo MinSizeRel")
IF(WITH_DEBUG OR WITH_DEBUG_FULL) IF(WITH_DEBUG)
SET(CMAKE_BUILD_TYPE "Debug" CACHE STRING ${BUILDTYPE_DOCSTRING} FORCE) SET(CMAKE_BUILD_TYPE "Debug" CACHE STRING ${BUILDTYPE_DOCSTRING} FORCE)
SET(OLD_WITH_DEBUG 1 CACHE INTERNAL "" FORCE) SET(OLD_WITH_DEBUG 1 CACHE INTERNAL "" FORCE)
ELSEIF(NOT HAVE_CMAKE_BUILD_TYPE OR OLD_WITH_DEBUG) ELSEIF(NOT HAVE_CMAKE_BUILD_TYPE OR OLD_WITH_DEBUG)
...@@ -202,15 +201,10 @@ ENDIF() ...@@ -202,15 +201,10 @@ ENDIF()
# Add safemutex for debug configurations, except on Windows # Add safemutex for debug configurations, except on Windows
# (safemutex has never worked on Windows) # (safemutex has never worked on Windows)
IF(WITH_DEBUG OR WITH_DEBUG_FULL AND NOT WIN32) IF(WITH_DEBUG AND NOT WIN32)
FOREACH(LANG C CXX) FOREACH(LANG C CXX)
IF(WITH_DEBUG_FULL) SET(CMAKE_${LANG}_FLAGS_DEBUG
SET(CMAKE_${LANG}_FLAGS_DEBUG "${CMAKE_${LANG}_FLAGS_DEBUG} -DSAFE_MUTEX")
"${CMAKE_${LANG}_FLAGS_DEBUG} -DSAFE_MUTEX")
ELSE()
SET(CMAKE_${LANG}_FLAGS_DEBUG
"${CMAKE_${LANG}_FLAGS_DEBUG} -DSAFE_MUTEX")
ENDIF()
ENDFOREACH() ENDFOREACH()
ENDIF() ENDIF()
......
...@@ -179,11 +179,6 @@ foreach my $option (@ARGV) ...@@ -179,11 +179,6 @@ foreach my $option (@ARGV)
$cmakeargs = $cmakeargs." -DMYSQL_DATADIR=".substr($option,14); $cmakeargs = $cmakeargs." -DMYSQL_DATADIR=".substr($option,14);
next; next;
} }
if ($option =~ /with-debug=full/)
{
$cmakeargs = $cmakeargs." -DWITH_DEBUG_FULL=1";
next;
}
if ($option =~ /mysql-maintainer-mode/) if ($option =~ /mysql-maintainer-mode/)
{ {
$cmakeargs = $cmakeargs." -DMYSQL_MAINTAINER_MODE=" . $cmakeargs = $cmakeargs." -DMYSQL_MAINTAINER_MODE=" .
......
...@@ -206,7 +206,7 @@ AC_DEFUN([MYSQL_SETUP_NDBCLUSTER], [ ...@@ -206,7 +206,7 @@ AC_DEFUN([MYSQL_SETUP_NDBCLUSTER], [
NDB_DEFS="-DNDB_DEBUG_FULL -DVM_TRACE -DERROR_INSERT -DARRAY_GUARD" NDB_DEFS="-DNDB_DEBUG_FULL -DVM_TRACE -DERROR_INSERT -DARRAY_GUARD"
else else
# no extra ndb debug but still do asserts if debug version # no extra ndb debug but still do asserts if debug version
if test "$with_debug" = "yes" -o "$with_debug" = "full" if test "$with_debug" = "yes"
then then
NDB_DEFS="" NDB_DEFS=""
else else
......
...@@ -1732,22 +1732,14 @@ then ...@@ -1732,22 +1732,14 @@ then
fi fi
AC_ARG_WITH(debug, AC_ARG_WITH(debug,
[ --with-debug Add debug code [AS_HELP_STRING([--with-debug], [Add debug code @<:@default=no@:>@])]
--with-debug=full Add debug code (adds memory checker, very slow)],
[with_debug=$withval], [with_debug=$withval],
[with_debug=no]) [with_debug=no])
if test "$with_debug" = "yes" if test "$with_debug" = "yes"
then then
# Medium debug.
AC_DEFINE([DBUG_ON], [1], [Use libdbug]) AC_DEFINE([DBUG_ON], [1], [Use libdbug])
CFLAGS="$DEBUG_CFLAGS $DEBUG_OPTIMIZE_CC -DSAFE_MUTEX $CFLAGS" CFLAGS="$DEBUG_CFLAGS $DEBUG_OPTIMIZE_CC -DSAFE_MUTEX $CFLAGS"
CXXFLAGS="$DEBUG_CXXFLAGS $DEBUG_OPTIMIZE_CXX -DSAFE_MUTEX $CXXFLAGS" CXXFLAGS="$DEBUG_CXXFLAGS $DEBUG_OPTIMIZE_CXX -DSAFE_MUTEX $CXXFLAGS"
elif test "$with_debug" = "full"
then
# Full debug. Very slow in some cases
AC_DEFINE([DBUG_ON], [1], [Use libdbug])
CFLAGS="$DEBUG_CFLAGS -DSAFE_MUTEX $CFLAGS"
CXXFLAGS="$DEBUG_CXXFLAGS -DSAFE_MUTEX $CXXFLAGS"
else else
# Optimized version. No debug # Optimized version. No debug
AC_DEFINE([DBUG_OFF], [1], [Don't use libdbug]) AC_DEFINE([DBUG_OFF], [1], [Don't use libdbug])
......
...@@ -43,7 +43,7 @@ ENDIF() ...@@ -43,7 +43,7 @@ ENDIF()
# Enable InnoDB's UNIV_DEBUG if MySQL's WITH_DEBUG[_FULL] is defined # Enable InnoDB's UNIV_DEBUG if MySQL's WITH_DEBUG[_FULL] is defined
# enable when this bug is resolved: # enable when this bug is resolved:
# Bug#54861 Additional connections not handled properly in mtr --embedded # Bug#54861 Additional connections not handled properly in mtr --embedded
#IF(WITH_DEBUG OR WITH_DEBUG_FULL) #IF(WITH_DEBUG)
# ADD_DEFINITIONS("-DUNIV_DEBUG") # ADD_DEFINITIONS("-DUNIV_DEBUG")
#ENDIF() #ENDIF()
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment