summaryrefslogtreecommitdiff
path: root/sql/sql_handler.cc
diff options
context:
space:
mode:
authorSergei Golubchik <serg@mariadb.org>2020-01-29 13:50:26 +0100
committerSergei Golubchik <serg@mariadb.org>2020-03-10 19:24:22 +0100
commit7c58e97bf6f80a251046c5b3e7bce826fe058bd6 (patch)
tree7d32d26b320cf83296ee0ede2ea164ad116c4de8 /sql/sql_handler.cc
parent2ac3121af2767186c489054db5d4871d04b8eef4 (diff)
downloadmariadb-git-7c58e97bf6f80a251046c5b3e7bce826fe058bd6.tar.gz
perfschema memory related instrumentation changes
Diffstat (limited to 'sql/sql_handler.cc')
-rw-r--r--sql/sql_handler.cc7
1 files changed, 4 insertions, 3 deletions
diff --git a/sql/sql_handler.cc b/sql/sql_handler.cc
index 12119997430..6292631ea7d 100644
--- a/sql/sql_handler.cc
+++ b/sql/sql_handler.cc
@@ -292,7 +292,8 @@ bool mysql_ha_open(THD *thd, TABLE_LIST *tables, SQL_HANDLER *reopen)
if (my_hash_init(&thd->handler_tables_hash, &my_charset_latin1,
HANDLER_TABLES_HASH_SIZE, 0, 0,
(my_hash_get_key) mysql_ha_hash_get_key,
- (my_hash_free_key) mysql_ha_hash_free, 0))
+ (my_hash_free_key) mysql_ha_hash_free, 0,
+ key_memory_THD_handler_tables_hash))
{
DBUG_PRINT("exit",("ERROR"));
DBUG_RETURN(TRUE);
@@ -384,14 +385,14 @@ bool mysql_ha_open(THD *thd, TABLE_LIST *tables, SQL_HANDLER *reopen)
/* copy data to sql_handler */
if (!(sql_handler= new SQL_HANDLER(thd)))
goto err;
- init_alloc_root(&sql_handler->mem_root, "sql_handler", 1024, 0,
+ init_alloc_root(PSI_INSTRUMENT_ME, &sql_handler->mem_root, 1024, 0,
MYF(MY_THREAD_SPECIFIC));
sql_handler->db.length= tables->db.length;
sql_handler->table_name.length= tables->table_name.length;
sql_handler->handler_name.length= tables->alias.length;
- if (!(my_multi_malloc(MY_WME,
+ if (!(my_multi_malloc(PSI_INSTRUMENT_ME, MYF(MY_WME),
&sql_handler->base_data,
(uint) sql_handler->db.length + 1,
&sql_handler->table_name.str,