Commit fc2c6729 authored by marko's avatar marko

branches/zip: Remove buf_pool->frame_zero and buf_pool->high_end.

parent e5eb6187
......@@ -665,9 +665,6 @@ buf_pool_init(
frame = ut_align(buf_pool->frame_mem, UNIV_PAGE_SIZE);
buf_pool->frame_zero = frame;
buf_pool->high_end = frame + UNIV_PAGE_SIZE * n_frames;
/* Init block structs and assign frames for them. Then we
assign the frames to the first blocks (we already mapped the
memory above). */
......@@ -676,9 +673,9 @@ buf_pool_init(
block = buf_pool_get_nth_block(buf_pool, i);
frame = buf_pool->frame_zero + i * UNIV_PAGE_SIZE;
buf_block_init(block, frame);
frame += UNIV_PAGE_SIZE;
}
buf_pool->page_hash = hash_create(2 * curr_size);
......
......@@ -830,11 +830,6 @@ struct buf_pool_struct{
read-write lock in them */
byte* frame_mem; /* pointer to the memory area which
was allocated for the frames */
byte* frame_zero; /* pointer to the first buffer frame:
this may differ from frame_mem, because
this is aligned by the frame size */
byte* high_end; /* pointer to the end of the buffer
frames */
buf_block_t* blocks; /* array of buffer control blocks */
ulint curr_size; /* current pool size in pages */
hash_table_t* page_hash; /* hash table of the file pages */
......
......@@ -57,13 +57,6 @@ mlog_write_initial_log_record(
ut_ad(type <= MLOG_BIGGEST_TYPE);
ut_ad(type > MLOG_8BYTES);
if (ptr < buf_pool->frame_zero || ptr >= buf_pool->high_end) {
fprintf(stderr,
"InnoDB: Error: trying to write to"
" a stray memory location %p\n", (void*) ptr);
ut_error;
}
log_ptr = mlog_open(mtr, 11);
/* If no logging is requested, we may return now */
......@@ -240,14 +233,6 @@ mlog_write_ulint(
{
byte* log_ptr;
if (UNIV_UNLIKELY(ptr < buf_pool->frame_zero)
|| UNIV_UNLIKELY(ptr >= buf_pool->high_end)) {
fprintf(stderr,
"InnoDB: Error: trying to write to"
" a stray memory location %p\n", (void*) ptr);
ut_error;
}
switch (type) {
case MLOG_1BYTE:
mach_write_to_1(ptr, val);
......@@ -293,14 +278,6 @@ mlog_write_dulint(
{
byte* log_ptr;
if (UNIV_UNLIKELY(ptr < buf_pool->frame_zero)
|| UNIV_UNLIKELY(ptr >= buf_pool->high_end)) {
fprintf(stderr,
"InnoDB: Error: trying to write to"
" a stray memory location %p\n", (void*) ptr);
ut_error;
}
ut_ad(ptr && mtr);
mach_write_to_8(ptr, val);
......@@ -336,13 +313,6 @@ mlog_write_string(
ulint len, /* in: string length */
mtr_t* mtr) /* in: mini-transaction handle */
{
if (UNIV_UNLIKELY(ptr < buf_pool->frame_zero)
|| UNIV_UNLIKELY(ptr >= buf_pool->high_end)) {
fprintf(stderr,
"InnoDB: Error: trying to write to"
" a stray memory location %p\n", (void*) ptr);
ut_error;
}
ut_ad(ptr && mtr);
ut_a(len < UNIV_PAGE_SIZE);
......
......@@ -3795,13 +3795,9 @@ row_search_for_mysql(
ut_print_timestamp(stderr);
buf_page_print(page_align(rec), 0);
fprintf(stderr,
"\nInnoDB: rec address %p, first"
" buffer frame %p\n"
"InnoDB: buffer pool high end %p,"
"\nInnoDB: rec address %p,"
" buf block fix count %lu\n",
(void*) rec, (void*) buf_pool->frame_zero,
(void*) buf_pool->high_end,
(ulong)
(void*) rec, (ulong)
btr_cur_get_block(btr_pcur_get_btr_cur(pcur))
->buf_fix_count);
fprintf(stderr,
......
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