summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergei Golubchik <serg@mariadb.org>2023-01-03 20:48:03 +0100
committerMonty <monty@mariadb.org>2023-02-10 12:59:36 +0200
commit7e465aeb3a67d2cc409274b91a75d1928fab0faa (patch)
tree4b716e67e9f91b6eb90913731d75ff8dc41cbc42
parent5e5988dbb88f45d1dfebdc3a71153489b2151717 (diff)
downloadmariadb-git-7e465aeb3a67d2cc409274b91a75d1928fab0faa.tar.gz
typos in comments, etc
-rw-r--r--Docs/optimizer_costs.txt2
-rw-r--r--mysql-test/main/optimizer_costs2.opt (renamed from mysql-test/main/optimizer_costs2-master.opt)0
-rw-r--r--mysql-test/main/subselect_mat_cost.opt (renamed from mysql-test/main/subselect_mat_cost-master.opt)0
-rw-r--r--sql/handler.cc4
-rw-r--r--sql/sys_vars.inl6
5 files changed, 4 insertions, 8 deletions
diff --git a/Docs/optimizer_costs.txt b/Docs/optimizer_costs.txt
index 3bcce2453b5..dcb8bca7a23 100644
--- a/Docs/optimizer_costs.txt
+++ b/Docs/optimizer_costs.txt
@@ -1,5 +1,5 @@
This file is intended to explain some of the optimizer cost variables
-in MariaDB 10.11.
+in MariaDB 11.0
Background
==========
diff --git a/mysql-test/main/optimizer_costs2-master.opt b/mysql-test/main/optimizer_costs2.opt
index 718ccafc05e..718ccafc05e 100644
--- a/mysql-test/main/optimizer_costs2-master.opt
+++ b/mysql-test/main/optimizer_costs2.opt
diff --git a/mysql-test/main/subselect_mat_cost-master.opt b/mysql-test/main/subselect_mat_cost.opt
index cb4a9db9617..cb4a9db9617 100644
--- a/mysql-test/main/subselect_mat_cost-master.opt
+++ b/mysql-test/main/subselect_mat_cost.opt
diff --git a/sql/handler.cc b/sql/handler.cc
index 536958059ac..5884339c809 100644
--- a/sql/handler.cc
+++ b/sql/handler.cc
@@ -763,9 +763,7 @@ int ha_initialize_handlerton(st_plugin_int *plugin)
savepoint_alloc_size+= tmp;
hton2plugin[hton->slot]=plugin;
- if (plugin->plugin->type == MYSQL_STORAGE_ENGINE_PLUGIN &&
- !(hton->flags & HTON_HIDDEN) &&
- update_optimizer_costs(hton))
+ if (!(hton->flags & HTON_HIDDEN) && update_optimizer_costs(hton))
goto err_deinit;
if (hton->prepare)
diff --git a/sql/sys_vars.inl b/sql/sys_vars.inl
index 5997446a61e..a9d17b8f5e7 100644
--- a/sql/sys_vars.inl
+++ b/sql/sys_vars.inl
@@ -1200,7 +1200,6 @@ public:
option.var_type|= GET_DOUBLE;
option.min_value= (longlong) getopt_double2ulonglong(min_val);
option.max_value= (longlong) getopt_double2ulonglong(max_val);
- global_var(double)= (double)option.def_value;
SYSVAR_ASSERT(min_val < max_val);
SYSVAR_ASSERT(min_val <= def_val);
SYSVAR_ASSERT(max_val >= def_val);
@@ -1263,7 +1262,6 @@ public:
option.var_type|= GET_ADJUST_VALUE;
}
cost_adjust= (double) arg_cost_adjust;
- global_var(double)= (double)option.def_value/cost_adjust; // To usec
}
bool session_update(THD *thd, set_var *var)
{
@@ -1287,7 +1285,7 @@ public:
/*
- The class for optimzer costs with structured names, unique for each engine.
+ The class for optimizer costs with structured names, unique for each engine.
Used as 'engine.variable_name'
Class specific constructor arguments:
@@ -1331,7 +1329,7 @@ class Sys_var_engine_optimizer_cost: public Sys_var_optimizer_cost
{
option.var_type|= GET_ASK_ADDR;
option.value= (uchar**)1; // crash me, please
- // fix an offset from global_system_variables to be an offset in KEY_CACHE
+ // fix an offset from global_system_variables to be an offset in OPTIMIZER_COSTS
offset= global_var_ptr() - (uchar*) &default_optimizer_costs;
SYSVAR_ASSERT(scope() == GLOBAL);
}