Browse Source

branches/zip: Improve Valgrind instrumentation.

btr_cur_optimistic_insert(): On compressed tablespaces, check that both
the compressed and the uncompressed page are completely initialized in
the beginning of the function.

page_zip_compress(): After successful compression, check that the compressed
page is completely initialized.
pull/374/head
marko 18 years ago
parent
commit
589393da83
  1. 6
      btr/btr0cur.c
  2. 2
      page/page0zip.c

6
btr/btr0cur.c

@ -1029,6 +1029,12 @@ btr_cur_optimistic_insert(
page = buf_block_get_frame(block);
index = cursor->index;
zip_size = buf_block_get_zip_size(block);
#ifdef UNIV_DEBUG_VALGRIND
if (zip_size) {
UNIV_MEM_ASSERT_RW(page, UNIV_PAGE_SIZE);
UNIV_MEM_ASSERT_RW(buf_block_get_page_zip(block), zip_size);
}
#endif /* UNIV_DEBUG_VALGRIND */
if (!dtuple_check_typed_no_assert(entry)) {
fputs("InnoDB: Error in a tuple to insert into ", stderr);

2
page/page0zip.c

@ -1253,6 +1253,8 @@ zlib_error:
page_zip_compress_ok[page_zip->ssize]++;
UNIV_MEM_ASSERT_RW(page_zip, page_zip_get_size(page_zip));
return(TRUE);
}

Loading…
Cancel
Save