diff options
author | Marko Mäkelä <marko.makela@oracle.com> | 2010-05-19 12:36:27 +0300 |
---|---|---|
committer | Marko Mäkelä <marko.makela@oracle.com> | 2010-05-19 12:36:27 +0300 |
commit | 9bf086dcff409d1a115874f253f1124a9d7da3a5 (patch) | |
tree | 6c7cc64713f200a5f098e85133bd473fd6c77164 | |
parent | 52223f72174b340cb2b9b50eaa8f2dfa2577d4fb (diff) | |
download | mariadb-git-9bf086dcff409d1a115874f253f1124a9d7da3a5.tar.gz |
Merge a change from mysql-5.1-innodb:
------------------------------------------------------------
revno: 3471
revision-id: marko.makela@oracle.com-20100519080152-h3555oqmu3wo95so
parent: marko.makela@oracle.com-20100519075843-4gl3uijo6cwjtcf9
committer: Marko Mäkelä <marko.makela@oracle.com>
branch nick: 5.1-innodb
timestamp: Wed 2010-05-19 11:01:52 +0300
message:
Silence some more bogus Valgrind warnings on non-32-bit systems. (Bug #53307)
-rw-r--r-- | storage/innobase/buf/buf0buddy.c | 5 | ||||
-rw-r--r-- | storage/innobase/buf/buf0lru.c | 7 | ||||
-rw-r--r-- | storage/innobase/page/page0zip.c | 5 |
3 files changed, 16 insertions, 1 deletions
diff --git a/storage/innobase/buf/buf0buddy.c b/storage/innobase/buf/buf0buddy.c index 695aed2d0cb..8fe1780985b 100644 --- a/storage/innobase/buf/buf0buddy.c +++ b/storage/innobase/buf/buf0buddy.c @@ -502,7 +502,12 @@ success: mutex_exit(mutex); } else if (i == buf_buddy_get_slot(sizeof(buf_page_t))) { /* This must be a buf_page_t object. */ +#if UNIV_WORD_SIZE == 4 + /* On 32-bit systems, there is no padding in + buf_page_t. On other systems, Valgrind could complain + about uninitialized pad bytes. */ UNIV_MEM_ASSERT_RW(src, size); +#endif if (buf_buddy_relocate_block(src, dst)) { goto success; diff --git a/storage/innobase/buf/buf0lru.c b/storage/innobase/buf/buf0lru.c index 9de68e23533..5cff0f51aaa 100644 --- a/storage/innobase/buf/buf0lru.c +++ b/storage/innobase/buf/buf0lru.c @@ -1578,8 +1578,13 @@ alloc: ut_ad(prev_b->in_LRU_list); ut_ad(buf_page_in_file(prev_b)); +#if UNIV_WORD_SIZE == 4 + /* On 32-bit systems, there is no + padding in buf_page_t. On other + systems, Valgrind could complain about + uninitialized pad bytes. */ UNIV_MEM_ASSERT_RW(prev_b, sizeof *prev_b); - +#endif UT_LIST_INSERT_AFTER(LRU, buf_pool->LRU, prev_b, b); diff --git a/storage/innobase/page/page0zip.c b/storage/innobase/page/page0zip.c index d9f61cea335..14ec3e7a94f 100644 --- a/storage/innobase/page/page0zip.c +++ b/storage/innobase/page/page0zip.c @@ -3117,8 +3117,13 @@ page_zip_validate_low( temp_page_zip in a debugger when running valgrind --db-attach. */ VALGRIND_GET_VBITS(page, temp_page, UNIV_PAGE_SIZE); UNIV_MEM_ASSERT_RW(page, UNIV_PAGE_SIZE); +# if UNIV_WORD_SIZE == 4 VALGRIND_GET_VBITS(page_zip, &temp_page_zip, sizeof temp_page_zip); + /* On 32-bit systems, there is no padding in page_zip_des_t. + On other systems, Valgrind could complain about uninitialized + pad bytes. */ UNIV_MEM_ASSERT_RW(page_zip, sizeof *page_zip); +# endif VALGRIND_GET_VBITS(page_zip->data, temp_page, page_zip_get_size(page_zip)); UNIV_MEM_ASSERT_RW(page_zip->data, page_zip_get_size(page_zip)); |