mariadb/BUILD/compile-pentium-valgrind-max
Marko Mäkelä 98406ba452 Bug#53593: Add some instrumentation to improve Valgrind sensitivity
BUILD/*: Add valgrind_configs=--with-valgrind.
BUILD/*: Remove -USAFEMALLOC from valgrind_flags.

configure.in: Add AC_ARG_WITH(valgrind) and HAVE_VALGRIND.

include/my_sys.h: Define a number of MEM_ wrappers for VALGRIND_ functions.
include/my_sys.h: Make TRASH do MEM_UNDEFINED().

include/m_string.h: Remove unused macro bzero_if_purify(A,B).

_mymalloc(): Declare MEM_UNDEFINED() on the allocated memory.

_myfree(): Declare MEM_NOACCESS() on the freed memory.

storage/innobase/include/univ.i: Enable UNIV_DEBUG_VALGRIND based on
HAVE_VALGRIND rather than HAVE_purify.

Possible things to do:
 * In my_global.h, remove the defined(HAVE_purify) condition
   from the _WIN32 uint3korr().
 * In my_global.h *int*korr(), use | instead of +
   in order to keep the Valgrind V bits accurate
 * Consider replacing HAVE_purify with HAVE_VALGRIND
 * Use VALGRIND_CREATE_BLOCK, VALGRIND_DISCARD in mem_root and similar places
2010-05-20 13:40:42 +03:00

24 lines
892 B
Bash
Executable file

#! /bin/sh
path=`dirname $0`
. "$path/SETUP.sh"
extra_flags="$pentium_cflags $debug_cflags $valgrind_flags"
extra_configs="$pentium_configs $debug_configs $valgrind_configs $max_configs"
. "$path/FINISH.sh"
if test -z "$just_print"
then
set +v +x
echo "\
******************************************************************************
Note that by default BUILD/compile-pentium-valgrind-max calls 'configure' with
--enable-assembler. When Valgrind detects an error involving an assembly
function (for example an uninitialized value used as an argument of an
assembly function), Valgrind will not print the stacktrace and 'valgrind
--gdb-attach=yes' will not work either. If you need a stacktrace in those
cases, you have to run BUILD/compile-pentium-valgrind-max with the
--disable-assembler argument.
******************************************************************************"
fi