summaryrefslogtreecommitdiff
path: root/innobase
diff options
context:
space:
mode:
authorunknown <marko@hundin.mysql.fi>2005-06-13 11:39:31 +0300
committerunknown <marko@hundin.mysql.fi>2005-06-13 11:39:31 +0300
commit59332c86c005227b0e85423a5dcfb594a2738dcf (patch)
tree0f1127c870e3338a55d3e411098bc50e6161374d /innobase
parentf6da55d8ceb1ca731c7d5aeba11f7b858f253b30 (diff)
downloadmariadb-git-59332c86c005227b0e85423a5dcfb594a2738dcf.tar.gz
InnoDB: Remove unreferenced debug functions from non-debug builds.
innobase/buf/buf0buf.c: Remove buf_print() and buf_validate() unless #ifdef UNIV_DEBUG innobase/buf/buf0lru.c: Remove buf_LRU_print() and buf_LRU_validate() unless #ifdef UNIV_DEBUG innobase/include/buf0buf.h: Remove buf_print() and buf_validate() unless #ifdef UNIV_DEBUG innobase/include/buf0lru.h: Remove buf_LRU_print() and buf_LRU_validate() unless #ifdef UNIV_DEBUG innobase/include/rem0rec.h: rec_offs_comp(): Correct the comment about return value.
Diffstat (limited to 'innobase')
-rw-r--r--innobase/buf/buf0buf.c2
-rw-r--r--innobase/buf/buf0lru.c4
-rw-r--r--innobase/include/buf0buf.h14
-rw-r--r--innobase/include/buf0lru.h2
-rw-r--r--innobase/include/rem0rec.h2
5 files changed, 16 insertions, 8 deletions
diff --git a/innobase/buf/buf0buf.c b/innobase/buf/buf0buf.c
index fca0b9f85f8..84d1510581c 100644
--- a/innobase/buf/buf0buf.c
+++ b/innobase/buf/buf0buf.c
@@ -1947,6 +1947,7 @@ buf_pool_invalidate(void)
mutex_exit(&(buf_pool->mutex));
}
+#ifdef UNIV_DEBUG
/*************************************************************************
Validates the buffer buf_pool data structure. */
@@ -2146,6 +2147,7 @@ buf_print(void)
ut_a(buf_validate());
}
+#endif /* UNIV_DEBUG */
/*************************************************************************
Returns the number of latched pages in the buffer pool. */
diff --git a/innobase/buf/buf0lru.c b/innobase/buf/buf0lru.c
index 18c4f8c10fb..0a195b6162f 100644
--- a/innobase/buf/buf0lru.c
+++ b/innobase/buf/buf0lru.c
@@ -919,7 +919,8 @@ buf_LRU_block_free_hashed_page(
buf_LRU_block_free_non_file_page(block);
}
-
+
+#ifdef UNIV_DEBUG
/**************************************************************************
Validates the LRU list. */
@@ -1050,3 +1051,4 @@ buf_LRU_print(void)
mutex_exit(&(buf_pool->mutex));
}
+#endif /* UNIV_DEBUG */
diff --git a/innobase/include/buf0buf.h b/innobase/include/buf0buf.h
index 7b8e1b7bb09..81170226171 100644
--- a/innobase/include/buf0buf.h
+++ b/innobase/include/buf0buf.h
@@ -480,12 +480,20 @@ buf_pool_is_block(
/*==============*/
/* out: TRUE if pointer to block */
void* ptr); /* in: pointer to memory */
+#ifdef UNIV_DEBUG
/*************************************************************************
Validates the buffer pool data structure. */
ibool
buf_validate(void);
/*==============*/
+/*************************************************************************
+Prints info of the buffer pool data structure. */
+
+void
+buf_print(void);
+/*============*/
+#endif /* UNIV_DEBUG */
/************************************************************************
Prints a page to stderr. */
@@ -494,12 +502,6 @@ buf_page_print(
/*===========*/
byte* read_buf); /* in: a database page */
/*************************************************************************
-Prints info of the buffer pool data structure. */
-
-void
-buf_print(void);
-/*============*/
-/*************************************************************************
Returns the number of latched pages in the buffer pool. */
ulint
diff --git a/innobase/include/buf0lru.h b/innobase/include/buf0lru.h
index 45164dd561e..fb29b44ba98 100644
--- a/innobase/include/buf0lru.h
+++ b/innobase/include/buf0lru.h
@@ -122,6 +122,7 @@ void
buf_LRU_make_block_old(
/*===================*/
buf_block_t* block); /* in: control block */
+#ifdef UNIV_DEBUG
/**************************************************************************
Validates the LRU list. */
@@ -134,6 +135,7 @@ Prints the LRU list. */
void
buf_LRU_print(void);
/*===============*/
+#endif /* UNIV_DEBUG */
#ifndef UNIV_NONINL
#include "buf0lru.ic"
diff --git a/innobase/include/rem0rec.h b/innobase/include/rem0rec.h
index 0e9ab49f363..c068f4cb73c 100644
--- a/innobase/include/rem0rec.h
+++ b/innobase/include/rem0rec.h
@@ -300,7 +300,7 @@ UNIV_INLINE
ulint
rec_offs_comp(
/*==========*/
- /* out: TRUE if compact format */
+ /* out: nonzero if compact format */
const ulint* offsets);/* in: array returned by rec_get_offsets() */
/**********************************************************
Returns nonzero if the extern bit is set in nth field of rec. */