Commit 7e29c1b5 authored by Sergei Golubchik's avatar Sergei Golubchik

5.5 merge

parents 1e3e81a6 33656e04
...@@ -1436,7 +1436,7 @@ storage/tokudb/ft-index/portability/tests/try-uninit ...@@ -1436,7 +1436,7 @@ storage/tokudb/ft-index/portability/tests/try-uninit
storage/tokudb/ft-index/src/merge_archives_tokufractaltree_static.cmake storage/tokudb/ft-index/src/merge_archives_tokufractaltree_static.cmake
storage/tokudb/ft-index/src/tokufractaltree_static_depends.cc storage/tokudb/ft-index/src/tokufractaltree_static_depends.cc
storage/tokudb/ft-index/src/tests/recovery_fileops_unit_dir storage/tokudb/ft-index/src/tests/recovery_fileops_unit_dir
storage/tokudb/ft-index/portability/toku_config.h storage/tokudb/ft-index/toku_include/toku_config.h
storage/tokudb/ft-index/util/tests/marked-omt-test storage/tokudb/ft-index/util/tests/marked-omt-test
storage/tokudb/ft-index/util/tests/omt-tmpl-test storage/tokudb/ft-index/util/tests/omt-tmpl-test
storage/tokudb/ft-index/util/tests/sort-tmpl-test storage/tokudb/ft-index/util/tests/sort-tmpl-test
...@@ -1450,9 +1450,9 @@ storage/tokudb/ft-index/util/tests/test_partitioned_counter ...@@ -1450,9 +1450,9 @@ storage/tokudb/ft-index/util/tests/test_partitioned_counter
storage/tokudb/ft-index/util/tests/test_partitioned_counter_5833 storage/tokudb/ft-index/util/tests/test_partitioned_counter_5833
storage/tokudb/ft-index/util/tests/threadpool-test storage/tokudb/ft-index/util/tests/threadpool-test
storage/tokudb/ft-index/util/tests/threadpool-testrunf storage/tokudb/ft-index/util/tests/threadpool-testrunf
storage/tokudb/ft-index/tools/tokudb_dump storage/tokudb/ft-index/utils/tokudb_dump
storage/tokudb/ft-index/tools/tokudb_gen storage/tokudb/ft-index/utils/tokudb_gen
storage/tokudb/ft-index/tools/tokudb_load storage/tokudb/ft-index/utils/tokudb_load
storage/connect/connect.cnf storage/connect/connect.cnf
storage/cassandra/cassandra.cnf storage/cassandra/cassandra.cnf
libmysql/libmysql_versions.ld libmysql/libmysql_versions.ld
......
...@@ -508,8 +508,10 @@ ADD_CUSTOM_TARGET(INFO_BIN ALL ...@@ -508,8 +508,10 @@ ADD_CUSTOM_TARGET(INFO_BIN ALL
INSTALL_DOCUMENTATION(README CREDITS COPYING COPYING.LESSER EXCEPTIONS-CLIENT INSTALL_DOCUMENTATION(README CREDITS COPYING COPYING.LESSER EXCEPTIONS-CLIENT
COMPONENT Readme) COMPONENT Readme)
INSTALL_DOCUMENTATION(${CMAKE_BINARY_DIR}/Docs/INFO_SRC
${CMAKE_BINARY_DIR}/Docs/INFO_BIN) # MDEV-6526 these files are not installed anymore
#INSTALL_DOCUMENTATION(${CMAKE_BINARY_DIR}/Docs/INFO_SRC
# ${CMAKE_BINARY_DIR}/Docs/INFO_BIN)
IF(UNIX) IF(UNIX)
INSTALL_DOCUMENTATION(Docs/INSTALL-BINARY COMPONENT Readme) INSTALL_DOCUMENTATION(Docs/INSTALL-BINARY COMPONENT Readme)
......
...@@ -90,7 +90,7 @@ extern "C" { ...@@ -90,7 +90,7 @@ extern "C" {
#if defined(__WIN__) #if defined(__WIN__)
#include <conio.h> #include <conio.h>
#else #else
#include <readline/readline.h> #include <readline.h>
#define HAVE_READLINE #define HAVE_READLINE
#define USE_POPEN #define USE_POPEN
#endif #endif
......
...@@ -122,14 +122,9 @@ ENDIF() ...@@ -122,14 +122,9 @@ ENDIF()
IF(UNIX) IF(UNIX)
SET(WITH_EXTRA_CHARSETS all CACHE STRING "") SET(WITH_EXTRA_CHARSETS all CACHE STRING "")
IF(EXISTS "${CMAKE_SOURCE_DIR}/COPYING")
OPTION(WITH_READLINE "" ON)
ELSE()
OPTION(WITH_LIBEDIT "" ON)
ENDIF()
IF(CMAKE_SYSTEM_NAME STREQUAL "Linux") IF(CMAKE_SYSTEM_NAME STREQUAL "Linux")
SET(WITH_JEMALLOC "yes" CACHE STRING "")
IF(NOT IGNORE_AIO_CHECK) IF(NOT IGNORE_AIO_CHECK)
# Ensure aio is available on Linux (required by InnoDB) # Ensure aio is available on Linux (required by InnoDB)
......
# old cmake does not have ExternalProject file INCLUDE (CheckLibraryExists)
IF(CMAKE_VERSION VERSION_LESS "2.8.6")
MACRO (CHECK_JEMALLOC)
ENDMACRO()
RETURN()
ENDIF()
INCLUDE(ExternalProject) SET(WITH_JEMALLOC auto CACHE STRING
"Build with jemalloc. Possible values are 'yes', 'no', 'auto'")
MACRO (USE_BUNDLED_JEMALLOC) MACRO (CHECK_JEMALLOC)
SET(SOURCE_DIR "${CMAKE_SOURCE_DIR}/extra/jemalloc") # compatibility with old WITH_JEMALLOC values
SET(BINARY_DIR "${CMAKE_BINARY_DIR}/${CMAKE_CFG_INTDIR}/extra/jemalloc/build") IF(WITH_JEMALLOC STREQUAL "bundled")
SET(LIBJEMALLOC "libjemalloc") MESSAGE(FATAL_ERROR "MariaDB no longer bundles jemalloc")
SET(JEMALLOC_CONFIGURE_OPTS "CC=${CMAKE_C_COMPILER} ${CMAKE_C_COMPILER_ARG1}" "--with-private-namespace=jemalloc_internal_" "--enable-cc-silence")
IF (CMAKE_BUILD_TYPE MATCHES "Debug" AND NOT APPLE) # see the comment in CMakeLists.txt
LIST(APPEND JEMALLOC_CONFIGURE_OPTS --enable-debug)
ENDIF() ENDIF()
IF(WITH_JEMALLOC STREQUAL "system")
IF(CMAKE_GENERATOR MATCHES "Makefiles") SET(WITH_JEMALLOC "yes")
SET(MAKE_COMMAND ${CMAKE_MAKE_PROGRAM})
ELSE() # Xcode/Ninja generators
SET(MAKE_COMMAND make)
ENDIF() ENDIF()
ExternalProject_Add(jemalloc IF(WITH_JEMALLOC STREQUAL "yes" OR WITH_JEMALLOC STREQUAL "auto")
PREFIX extra/jemalloc
SOURCE_DIR ${SOURCE_DIR}
BINARY_DIR ${BINARY_DIR}
STAMP_DIR ${BINARY_DIR}
CONFIGURE_COMMAND "${SOURCE_DIR}/configure" ${JEMALLOC_CONFIGURE_OPTS}
BUILD_COMMAND ${MAKE_COMMAND} "build_lib_static"
INSTALL_COMMAND ""
)
ADD_LIBRARY(libjemalloc STATIC IMPORTED)
SET_TARGET_PROPERTIES(libjemalloc PROPERTIES IMPORTED_LOCATION "${BINARY_DIR}/lib/libjemalloc_pic.a")
ADD_DEPENDENCIES(libjemalloc jemalloc)
ENDMACRO()
IF(CMAKE_SYSTEM_NAME MATCHES "Linux" OR APPLE)
# Linux and OSX are the only systems where bundled jemalloc can be built without problems,
# as they both have GNU make and jemalloc actually compiles.
# Also, BSDs use jemalloc as malloc already
SET(WITH_JEMALLOC_DEFAULT "yes")
ELSE()
SET(WITH_JEMALLOC_DEFAULT "no")
ENDIF()
SET(WITH_JEMALLOC ${WITH_JEMALLOC_DEFAULT} CACHE STRING
"Which jemalloc to use. Possible values are 'no', 'bundled', 'system', 'yes' (system if possible, otherwise bundled)")
MACRO (CHECK_JEMALLOC)
IF(WITH_JEMALLOC STREQUAL "system" OR WITH_JEMALLOC STREQUAL "yes")
CHECK_LIBRARY_EXISTS(jemalloc malloc_stats_print "" HAVE_JEMALLOC) CHECK_LIBRARY_EXISTS(jemalloc malloc_stats_print "" HAVE_JEMALLOC)
IF (HAVE_JEMALLOC) IF (HAVE_JEMALLOC)
SET(LIBJEMALLOC jemalloc) SET(LIBJEMALLOC jemalloc)
SET(MALLOC_LIBRARY "system jemalloc") SET(MALLOC_LIBRARY "system jemalloc")
ELSEIF (WITH_JEMALLOC STREQUAL "system")
MESSAGE(FATAL_ERROR "system jemalloc is not found")
ELSEIF (WITH_JEMALLOC STREQUAL "yes") ELSEIF (WITH_JEMALLOC STREQUAL "yes")
SET(trybundled 1) MESSAGE(FATAL_ERROR "jemalloc is not found")
ENDIF()
ENDIF() ENDIF()
IF(WITH_JEMALLOC STREQUAL "bundled" OR trybundled)
USE_BUNDLED_JEMALLOC()
SET(MALLOC_LIBRARY "bundled jemalloc")
ENDIF() ENDIF()
ENDMACRO() ENDMACRO()
...@@ -116,24 +116,23 @@ ENDMACRO() ...@@ -116,24 +116,23 @@ ENDMACRO()
MACRO (MYSQL_USE_BUNDLED_READLINE) MACRO (MYSQL_USE_BUNDLED_READLINE)
SET(USE_NEW_READLINE_INTERFACE 1) SET(USE_NEW_READLINE_INTERFACE 1)
SET(HAVE_HIST_ENTRY 0 CACHE INTERNAL "" FORCE) SET(HAVE_HIST_ENTRY 0 CACHE INTERNAL "" FORCE)
SET(READLINE_INCLUDE_DIR ${CMAKE_SOURCE_DIR}/cmd-line-utils) SET(MY_READLINE_INCLUDE_DIR ${CMAKE_SOURCE_DIR}/cmd-line-utils/readline)
SET(READLINE_LIBRARY readline) SET(MY_READLINE_LIBRARY readline)
ADD_SUBDIRECTORY(${CMAKE_SOURCE_DIR}/cmd-line-utils/readline) ADD_SUBDIRECTORY(${CMAKE_SOURCE_DIR}/cmd-line-utils/readline)
ENDMACRO() ENDMACRO()
MACRO (MYSQL_FIND_SYSTEM_READLINE) MACRO (MYSQL_FIND_SYSTEM_READLINE)
FIND_PATH(READLINE_INCLUDE_DIR readline/readline.h ) FIND_PATH(READLINE_INCLUDE_DIR readline.h PATH_SUFFIXES readline)
FIND_LIBRARY(READLINE_LIBRARY NAMES readline) FIND_LIBRARY(READLINE_LIBRARY NAMES readline)
MARK_AS_ADVANCED(READLINE_INCLUDE_DIR READLINE_LIBRARY) MARK_AS_ADVANCED(READLINE_INCLUDE_DIR READLINE_LIBRARY)
SET(CMAKE_REQUIRES_LIBRARIES ${READLINE_LIBRARY} ${CURSES_LIBRARY})
IF(READLINE_LIBRARY AND READLINE_INCLUDE_DIR) IF(READLINE_LIBRARY AND READLINE_INCLUDE_DIR)
SET(CMAKE_REQUIRED_LIBRARIES ${READLINE_LIBRARY} ${CURSES_LIBRARY}) SET(CMAKE_REQUIRED_LIBRARIES ${READLINE_LIBRARY} ${CURSES_LIBRARY})
SET(CMAKE_REQUIRED_INCLUDES ${READLINE_INCLUDE_DIR})
CHECK_CXX_SOURCE_COMPILES(" CHECK_CXX_SOURCE_COMPILES("
#include <stdio.h> #include <stdio.h>
#include <readline/readline.h> #include <readline.h>
int main(int argc, char **argv) int main(int argc, char **argv)
{ {
rl_completion_func_t *func1= (rl_completion_func_t*)0; rl_completion_func_t *func1= (rl_completion_func_t*)0;
...@@ -141,19 +140,9 @@ MACRO (MYSQL_FIND_SYSTEM_READLINE) ...@@ -141,19 +140,9 @@ MACRO (MYSQL_FIND_SYSTEM_READLINE)
}" }"
NEW_READLINE_INTERFACE) NEW_READLINE_INTERFACE)
CHECK_CXX_SOURCE_COMPILES("
#include <stdio.h>
#include <readline/readline.h>
int main(int argc, char **argv)
{
HIST_ENTRY entry;
return 0;
}"
HAVE_HIST_ENTRY)
CHECK_C_SOURCE_COMPILES(" CHECK_C_SOURCE_COMPILES("
#include <stdio.h> #include <stdio.h>
#include <readline/readline.h> #include <readline.h>
#if RL_VERSION_MAJOR > 5 #if RL_VERSION_MAJOR > 5
#error #error
#endif #endif
...@@ -176,30 +165,27 @@ MACRO (MYSQL_FIND_SYSTEM_READLINE) ...@@ -176,30 +165,27 @@ MACRO (MYSQL_FIND_SYSTEM_READLINE)
ENDIF(READLINE_V5) ENDIF(READLINE_V5)
ENDIF(NEW_READLINE_INTERFACE) ENDIF(NEW_READLINE_INTERFACE)
ENDIF() ENDIF()
SET(CMAKE_REQUIRES_LIBRARIES )
ENDMACRO() ENDMACRO()
MACRO (MYSQL_FIND_SYSTEM_LIBEDIT) MACRO (MYSQL_FIND_SYSTEM_LIBEDIT)
FIND_PATH(LIBEDIT_INCLUDE_DIR readline.h PATH_SUFFIXES editline edit/readline)
FIND_LIBRARY(LIBEDIT_LIBRARY edit)
MARK_AS_ADVANCED(LIBEDIT_INCLUDE_DIR LIBEDIT_LIBRARY)
FIND_PATH(READLINE_INCLUDE_DIR readline/readline.h ) IF(LIBEDIT_LIBRARY AND LIBEDIT_INCLUDE_DIR)
FIND_LIBRARY(READLINE_LIBRARY NAMES readline) SET(CMAKE_REQUIRED_LIBRARIES ${LIBEDIT_LIBRARY})
MARK_AS_ADVANCED(READLINE_INCLUDE_DIR READLINE_LIBRARY) SET(CMAKE_REQUIRED_INCLUDES ${LIBEDIT_INCLUDE_DIR})
SET(CMAKE_REQUIRES_LIBRARIES ${READLINE_LIBRARY})
IF(READLINE_LIBRARY AND READLINE_INCLUDE_DIR)
CHECK_CXX_SOURCE_COMPILES(" CHECK_CXX_SOURCE_COMPILES("
#include <stdio.h> #include <stdio.h>
#include <readline/readline.h> #include <readline.h>
int main(int argc, char **argv) int main(int argc, char **argv)
{ {
char res= *(*rl_completion_entry_function)(0,0); int res= (*rl_completion_entry_function)(0,0);
completion_matches(0,0); completion_matches(0,0);
}" }"
LIBEDIT_INTERFACE) LIBEDIT_INTERFACE)
SET(USE_LIBEDIT_INTERFACE ${LIBEDIT_INTERFACE}) SET(USE_LIBEDIT_INTERFACE ${LIBEDIT_INTERFACE})
ENDIF() ENDIF()
SET(CMAKE_REQUIRES_LIBRARIES)
ENDMACRO() ENDMACRO()
...@@ -216,15 +202,33 @@ MACRO (MYSQL_CHECK_READLINE) ...@@ -216,15 +202,33 @@ MACRO (MYSQL_CHECK_READLINE)
IF (NOT APPLE) IF (NOT APPLE)
MYSQL_FIND_SYSTEM_READLINE() MYSQL_FIND_SYSTEM_READLINE()
ENDIF() ENDIF()
IF(NOT USE_NEW_READLINE_INTERFACE) IF(USE_NEW_READLINE_INTERFACE)
SET(MY_READLINE_INCLUDE_DIR ${READLINE_INCLUDE_DIR})
SET(MY_READLINE_LIBRARY ${READLINE_LIBRARY} ${CURSES_LIBRARY})
ELSE()
MYSQL_FIND_SYSTEM_LIBEDIT() MYSQL_FIND_SYSTEM_LIBEDIT()
IF(NOT USE_LIBEDIT_INTERFACE) IF(USE_LIBEDIT_INTERFACE)
SET(MY_READLINE_INCLUDE_DIR ${LIBEDIT_INCLUDE_DIR})
SET(MY_READLINE_LIBRARY ${LIBEDIT_LIBRARY} ${CURSES_LIBRARY})
ELSE()
MYSQL_USE_BUNDLED_READLINE() MYSQL_USE_BUNDLED_READLINE()
ENDIF() ENDIF()
ENDIF() ENDIF()
ENDIF() ENDIF()
SET(MY_READLINE_INCLUDE_DIR ${READLINE_INCLUDE_DIR})
SET(MY_READLINE_LIBRARY ${READLINE_LIBRARY} ${CURSES_LIBRARY}) SET(CMAKE_REQUIRED_LIBRARIES ${MY_READLINE_LIBRARY})
SET(CMAKE_REQUIRED_INCLUDES ${MY_READLINE_INCLUDE_DIR})
CHECK_CXX_SOURCE_COMPILES("
#include <stdio.h>
#include <readline.h>
int main(int argc, char **argv)
{
HIST_ENTRY entry;
return 0;
}"
HAVE_HIST_ENTRY)
SET(CMAKE_REQUIRED_LIBRARIES)
SET(CMAKE_REQUIRED_INCLUDES)
ENDIF(NOT WIN32) ENDIF(NOT WIN32)
ENDMACRO() ENDMACRO()
...@@ -13,8 +13,7 @@ ...@@ -13,8 +13,7 @@
# along with this program; if not, write to the Free Software # along with this program; if not, write to the Free Software
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA # Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/include INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/include ${CMAKE_CURRENT_SOURCE_DIR})
${CMAKE_SOURCE_DIR}/cmd-line-utils)
ADD_DEFINITIONS(-DHAVE_CONFIG_H -DNO_KILL_INTR) ADD_DEFINITIONS(-DHAVE_CONFIG_H -DNO_KILL_INTR)
......
...@@ -32,8 +32,8 @@ extern "C" { ...@@ -32,8 +32,8 @@ extern "C" {
# include "rlstdc.h" # include "rlstdc.h"
# include "rltypedefs.h" # include "rltypedefs.h"
#else #else
# include <readline/rlstdc.h> # include <rlstdc.h>
# include <readline/rltypedefs.h> # include <rltypedefs.h>
#endif #endif
#ifdef __STDC__ #ifdef __STDC__
......
...@@ -32,9 +32,9 @@ extern "C" { ...@@ -32,9 +32,9 @@ extern "C" {
# include "chardefs.h" # include "chardefs.h"
# include "rltypedefs.h" # include "rltypedefs.h"
#else #else
# include <readline/rlstdc.h> # include <rlstdc.h>
# include <readline/chardefs.h> # include <chardefs.h>
# include <readline/rltypedefs.h> # include <rltypedefs.h>
#endif #endif
/* A keymap contains one entry for each key in the ASCII set. /* A keymap contains one entry for each key in the ASCII set.
......
...@@ -33,10 +33,10 @@ extern "C" { ...@@ -33,10 +33,10 @@ extern "C" {
# include "keymaps.h" # include "keymaps.h"
# include "tilde.h" # include "tilde.h"
#else #else
# include <readline/rlstdc.h> # include <rlstdc.h>
# include <readline/rltypedefs.h> # include <rltypedefs.h>
# include <readline/keymaps.h> # include <keymaps.h>
# include <readline/tilde.h> # include <tilde.h>
#endif #endif
/* Hex-encoded Readline version number. */ /* Hex-encoded Readline version number. */
......
...@@ -26,7 +26,7 @@ ...@@ -26,7 +26,7 @@
#if defined (READLINE_LIBRARY) #if defined (READLINE_LIBRARY)
# include "rlstdc.h" # include "rlstdc.h"
#else #else
# include <readline/rlstdc.h> # include <rlstdc.h>
#endif #endif
#ifndef PTR_T #ifndef PTR_T
......
...@@ -4,7 +4,7 @@ Priority: optional ...@@ -4,7 +4,7 @@ Priority: optional
Maintainer: MariaDB Developers <maria-developers@lists.launchpad.net> Maintainer: MariaDB Developers <maria-developers@lists.launchpad.net>
XSBC-Original-Maintainer: Maria Developers <maria-developers@lists.launchpad.net> XSBC-Original-Maintainer: Maria Developers <maria-developers@lists.launchpad.net>
Uploaders: MariaDB Developers <maria-developers@lists.launchpad.net> Uploaders: MariaDB Developers <maria-developers@lists.launchpad.net>
Build-Depends: libtool (>= 1.4.2-7), procps | hurd, debhelper, file (>= 3.28), libncurses5-dev (>= 5.0-6), perl (>= 5.6.0), libwrap0-dev (>= 7.6-8.3), zlib1g-dev (>= 1:1.1.3-5), ${LIBREADLINE_DEV}, libssl-dev, libpam0g-dev, psmisc, po-debconf, chrpath, automake1.9, doxygen, texlive-latex-base, ghostscript | gs-gpl, dpatch, gawk, bison, lsb-release, hardening-wrapper, ${CMAKE_DEP}libaio-dev Build-Depends: libtool (>= 1.4.2-7), procps | hurd, debhelper, file (>= 3.28), libncurses5-dev (>= 5.0-6), perl (>= 5.6.0), libwrap0-dev (>= 7.6-8.3), zlib1g-dev (>= 1:1.1.3-5), ${LIBREADLINE_DEV}, libssl-dev, libpam0g-dev, psmisc, po-debconf, chrpath, automake1.9, doxygen, texlive-latex-base, ghostscript | gs-gpl, dpatch, gawk, bison, lsb-release, hardening-wrapper, ${CMAKE_DEP}libaio-dev, libjemalloc-dev (>= 3.0.0)
Standards-Version: 3.8.3 Standards-Version: 3.8.3
Homepage: http://mariadb.org/ Homepage: http://mariadb.org/
Vcs-Browser: http://bazaar.launchpad.net/~maria-captains/maria/10.0/files Vcs-Browser: http://bazaar.launchpad.net/~maria-captains/maria/10.0/files
...@@ -147,7 +147,7 @@ Description: MariaDB database client binaries ...@@ -147,7 +147,7 @@ Description: MariaDB database client binaries
Package: mariadb-server-core-10.0 Package: mariadb-server-core-10.0
Architecture: any Architecture: any
Depends: ${shlibs:Depends}, ${misc:Depends}, libmariadbclient18 (>= ${binary:Version}) Depends: ${shlibs:Depends}, ${misc:Depends}, libmariadbclient18 (>= ${binary:Version}), libjemalloc1 (>= 3.0.0)
Provides: mysql-server-core, mysql-server-core-5.1, mysql-server-core-5.5 Provides: mysql-server-core, mysql-server-core-5.1, mysql-server-core-5.5
Conflicts: mariadb-server-5.1 (<< 5.1.60), Conflicts: mariadb-server-5.1 (<< 5.1.60),
mariadb-server-5.2 (<< 5.2.10), mariadb-server-5.2 (<< 5.2.10),
...@@ -192,7 +192,7 @@ Architecture: any ...@@ -192,7 +192,7 @@ Architecture: any
Suggests: tinyca, mailx, mariadb-test Suggests: tinyca, mailx, mariadb-test
Recommends: libhtml-template-perl Recommends: libhtml-template-perl
Pre-Depends: mariadb-common, adduser (>= 3.40), debconf Pre-Depends: mariadb-common, adduser (>= 3.40), debconf
Depends: mariadb-client-10.0 (>= ${source:Version}), libdbi-perl, perl (>= 5.6), ${shlibs:Depends}, ${misc:Depends}, psmisc, passwd, lsb-base (>= 3.0-10), mariadb-server-core-10.0 (>= ${binary:Version}) Depends: mariadb-client-10.0 (>= ${source:Version}), libdbi-perl, perl (>= 5.6), ${shlibs:Depends}, ${misc:Depends}, psmisc, passwd, lsb-base (>= 3.0-10), mariadb-server-core-10.0 (>= ${binary:Version}), libjemalloc1 (>= 3.0.0)
Provides: mariadb-server, mysql-server, virtual-mysql-server Provides: mariadb-server, mysql-server, virtual-mysql-server
Conflicts: mariadb-server (<< ${source:Version}), mysql-server (<< ${source:Version}), Conflicts: mariadb-server (<< ${source:Version}), mysql-server (<< ${source:Version}),
mysql-server-4.1, mysql-server-5.0, mysql-server-5.1, mysql-server-5.5, mysql-server-4.1, mysql-server-5.0, mysql-server-5.1, mysql-server-5.5,
......
...@@ -4,7 +4,7 @@ Priority: optional ...@@ -4,7 +4,7 @@ Priority: optional
Maintainer: MariaDB Developers <maria-developers@lists.launchpad.net> Maintainer: MariaDB Developers <maria-developers@lists.launchpad.net>
XSBC-Original-Maintainer: Maria Developers <maria-developers@lists.launchpad.net> XSBC-Original-Maintainer: Maria Developers <maria-developers@lists.launchpad.net>
Uploaders: MariaDB Developers <maria-developers@lists.launchpad.net> Uploaders: MariaDB Developers <maria-developers@lists.launchpad.net>
Build-Depends: libtool (>= 1.4.2-7), procps | hurd, debhelper, file (>= 3.28), libncurses5-dev (>= 5.0-6), perl (>= 5.6.0), libwrap0-dev (>= 7.6-8.3), zlib1g-dev (>= 1:1.1.3-5), ${LIBREADLINE_DEV}, libssl-dev, libpam0g-dev, psmisc, po-debconf, chrpath, automake1.9, doxygen, texlive-latex-base, ghostscript | gs-gpl, dpatch, gawk, bison, lsb-release, hardening-wrapper, ${CMAKE_DEP}libaio-dev Build-Depends: libtool (>= 1.4.2-7), procps | hurd, debhelper, file (>= 3.28), libncurses5-dev (>= 5.0-6), perl (>= 5.6.0), libwrap0-dev (>= 7.6-8.3), zlib1g-dev (>= 1:1.1.3-5), ${LIBREADLINE_DEV}, libssl-dev, libpam0g-dev, psmisc, po-debconf, chrpath, automake1.9, doxygen, texlive-latex-base, ghostscript | gs-gpl, dpatch, gawk, bison, lsb-release, hardening-wrapper, ${CMAKE_DEP}libaio-dev, libjemalloc-dev (>= 3.0.0)
Standards-Version: 3.8.2 Standards-Version: 3.8.2
Homepage: http://mariadb.org/ Homepage: http://mariadb.org/
Vcs-Browser: http://bazaar.launchpad.net/~maria-captains/maria/10.0/files Vcs-Browser: http://bazaar.launchpad.net/~maria-captains/maria/10.0/files
...@@ -147,7 +147,7 @@ Description: MariaDB database client binaries ...@@ -147,7 +147,7 @@ Description: MariaDB database client binaries
Package: mariadb-server-core-10.0 Package: mariadb-server-core-10.0
Architecture: any Architecture: any
Depends: ${shlibs:Depends}, ${misc:Depends}, libmariadbclient18 (>= ${binary:Version}) Depends: ${shlibs:Depends}, ${misc:Depends}, libmariadbclient18 (>= ${binary:Version}), libjemalloc1 (>= 3.0.0)
Provides: mysql-server-core, mysql-server-core-5.1, mysql-server-core-5.5 Provides: mysql-server-core, mysql-server-core-5.1, mysql-server-core-5.5
Conflicts: mysql-server-5.0, Conflicts: mysql-server-5.0,
mysql-server-core-5.0, mysql-server-core-5.1, mysql-server-core-5.5, mysql-server-core-5.0, mysql-server-core-5.1, mysql-server-core-5.5,
...@@ -186,7 +186,7 @@ Architecture: any ...@@ -186,7 +186,7 @@ Architecture: any
Suggests: tinyca, mailx, mariadb-test Suggests: tinyca, mailx, mariadb-test
Recommends: libhtml-template-perl Recommends: libhtml-template-perl
Pre-Depends: mariadb-common, adduser (>= 3.40), debconf Pre-Depends: mariadb-common, adduser (>= 3.40), debconf
Depends: mariadb-client-10.0 (>= ${source:Version}), libdbi-perl, perl (>= 5.6), ${shlibs:Depends}, ${misc:Depends}, psmisc, passwd, lsb-base (>= 3.0-10), mariadb-server-core-10.0 (>= ${binary:Version}) Depends: mariadb-client-10.0 (>= ${source:Version}), libdbi-perl, perl (>= 5.6), ${shlibs:Depends}, ${misc:Depends}, psmisc, passwd, lsb-base (>= 3.0-10), mariadb-server-core-10.0 (>= ${binary:Version}), libjemalloc1 (>= 3.0.0)
Provides: mariadb-server, mysql-server, virtual-mysql-server Provides: mariadb-server, mysql-server, virtual-mysql-server
Conflicts: mariadb-server (<< ${source:Version}), mysql-server (<< ${source:Version}), Conflicts: mariadb-server (<< ${source:Version}), mysql-server (<< ${source:Version}),
mysql-server-4.1, mysql-server-5.0, mysql-server-5.1, mysql-server-5.5, mysql-server-4.1, mysql-server-5.0, mysql-server-5.1, mysql-server-5.5,
......
Unless otherwise specified, files in the jemalloc source distribution are
subject to the following license:
--------------------------------------------------------------------------------
Copyright (C) 2002-2013 Jason Evans <jasone@canonware.com>.
All rights reserved.
Copyright (C) 2007-2012 Mozilla Foundation. All rights reserved.
Copyright (C) 2009-2013 Facebook, Inc. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
1. Redistributions of source code must retain the above copyright notice(s),
this list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright notice(s),
this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER(S) ``AS IS'' AND ANY EXPRESS
OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
EVENT SHALL THE COPYRIGHT HOLDER(S) BE LIABLE FOR ANY DIRECT, INDIRECT,
INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
--------------------------------------------------------------------------------
This diff is collapsed.
This diff is collapsed.
# Clear out all vpaths, then set just one (default vpath) for the main build
# directory.
vpath
vpath % .
# Clear the default suffixes, so that built-in rules are not used.
.SUFFIXES :
SHELL := /bin/sh
CC := @CC@
# Configuration parameters.
DESTDIR =
BINDIR := $(DESTDIR)@BINDIR@
INCLUDEDIR := $(DESTDIR)@INCLUDEDIR@
LIBDIR := $(DESTDIR)@LIBDIR@
DATADIR := $(DESTDIR)@DATADIR@
MANDIR := $(DESTDIR)@MANDIR@
srcroot := @srcroot@
objroot := @objroot@
abs_srcroot := @abs_srcroot@
abs_objroot := @abs_objroot@
# Build parameters.
CPPFLAGS := @CPPFLAGS@ -I$(srcroot)include -I$(objroot)include
CFLAGS := @CFLAGS@
LDFLAGS := @LDFLAGS@
EXTRA_LDFLAGS := @EXTRA_LDFLAGS@
LIBS := @LIBS@
RPATH_EXTRA := @RPATH_EXTRA@
SO := @so@
IMPORTLIB := @importlib@
O := @o@
A := @a@
EXE := @exe@
LIBPREFIX := @libprefix@
REV := @rev@
install_suffix := @install_suffix@
ABI := @abi@
XSLTPROC := @XSLTPROC@
AUTOCONF := @AUTOCONF@
_RPATH = @RPATH@
RPATH = $(if $(1),$(call _RPATH,$(1)))
cfghdrs_in := @cfghdrs_in@
cfghdrs_out := @cfghdrs_out@
cfgoutputs_in := @cfgoutputs_in@
cfgoutputs_out := @cfgoutputs_out@
enable_autogen := @enable_autogen@
enable_experimental := @enable_experimental@
enable_zone_allocator := @enable_zone_allocator@
DSO_LDFLAGS = @DSO_LDFLAGS@
SOREV = @SOREV@
PIC_CFLAGS = @PIC_CFLAGS@
CTARGET = @CTARGET@
LDTARGET = @LDTARGET@
MKLIB = @MKLIB@
CC_MM = @CC_MM@
ifeq (macho, $(ABI))
TEST_LIBRARY_PATH := DYLD_FALLBACK_LIBRARY_PATH="$(objroot)lib"
else
ifeq (pecoff, $(ABI))
TEST_LIBRARY_PATH := PATH="$(PATH):$(objroot)lib"
else
TEST_LIBRARY_PATH :=
endif
endif
LIBJEMALLOC := $(LIBPREFIX)jemalloc$(install_suffix)
# Lists of files.
BINS := $(srcroot)bin/pprof $(objroot)bin/jemalloc.sh
CHDRS := $(objroot)include/jemalloc/jemalloc$(install_suffix).h \
$(objroot)include/jemalloc/jemalloc_defs$(install_suffix).h
CSRCS := $(srcroot)src/jemalloc.c $(srcroot)src/arena.c $(srcroot)src/atomic.c \
$(srcroot)src/base.c $(srcroot)src/bitmap.c $(srcroot)src/chunk.c \
$(srcroot)src/chunk_dss.c $(srcroot)src/chunk_mmap.c \
$(srcroot)src/ckh.c $(srcroot)src/ctl.c $(srcroot)src/extent.c \
$(srcroot)src/hash.c $(srcroot)src/huge.c $(srcroot)src/mb.c \
$(srcroot)src/mutex.c $(srcroot)src/prof.c $(srcroot)src/quarantine.c \
$(srcroot)src/rtree.c $(srcroot)src/stats.c $(srcroot)src/tcache.c \
$(srcroot)src/util.c $(srcroot)src/tsd.c
ifeq ($(enable_zone_allocator), 1)
CSRCS += $(srcroot)src/zone.c
endif
ifeq ($(IMPORTLIB),$(SO))
STATIC_LIBS := $(objroot)lib/$(LIBJEMALLOC).$(A)
endif
ifdef PIC_CFLAGS
STATIC_LIBS += $(objroot)lib/$(LIBJEMALLOC)_pic.$(A)
else
STATIC_LIBS += $(objroot)lib/$(LIBJEMALLOC)_s.$(A)
endif
DSOS := $(objroot)lib/$(LIBJEMALLOC).$(SOREV)
ifneq ($(SOREV),$(SO))
DSOS += $(objroot)lib/$(LIBJEMALLOC).$(SO)
endif
MAN3 := $(objroot)doc/jemalloc$(install_suffix).3
DOCS_XML := $(objroot)doc/jemalloc$(install_suffix).xml
DOCS_HTML := $(DOCS_XML:$(objroot)%.xml=$(srcroot)%.html)
DOCS_MAN3 := $(DOCS_XML:$(objroot)%.xml=$(srcroot)%.3)
DOCS := $(DOCS_HTML) $(DOCS_MAN3)
CTESTS := $(srcroot)test/aligned_alloc.c $(srcroot)test/allocated.c \
$(srcroot)test/ALLOCM_ARENA.c $(srcroot)test/bitmap.c \
$(srcroot)test/mremap.c $(srcroot)test/posix_memalign.c \
$(srcroot)test/thread_arena.c $(srcroot)test/thread_tcache_enabled.c
ifeq ($(enable_experimental), 1)
CTESTS += $(srcroot)test/allocm.c $(srcroot)test/rallocm.c
endif
COBJS := $(CSRCS:$(srcroot)%.c=$(objroot)%.$(O))
CPICOBJS := $(CSRCS:$(srcroot)%.c=$(objroot)%.pic.$(O))
CTESTOBJS := $(CTESTS:$(srcroot)%.c=$(objroot)%.$(O))
.PHONY: all dist build_doc_html build_doc_man build_doc
.PHONY: install_bin install_include install_lib
.PHONY: install_doc_html install_doc_man install_doc install
.PHONY: tests check clean distclean relclean
.SECONDARY : $(CTESTOBJS)
# Default target.
all: build
dist: build_doc
$(srcroot)doc/%.html : $(objroot)doc/%.xml $(srcroot)doc/stylesheet.xsl $(objroot)doc/html.xsl
$(XSLTPROC) -o $@ $(objroot)doc/html.xsl $<
$(srcroot)doc/%.3 : $(objroot)doc/%.xml $(srcroot)doc/stylesheet.xsl $(objroot)doc/manpages.xsl
$(XSLTPROC) -o $@ $(objroot)doc/manpages.xsl $<
build_doc_html: $(DOCS_HTML)
build_doc_man: $(DOCS_MAN3)
build_doc: $(DOCS)
#
# Include generated dependency files.
#
ifdef CC_MM
-include $(COBJS:%.$(O)=%.d)
-include $(CPICOBJS:%.$(O)=%.d)
-include $(CTESTOBJS:%.$(O)=%.d)
endif
$(COBJS): $(objroot)src/%.$(O): $(srcroot)src/%.c
$(CPICOBJS): $(objroot)src/%.pic.$(O): $(srcroot)src/%.c
$(CPICOBJS): CFLAGS += $(PIC_CFLAGS)
$(CTESTOBJS): $(objroot)test/%.$(O): $(srcroot)test/%.c
$(CTESTOBJS): CPPFLAGS += -I$(objroot)test
ifneq ($(IMPORTLIB),$(SO))
$(COBJS): CPPFLAGS += -DDLLEXPORT
endif
ifndef CC_MM
# Dependencies
HEADER_DIRS = $(srcroot)include/jemalloc/internal \
$(objroot)include/jemalloc $(objroot)include/jemalloc/internal
HEADERS = $(wildcard $(foreach dir,$(HEADER_DIRS),$(dir)/*.h))
$(COBJS) $(CPICOBJS) $(CTESTOBJS): $(HEADERS)
$(CTESTOBJS): $(objroot)test/jemalloc_test.h
endif
$(COBJS) $(CPICOBJS) $(CTESTOBJS): %.$(O):
@mkdir -p $(@D)
$(CC) $(CFLAGS) -c $(CPPFLAGS) $(CTARGET) $<
ifdef CC_MM
@$(CC) -MM $(CPPFLAGS) -MT $@ -o $(@:%.$(O)=%.d) $<
endif
ifneq ($(SOREV),$(SO))
%.$(SO) : %.$(SOREV)
@mkdir -p $(@D)
ln -sf $(<F) $@
endif
$(objroot)lib/$(LIBJEMALLOC).$(SOREV) : $(if $(PIC_CFLAGS),$(CPICOBJS),$(COBJS))
@mkdir -p $(@D)
$(CC) $(DSO_LDFLAGS) $(call RPATH,$(RPATH_EXTRA)) $(LDTARGET) $+ $(LDFLAGS) $(LIBS) $(EXTRA_LDFLAGS)
$(objroot)lib/$(LIBJEMALLOC)_pic.$(A) : $(CPICOBJS)
$(objroot)lib/$(LIBJEMALLOC).$(A) : $(COBJS)
$(objroot)lib/$(LIBJEMALLOC)_s.$(A) : $(COBJS)
$(STATIC_LIBS):
@mkdir -p $(@D)
$(MKLIB) $+
$(objroot)test/bitmap$(EXE): $(objroot)src/bitmap.$(O)
$(objroot)test/%$(EXE): $(objroot)test/%.$(O) $(objroot)src/util.$(O) $(DSOS)
@mkdir -p $(@D)
$(CC) $(LDTARGET) $(filter %.$(O),$^) $(call RPATH,$(objroot)lib) $(objroot)lib/$(LIBJEMALLOC).$(IMPORTLIB) $(filter -lpthread,$(LIBS)) $(EXTRA_LDFLAGS)
build_lib_shared: $(DSOS)
build_lib_static: $(STATIC_LIBS)
build: build_lib_shared build_lib_static
install_bin:
install -d $(BINDIR)
@for b in $(BINS); do \
echo "install -m 755 $$b $(BINDIR)"; \
install -m 755 $$b $(BINDIR); \
done
install_include:
install -d $(INCLUDEDIR)/jemalloc
@for h in $(CHDRS); do \
echo "install -m 644 $$h $(INCLUDEDIR)/jemalloc"; \
install -m 644 $$h $(INCLUDEDIR)/jemalloc; \
done
install_lib_shared: $(DSOS)
install -d $(LIBDIR)
install -m 755 $(objroot)lib/$(LIBJEMALLOC).$(SOREV) $(LIBDIR)
ifneq ($(SOREV),$(SO))
ln -sf $(LIBJEMALLOC).$(SOREV) $(LIBDIR)/$(LIBJEMALLOC).$(SO)
endif
install_lib_static: $(STATIC_LIBS)
install -d $(LIBDIR)
@for l in $(STATIC_LIBS); do \
echo "install -m 755 $$l $(LIBDIR)"; \
install -m 755 $$l $(LIBDIR); \
done
install_lib: install_lib_shared install_lib_static
install_doc_html:
install -d $(DATADIR)/doc/jemalloc$(install_suffix)
@for d in $(DOCS_HTML); do \
echo "install -m 644 $$d $(DATADIR)/doc/jemalloc$(install_suffix)"; \
install -m 644 $$d $(DATADIR)/doc/jemalloc$(install_suffix); \
done
install_doc_man:
install -d $(MANDIR)/man3
@for d in $(DOCS_MAN3); do \
echo "install -m 644 $$d $(MANDIR)/man3"; \
install -m 644 $$d $(MANDIR)/man3; \
done
install_doc: install_doc_html install_doc_man
install: install_bin install_include install_lib install_doc
tests: $(CTESTS:$(srcroot)%.c=$(objroot)%$(EXE))
check: tests
@mkdir -p $(objroot)test
@$(SHELL) -c 'total=0; \
failures=0; \
echo "========================================="; \
for t in $(CTESTS:$(srcroot)%.c=$(objroot)%); do \
total=`expr $$total + 1`; \
/bin/echo -n "$${t} ... "; \
$(TEST_LIBRARY_PATH) $${t}$(EXE) $(abs_srcroot) \
$(abs_objroot) > $(objroot)$${t}.out 2>&1; \
if test -e "$(srcroot)$${t}.exp"; then \
diff -w -u $(srcroot)$${t}.exp \
$(objroot)$${t}.out >/dev/null 2>&1; \
fail=$$?; \
if test "$${fail}" -eq "1" ; then \
failures=`expr $${failures} + 1`; \
echo "*** FAIL ***"; \
else \
echo "pass"; \
fi; \
else \
echo "*** FAIL *** (.exp file is missing)"; \
failures=`expr $${failures} + 1`; \
fi; \
done; \
echo "========================================="; \
echo "Failures: $${failures}/$${total}"'
clean:
rm -f $(COBJS)
rm -f $(CPICOBJS)
rm -f $(COBJS:%.$(O)=%.d)
rm -f $(CPICOBJS:%.$(O)=%.d)
rm -f $(CTESTOBJS:%.$(O)=%$(EXE))
rm -f $(CTESTOBJS)
rm -f $(CTESTOBJS:%.$(O)=%.d)
rm -f $(CTESTOBJS:%.$(O)=%.out)
rm -f $(DSOS) $(STATIC_LIBS)
distclean: clean
rm -rf $(objroot)autom4te.cache
rm -f $(objroot)config.log
rm -f $(objroot)config.status
rm -f $(objroot)config.stamp
rm -f $(cfghdrs_out)
rm -f $(cfgoutputs_out)
relclean: distclean
rm -f $(objroot)configure
rm -f $(srcroot)VERSION
rm -f $(DOCS_HTML)
rm -f $(DOCS_MAN3)
#===============================================================================
# Re-configuration rules.
ifeq ($(enable_autogen), 1)
$(srcroot)configure : $(srcroot)configure.ac
cd ./$(srcroot) && $(AUTOCONF)
$(objroot)config.status : $(srcroot)configure
./$(objroot)config.status --recheck
$(srcroot)config.stamp.in : $(srcroot)configure.ac
echo stamp > $(srcroot)config.stamp.in
$(objroot)config.stamp : $(cfgoutputs_in) $(cfghdrs_in) $(srcroot)configure
./$(objroot)config.status
@touch $@
# There must be some action in order for make to re-read Makefile when it is
# out of date.
$(cfgoutputs_out) $(cfghdrs_out) : $(objroot)config.stamp
@true
endif
jemalloc is a general-purpose scalable concurrent malloc(3) implementation.
This distribution is a "portable" implementation that currently targets
FreeBSD, Linux, Apple OS X, and MinGW. jemalloc is included as the default
allocator in the FreeBSD and NetBSD operating systems, and it is used by the
Mozilla Firefox web browser on Microsoft Windows-related platforms. Depending
on your needs, one of the other divergent versions may suit your needs better
than this distribution.
The COPYING file contains copyright and licensing information.
The INSTALL file contains information on how to configure, build, and install
jemalloc.
The ChangeLog file contains a brief summary of changes for each release.
URL: http://www.canonware.com/jemalloc/
3.3.1-0-g9ef9d9e8c271cdf14f664b871a8f98c827714784
#!/bin/sh
for i in autoconf; do
echo "$i"
$i
if [ $? -ne 0 ]; then
echo "Error $? in $i"
exit 1
fi
done
echo "./configure --enable-autogen $@"
./configure --enable-autogen $@
if [ $? -ne 0 ]; then
echo "Error $? in ./configure"
exit 1
fi
#!/bin/sh
prefix=/usr/local
exec_prefix=/usr/local
libdir=${exec_prefix}/lib
LD_PRELOAD=${libdir}/libjemalloc.so.1
export LD_PRELOAD
exec "$@"
#!/bin/sh
prefix=@prefix@
exec_prefix=@exec_prefix@
libdir=@libdir@
@LD_PRELOAD_VAR@=${libdir}/libjemalloc.@SOREV@
export @LD_PRELOAD_VAR@
exec "$@"
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
<xsl:import href="@XSLROOT@/html/docbook.xsl"/>
<xsl:import href="@abs_srcroot@doc/stylesheet.xsl"/>
</xsl:stylesheet>
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
<xsl:import href="@XSLROOT@/manpages/docbook.xsl"/>
<xsl:import href="@abs_srcroot@doc/stylesheet.xsl"/>
</xsl:stylesheet>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
<xsl:param name="funcsynopsis.style">ansi</xsl:param>
<xsl:param name="function.parens" select="1"/>
<xsl:template match="mallctl">
"<xsl:call-template name="inline.monoseq"/>"
</xsl:template>
</xsl:stylesheet>
This diff is collapsed.
This diff is collapsed.
/******************************************************************************/
#ifdef JEMALLOC_H_TYPES
#endif /* JEMALLOC_H_TYPES */
/******************************************************************************/
#ifdef JEMALLOC_H_STRUCTS
#endif /* JEMALLOC_H_STRUCTS */
/******************************************************************************/
#ifdef JEMALLOC_H_EXTERNS
void *base_alloc(size_t size);
void *base_calloc(size_t number, size_t size);
extent_node_t *base_node_alloc(void);
void base_node_dealloc(extent_node_t *node);
bool base_boot(void);
void base_prefork(void);
void base_postfork_parent(void);
void base_postfork_child(void);
#endif /* JEMALLOC_H_EXTERNS */
/******************************************************************************/
#ifdef JEMALLOC_H_INLINES
#endif /* JEMALLOC_H_INLINES */
/******************************************************************************/
This diff is collapsed.
/******************************************************************************/
#ifdef JEMALLOC_H_TYPES
/*
* Size and alignment of memory chunks that are allocated by the OS's virtual
* memory system.
*/
#define LG_CHUNK_DEFAULT 22
/* Return the chunk address for allocation address a. */
#define CHUNK_ADDR2BASE(a) \
((void *)((uintptr_t)(a) & ~chunksize_mask))
/* Return the chunk offset of address a. */
#define CHUNK_ADDR2OFFSET(a) \
((size_t)((uintptr_t)(a) & chunksize_mask))
/* Return the smallest chunk multiple that is >= s. */
#define CHUNK_CEILING(s) \
(((s) + chunksize_mask) & ~chunksize_mask)
#endif /* JEMALLOC_H_TYPES */
/******************************************************************************/
#ifdef JEMALLOC_H_STRUCTS
#endif /* JEMALLOC_H_STRUCTS */
/******************************************************************************/
#ifdef JEMALLOC_H_EXTERNS
extern size_t opt_lg_chunk;
extern const char *opt_dss;
/* Protects stats_chunks; currently not used for any other purpose. */
extern malloc_mutex_t chunks_mtx;
/* Chunk statistics. */
extern chunk_stats_t stats_chunks;
extern rtree_t *chunks_rtree;
extern size_t chunksize;
extern size_t chunksize_mask; /* (chunksize - 1). */
extern size_t chunk_npages;
extern size_t map_bias; /* Number of arena chunk header pages. */
extern size_t arena_maxclass; /* Max size class for arenas. */
void *chunk_alloc(size_t size, size_t alignment, bool base, bool *zero,
dss_prec_t dss_prec);
void chunk_unmap(void *chunk, size_t size);
void chunk_dealloc(void *chunk, size_t size, bool unmap);
bool chunk_boot(void);
void chunk_prefork(void);
void chunk_postfork_parent(void);
void chunk_postfork_child(void);
#endif /* JEMALLOC_H_EXTERNS */
/******************************************************************************/
#ifdef JEMALLOC_H_INLINES
#endif /* JEMALLOC_H_INLINES */
/******************************************************************************/
#include "jemalloc/internal/chunk_dss.h"
#include "jemalloc/internal/chunk_mmap.h"
/******************************************************************************/
#ifdef JEMALLOC_H_TYPES
typedef enum {
dss_prec_disabled = 0,
dss_prec_primary = 1,
dss_prec_secondary = 2,
dss_prec_limit = 3
} dss_prec_t ;
#define DSS_PREC_DEFAULT dss_prec_secondary
#define DSS_DEFAULT "secondary"
#endif /* JEMALLOC_H_TYPES */
/******************************************************************************/
#ifdef JEMALLOC_H_STRUCTS
extern const char *dss_prec_names[];
#endif /* JEMALLOC_H_STRUCTS */
/******************************************************************************/
#ifdef JEMALLOC_H_EXTERNS
dss_prec_t chunk_dss_prec_get(void);
bool chunk_dss_prec_set(dss_prec_t dss_prec);
void *chunk_alloc_dss(size_t size, size_t alignment, bool *zero);
bool chunk_in_dss(void *chunk);
bool chunk_dss_boot(void);
void chunk_dss_prefork(void);
void chunk_dss_postfork_parent(void);
void chunk_dss_postfork_child(void);
#endif /* JEMALLOC_H_EXTERNS */
/******************************************************************************/
#ifdef JEMALLOC_H_INLINES
#endif /* JEMALLOC_H_INLINES */
/******************************************************************************/
/******************************************************************************/
#ifdef JEMALLOC_H_TYPES
#endif /* JEMALLOC_H_TYPES */
/******************************************************************************/
#ifdef JEMALLOC_H_STRUCTS
#endif /* JEMALLOC_H_STRUCTS */
/******************************************************************************/
#ifdef JEMALLOC_H_EXTERNS
bool pages_purge(void *addr, size_t length);
void *chunk_alloc_mmap(size_t size, size_t alignment, bool *zero);
bool chunk_dealloc_mmap(void *chunk, size_t size);
#endif /* JEMALLOC_H_EXTERNS */
/******************************************************************************/
#ifdef JEMALLOC_H_INLINES
#endif /* JEMALLOC_H_INLINES */
/******************************************************************************/
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
/******************************************************************************/
#ifdef JEMALLOC_H_TYPES
#endif /* JEMALLOC_H_TYPES */
/******************************************************************************/
#ifdef JEMALLOC_H_STRUCTS
#endif /* JEMALLOC_H_STRUCTS */
/******************************************************************************/
#ifdef JEMALLOC_H_EXTERNS
/* Huge allocation statistics. */
extern uint64_t huge_nmalloc;
extern uint64_t huge_ndalloc;
extern size_t huge_allocated;
/* Protects chunk-related data structures. */
extern malloc_mutex_t huge_mtx;
void *huge_malloc(size_t size, bool zero);
void *huge_palloc(size_t size, size_t alignment, bool zero);
void *huge_ralloc_no_move(void *ptr, size_t oldsize, size_t size,
size_t extra);
void *huge_ralloc(void *ptr, size_t oldsize, size_t size, size_t extra,
size_t alignment, bool zero, bool try_tcache_dalloc);
void huge_dalloc(void *ptr, bool unmap);
size_t huge_salloc(const void *ptr);
prof_ctx_t *huge_prof_ctx_get(const void *ptr);
void huge_prof_ctx_set(const void *ptr, prof_ctx_t *ctx);
bool huge_boot(void);
void huge_prefork(void);
void huge_postfork_parent(void);
void huge_postfork_child(void);
#endif /* JEMALLOC_H_EXTERNS */
/******************************************************************************/
#ifdef JEMALLOC_H_INLINES
#endif /* JEMALLOC_H_INLINES */
/******************************************************************************/
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
#define JEMALLOC_ATOMIC_C_
#include "jemalloc/internal/jemalloc_internal.h"
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
#define JEMALLOC_HASH_C_
#include "jemalloc/internal/jemalloc_internal.h"
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
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