summaryrefslogtreecommitdiff
path: root/storage/innobase
diff options
context:
space:
mode:
authorMarko Mäkelä <marko.makela@mariadb.com>2020-03-19 12:57:22 +0200
committerMarko Mäkelä <marko.makela@mariadb.com>2020-03-19 13:01:20 +0200
commit9fd692aecacfc944fd3a6a58f4cae5a49eeb1cf0 (patch)
treea1c83f242567b0a52c0cf86380a37b80783c41a9 /storage/innobase
parentbfb5e1c3f0ba57b54f245d7cc2d1dfabaa7c4462 (diff)
downloadmariadb-git-9fd692aecacfc944fd3a6a58f4cae5a49eeb1cf0.tar.gz
MDEV-13626: Clean up the buffer pool resizing tests from MySQL 5.7
buf_pool_resize(): Simplify the fault injection for innodb.buf_pool_resize_oom. innodb.buf_pool_resize_oom: Use a small buffer pool. innodb.innodb_buffer_pool_load_now: Make use of the sequence engine, to avoid creating explicit InnoDB record locks. Clean up the accesses to information_schema.innodb_buffer_page_lru.
Diffstat (limited to 'storage/innobase')
-rw-r--r--storage/innobase/buf/buf0buf.cc22
1 files changed, 3 insertions, 19 deletions
diff --git a/storage/innobase/buf/buf0buf.cc b/storage/innobase/buf/buf0buf.cc
index d80eadcfc70..57dc54f38b4 100644
--- a/storage/innobase/buf/buf0buf.cc
+++ b/storage/innobase/buf/buf0buf.cc
@@ -2,7 +2,7 @@
Copyright (c) 1995, 2018, Oracle and/or its affiliates. All Rights Reserved.
Copyright (c) 2008, Google Inc.
-Copyright (c) 2013, 2019, MariaDB Corporation.
+Copyright (c) 2013, 2020, MariaDB Corporation.
Portions of this file contain modifications contributed and copyrighted by
Google, Inc. Those modifications are gratefully acknowledged and are described
@@ -2648,23 +2648,6 @@ buf_pool_resize_hash(
buf_pool->zip_hash = new_hash_table;
}
-#ifndef DBUG_OFF
-/** This is a debug routine to inject an memory allocation failure error. */
-static
-void
-buf_pool_resize_chunk_make_null(buf_chunk_t** new_chunks)
-{
- static int count = 0;
-
- if (count == 1) {
- ut_free(*new_chunks);
- *new_chunks = NULL;
- }
-
- count++;
-}
-#endif // DBUG_OFF
-
/** Resize the buffer pool based on srv_buf_pool_size from
srv_buf_pool_old_size. */
static
@@ -2931,7 +2914,8 @@ withdraw_retry:
ut_zalloc_nokey_nofatal(new_chunks_size));
DBUG_EXECUTE_IF("buf_pool_resize_chunk_null",
- buf_pool_resize_chunk_make_null(&new_chunks););
+ ut_free(new_chunks);
+ new_chunks = NULL;);
if (new_chunks == NULL) {
ib::error() << "buffer pool " << i