diff options
author | heikki@donna.mysql.fi <> | 2001-06-24 20:09:41 +0300 |
---|---|---|
committer | heikki@donna.mysql.fi <> | 2001-06-24 20:09:41 +0300 |
commit | 7f6e4a78ca5e3e64b72a1d55fdb283c843e51b5a (patch) | |
tree | f6c27154c8690eb8dc7fad6ac825463fb005fe01 /innobase | |
parent | 9187316332012a717fc873aeb6a80630eb25da75 (diff) | |
download | mariadb-git-7f6e4a78ca5e3e64b72a1d55fdb283c843e51b5a.tar.gz |
univ.i Added a new debug define option
sync0sync.ic Do not use GCC in-line assembly
srv0start.h Eliminate a deadlock of threads at startup
buf0buf.h Add some debug functions
srv0start.c Remove a printf
Diffstat (limited to 'innobase')
-rw-r--r-- | innobase/include/buf0buf.h | 29 | ||||
-rw-r--r-- | innobase/include/srv0start.h | 3 | ||||
-rw-r--r-- | innobase/include/sync0sync.ic | 4 | ||||
-rw-r--r-- | innobase/include/univ.i | 2 | ||||
-rw-r--r-- | innobase/srv/srv0start.c | 3 |
5 files changed, 38 insertions, 3 deletions
diff --git a/innobase/include/buf0buf.h b/innobase/include/buf0buf.h index 5e90f5952fc..7f3e20a4505 100644 --- a/innobase/include/buf0buf.h +++ b/innobase/include/buf0buf.h @@ -293,6 +293,32 @@ buf_page_peek_block( ulint space, /* in: space id */ ulint offset);/* in: page number */ /************************************************************************ +Sets file_page_was_freed TRUE if the page is found in the buffer pool. +This function should be called when we free a file page and want the +debug version to check that it is not accessed any more unless +reallocated. */ + +buf_block_t* +buf_page_set_file_page_was_freed( +/*=============================*/ + /* out: control block if found from page hash table, + otherwise NULL */ + ulint space, /* in: space id */ + ulint offset); /* in: page number */ +/************************************************************************ +Sets file_page_was_freed FALSE if the page is found in the buffer pool. +This function should be called when we free a file page and want the +debug version to check that it is not accessed any more unless +reallocated. */ + +buf_block_t* +buf_page_reset_file_page_was_freed( +/*===============================*/ + /* out: control block if found from page hash table, + otherwise NULL */ + ulint space, /* in: space id */ + ulint offset); /* in: page number */ +/************************************************************************ Recommends a move of a block to the start of the LRU list if there is danger of dropping from the buffer pool. NOTE: does not reserve the buffer pool mutex. */ @@ -706,6 +732,9 @@ struct buf_block_struct{ which bufferfixes the block acquires an s-latch here; so we can use the debug utilities in sync0rw */ + ibool file_page_was_freed; + /* this is set to TRUE when fsp + frees a page in buffer pool */ }; /* The buffer pool structure. NOTE! The definition appears here only for diff --git a/innobase/include/srv0start.h b/innobase/include/srv0start.h index 66eeb4f2e3c..e2b20f3b5fc 100644 --- a/innobase/include/srv0start.h +++ b/innobase/include/srv0start.h @@ -28,4 +28,7 @@ int innobase_shutdown_for_mysql(void); /*=============================*/ /* out: DB_SUCCESS or error code */ + +extern ibool srv_startup_is_before_trx_rollback_phase; + #endif diff --git a/innobase/include/sync0sync.ic b/innobase/include/sync0sync.ic index b58d024bf6c..f7b341cb386 100644 --- a/innobase/include/sync0sync.ic +++ b/innobase/include/sync0sync.ic @@ -86,7 +86,7 @@ mutex_test_and_set( /* mutex_fence(); */ return(res); -#elif defined(__GNUC__) && defined(UNIV_INTEL_X86) +#elif defined(not_defined) && defined(__GNUC__) && defined(UNIV_INTEL_X86) ulint* lw; ulint res; @@ -134,7 +134,7 @@ mutex_reset_lock_word( __asm MOV EDX, 0 __asm MOV ECX, lw __asm XCHG EDX, DWORD PTR [ECX] -#elif defined(__GNUC__) && defined(UNIV_INTEL_X86) +#elif defined(not_defined) && defined(__GNUC__) && defined(UNIV_INTEL_X86) ulint* lw; lw = &(mutex->lock_word); diff --git a/innobase/include/univ.i b/innobase/include/univ.i index 9ded084d044..73bf48b1bc0 100644 --- a/innobase/include/univ.i +++ b/innobase/include/univ.i @@ -74,6 +74,8 @@ subdirectory of 'mysql'. */ #define UNIV_SYNC_PERF_STAT #define UNIV_SEARCH_PERF_STAT + +#define UNIV_DEBUG_FILE_ACCESSES */ #define UNIV_LIGHT_MEM_DEBUG diff --git a/innobase/srv/srv0start.c b/innobase/srv/srv0start.c index e121f509266..80fafa37adf 100644 --- a/innobase/srv/srv0start.c +++ b/innobase/srv/srv0start.c @@ -550,8 +550,9 @@ innobase_start_or_create_for_mysql(void) return(DB_ERROR); } + /* printf("srv_unix set to %lu\n", srv_unix_file_flush_method); - + */ os_aio_use_native_aio = srv_use_native_aio; err = srv_boot(); |