summaryrefslogtreecommitdiff
path: root/storage
diff options
context:
space:
mode:
authorSergei Golubchik <serg@mariadb.org>2015-08-01 15:08:33 +0200
committerSergei Golubchik <serg@mariadb.org>2015-08-01 15:08:33 +0200
commit17a4a39c1557290f2712fdc921e3c0586619cf2e (patch)
tree87aa8665b6b3e06dbe29381ca71d018787a80dd6 /storage
parent6300f2f274bd9af0cdb599f15fbf55a66ba9ec56 (diff)
parent1b0c81c917c215fad107d66c75cc2eb282bd8f4e (diff)
downloadmariadb-git-17a4a39c1557290f2712fdc921e3c0586619cf2e.tar.gz
Merge branch 'merge-xtradb-5.5' into 5.5
5.5.44-37.3
Diffstat (limited to 'storage')
-rw-r--r--storage/xtradb/buf/buf0buf.c6
-rw-r--r--storage/xtradb/dict/dict0dict.c3
-rw-r--r--storage/xtradb/handler/ha_innodb.cc34
-rw-r--r--storage/xtradb/include/univ.i4
-rw-r--r--storage/xtradb/srv/srv0start.c4
-rw-r--r--storage/xtradb/sync/sync0arr.c7
-rw-r--r--storage/xtradb/trx/trx0trx.c4
7 files changed, 39 insertions, 23 deletions
diff --git a/storage/xtradb/buf/buf0buf.c b/storage/xtradb/buf/buf0buf.c
index f8966e9b15c..6ef9ac0d16a 100644
--- a/storage/xtradb/buf/buf0buf.c
+++ b/storage/xtradb/buf/buf0buf.c
@@ -1,6 +1,6 @@
/*****************************************************************************
-Copyright (c) 1995, 2014, Oracle and/or its affiliates. All Rights Reserved.
+Copyright (c) 1995, 2015, Oracle and/or its affiliates. All Rights Reserved.
Copyright (c) 2008, Google Inc.
Portions of this file contain modifications contributed and copyrighted by
@@ -1666,6 +1666,10 @@ buf_pool_watch_set(
/* buf_pool->watch is protected by zip_mutex for now */
mutex_enter(&buf_pool->zip_mutex);
+
+ /* The maximum number of purge threads should never exceed
+ BUF_POOL_WATCH_SIZE. So there is no way for purge thread
+ instance to hold a watch when setting another watch. */
for (i = 0; i < BUF_POOL_WATCH_SIZE; i++) {
bpage = &buf_pool->watch[i];
diff --git a/storage/xtradb/dict/dict0dict.c b/storage/xtradb/dict/dict0dict.c
index d18184f6e30..a7d9412ff15 100644
--- a/storage/xtradb/dict/dict0dict.c
+++ b/storage/xtradb/dict/dict0dict.c
@@ -1,6 +1,6 @@
/*****************************************************************************
-Copyright (c) 1996, 2014, Oracle and/or its affiliates. All Rights Reserved.
+Copyright (c) 1996, 2015, Oracle and/or its affiliates. All Rights Reserved.
This program is free software; you can redistribute it and/or modify it under
the terms of the GNU General Public License as published by the Free Software
@@ -2663,6 +2663,7 @@ dict_foreign_remove_from_cache(
foreign);
rbt = foreign->referenced_table->referenced_rbt;
+
if (rbt != NULL && foreign->id != NULL) {
const ib_rbt_node_t* node
= rbt_lookup(rbt, foreign->id);
diff --git a/storage/xtradb/handler/ha_innodb.cc b/storage/xtradb/handler/ha_innodb.cc
index 6c4e9eedd7d..37a029dd210 100644
--- a/storage/xtradb/handler/ha_innodb.cc
+++ b/storage/xtradb/handler/ha_innodb.cc
@@ -1,6 +1,6 @@
/*****************************************************************************
-Copyright (c) 2000, 2014, Oracle and/or its affiliates. All Rights Reserved.
+Copyright (c) 2000, 2015, Oracle and/or its affiliates. All Rights Reserved.
Copyright (c) 2008, 2009 Google Inc.
Copyright (c) 2009, Percona Inc.
@@ -9120,6 +9120,13 @@ ha_innobase::estimate_rows_upper_bound(void)
estimate = 2 * local_data_file_length /
dict_index_calc_min_rec_len(index);
+ /* Set num_rows less than MERGEBUFF to simulate the case where we do
+ not have enough space to merge the externally sorted file blocks. */
+ DBUG_EXECUTE_IF("set_num_rows_lt_MERGEBUFF",
+ estimate = 2;
+ DBUG_SET("-d,set_num_rows_lt_MERGEBUFF");
+ );
+
prebuilt->trx->op_info = (char*)"";
DBUG_RETURN((ha_rows) estimate);
@@ -9399,17 +9406,6 @@ ha_innobase::info_low(
prebuilt->trx->op_info = "returning various info to MySQL";
}
- my_snprintf(path, sizeof(path), "%s/%s%s",
- mysql_data_home, ib_table->name, reg_ext);
-
- unpack_filename(path,path);
-
- /* Note that we do not know the access time of the table,
- nor the CHECK TABLE time, nor the UPDATE or INSERT time. */
-
- if (os_file_get_status(path,&stat_info)) {
- stats.create_time = (ulong) stat_info.ctime;
- }
}
if (flag & HA_STATUS_VARIABLE) {
@@ -9653,6 +9649,20 @@ ha_innobase::info_low(
}
dict_table_stats_unlock(ib_table, RW_S_LATCH);
+
+ my_snprintf(path, sizeof(path), "%s/%s%s",
+ mysql_data_home,
+ table->s->normalized_path.str,
+ reg_ext);
+
+ unpack_filename(path,path);
+
+ /* Note that we do not know the access time of the table,
+ nor the CHECK TABLE time, nor the UPDATE or INSERT time. */
+
+ if (os_file_get_status(path,&stat_info)) {
+ stats.create_time = (ulong) stat_info.ctime;
+ }
}
if (srv_force_recovery >= SRV_FORCE_NO_IBUF_MERGE) {
diff --git a/storage/xtradb/include/univ.i b/storage/xtradb/include/univ.i
index c31a0f20862..701d3c14f1b 100644
--- a/storage/xtradb/include/univ.i
+++ b/storage/xtradb/include/univ.i
@@ -64,10 +64,10 @@ component, i.e. we show M.N.P as M.N */
(INNODB_VERSION_MAJOR << 8 | INNODB_VERSION_MINOR)
#ifndef PERCONA_INNODB_VERSION
-#define PERCONA_INNODB_VERSION 37.2
+#define PERCONA_INNODB_VERSION 37.3
#endif
-#define INNODB_VERSION_STR "5.5.43-MariaDB-" IB_TO_STR(PERCONA_INNODB_VERSION)
+#define INNODB_VERSION_STR "5.5.44-MariaDB-" IB_TO_STR(PERCONA_INNODB_VERSION)
#define REFMAN "http://dev.mysql.com/doc/refman/" \
IB_TO_STR(MYSQL_MAJOR_VERSION) "." \
diff --git a/storage/xtradb/srv/srv0start.c b/storage/xtradb/srv/srv0start.c
index 39a61935aed..e4f4047393d 100644
--- a/storage/xtradb/srv/srv0start.c
+++ b/storage/xtradb/srv/srv0start.c
@@ -1,6 +1,6 @@
/*****************************************************************************
-Copyright (c) 1996, 2013, Oracle and/or its affiliates. All rights reserved.
+Copyright (c) 1996, 2015, Oracle and/or its affiliates. All rights reserved.
Copyright (c) 2008, Google Inc.
Copyright (c) 2009, Percona Inc.
@@ -2501,9 +2501,9 @@ innobase_shutdown_for_mysql(void)
ibuf_close();
log_shutdown();
- lock_sys_close();
trx_sys_file_format_close();
trx_sys_close();
+ lock_sys_close();
mutex_free(&srv_monitor_file_mutex);
mutex_free(&srv_dict_tmpfile_mutex);
diff --git a/storage/xtradb/sync/sync0arr.c b/storage/xtradb/sync/sync0arr.c
index 73cd6ea1739..3bf53696148 100644
--- a/storage/xtradb/sync/sync0arr.c
+++ b/storage/xtradb/sync/sync0arr.c
@@ -1,6 +1,6 @@
/*****************************************************************************
-Copyright (c) 1995, 2011, Oracle and/or its affiliates. All Rights Reserved.
+Copyright (c) 1995, 2015, Oracle and/or its affiliates. All Rights Reserved.
Copyright (c) 2008, Google Inc.
Copyright (c) 2013, 2014, MariaDB Corporation. All Rights Reserved.
@@ -1114,8 +1114,9 @@ sync_array_output_info(
os_thread_id_t r;
fprintf(file,
- "OS WAIT ARRAY INFO: reservation count %ld, signal count %ld\n",
- (long) arr->res_count, (long) arr->sg_count);
+ "OS WAIT ARRAY INFO: reservation count " ULINTPF
+ ", signal count " ULINTPF "\n",
+ arr->res_count, arr->sg_count);
i = 0;
count = 0;
diff --git a/storage/xtradb/trx/trx0trx.c b/storage/xtradb/trx/trx0trx.c
index bc511504db9..11b0de49e10 100644
--- a/storage/xtradb/trx/trx0trx.c
+++ b/storage/xtradb/trx/trx0trx.c
@@ -768,9 +768,9 @@ trx_lists_init_at_db_start(void)
" anyway.\n");
trx->state = TRX_ACTIVE;
- trx_reserve_descriptor(
- trx);
}
+
+ trx_reserve_descriptor(trx);
} else {
trx->state
= TRX_COMMITTED_IN_MEMORY;