Commit bb6ea0c0 authored by marko's avatar marko

branches/zip: Clean up things found in an inlined build.

buf0lru.c: Always #include "srv0srv.h"

buf_block_get_lock_mutex(), buf_frame_get_lock_mutex(): Remove.

mtr0log.ic: Remove #include "page0page.h" and replace the page_
functions with lower-level ones to break an #include cycle.

dict0dict.ic: Remove unnecessary #include "trx0undo.h" and "trx0sys.h"
that would create an #include cycle.
parent 0d6c2414
...@@ -10,7 +10,6 @@ Created 11/5/1995 Heikki Tuuri ...@@ -10,7 +10,6 @@ Created 11/5/1995 Heikki Tuuri
#ifdef UNIV_NONINL #ifdef UNIV_NONINL
#include "buf0lru.ic" #include "buf0lru.ic"
#include "srv0srv.h" /* Needed to getsrv_print_innodb_monitor */
#endif #endif
#include "ut0byte.h" #include "ut0byte.h"
...@@ -28,6 +27,7 @@ Created 11/5/1995 Heikki Tuuri ...@@ -28,6 +27,7 @@ Created 11/5/1995 Heikki Tuuri
#include "btr0sea.h" #include "btr0sea.h"
#include "os0file.h" #include "os0file.h"
#include "log0recv.h" #include "log0recv.h"
#include "srv0srv.h"
/* The number of blocks from the LRU_old pointer onward, including the block /* The number of blocks from the LRU_old pointer onward, including the block
pointed to, must be 3/8 of the whole LRU list length, except that the pointed to, must be 3/8 of the whole LRU list length, except that the
......
...@@ -440,16 +440,6 @@ buf_block_get_lock_hash_val( ...@@ -440,16 +440,6 @@ buf_block_get_lock_hash_val(
/* out: lock hash value */ /* out: lock hash value */
const buf_block_t* block) /* in: block */ const buf_block_t* block) /* in: block */
__attribute__((const)); __attribute__((const));
/**************************************************************************
Gets the mutex number protecting the page record lock hash chain in the lock
table. */
UNIV_INLINE
mutex_t*
buf_block_get_lock_mutex(
/*=====================*/
/* out: mutex */
buf_block_t* block) /* in: block */
__attribute__((const));
/*********************************************************************** /***********************************************************************
Checks if a pointer points to the block array of the buffer pool (blocks, not Checks if a pointer points to the block array of the buffer pool (blocks, not
the frames). */ the frames). */
......
...@@ -308,19 +308,6 @@ buf_block_get_lock_hash_val( ...@@ -308,19 +308,6 @@ buf_block_get_lock_hash_val(
return(block->lock_hash_val); return(block->lock_hash_val);
} }
/**************************************************************************
Gets the mutex number protecting the page record lock hash chain in the lock
table. */
UNIV_INLINE
mutex_t*
buf_frame_get_lock_mutex(
/*=====================*/
/* out: mutex */
buf_block_t* block) /* in: block */
{
return(block->lock_mutex);
}
/************************************************************************ /************************************************************************
Allocates a buffer block. */ Allocates a buffer block. */
UNIV_INLINE UNIV_INLINE
......
...@@ -7,8 +7,6 @@ Created 1/8/1996 Heikki Tuuri ...@@ -7,8 +7,6 @@ Created 1/8/1996 Heikki Tuuri
***********************************************************************/ ***********************************************************************/
#include "dict0load.h" #include "dict0load.h"
#include "trx0undo.h"
#include "trx0sys.h"
#include "rem0types.h" #include "rem0types.h"
#include "data0type.h" #include "data0type.h"
......
...@@ -9,7 +9,6 @@ Created 12/7/1995 Heikki Tuuri ...@@ -9,7 +9,6 @@ Created 12/7/1995 Heikki Tuuri
#include "mach0data.h" #include "mach0data.h"
#include "ut0lst.h" #include "ut0lst.h"
#include "buf0buf.h" #include "buf0buf.h"
#include "page0page.h"
/************************************************************ /************************************************************
Opens a buffer to mlog. It must be closed with mlog_close. */ Opens a buffer to mlog. It must be closed with mlog_close. */
...@@ -164,6 +163,7 @@ mlog_write_initial_log_record_fast( ...@@ -164,6 +163,7 @@ mlog_write_initial_log_record_fast(
#ifdef UNIV_DEBUG #ifdef UNIV_DEBUG
buf_block_t* block; buf_block_t* block;
#endif #endif
const byte* page;
ulint space; ulint space;
ulint offset; ulint offset;
...@@ -171,8 +171,9 @@ mlog_write_initial_log_record_fast( ...@@ -171,8 +171,9 @@ mlog_write_initial_log_record_fast(
ut_ad(type <= MLOG_BIGGEST_TYPE); ut_ad(type <= MLOG_BIGGEST_TYPE);
ut_ad(ptr && log_ptr); ut_ad(ptr && log_ptr);
space = page_get_space_id(page_align(ptr)); page = ut_align_down(ptr, UNIV_PAGE_SIZE);
offset = page_get_page_no(page_align(ptr)); space = mach_read_from_4(page + FIL_PAGE_ARCH_LOG_NO_OR_SPACE_ID);
offset = mach_read_from_4(page + FIL_PAGE_OFFSET);
mach_write_to_1(log_ptr, type); mach_write_to_1(log_ptr, type);
log_ptr++; log_ptr++;
......
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