summaryrefslogtreecommitdiff
path: root/sql/sql_parse.h
diff options
context:
space:
mode:
authorSergey Vojtovich <svoj@mariadb.org>2015-08-11 11:18:38 +0400
committerSergey Vojtovich <svoj@mariadb.org>2015-08-21 10:40:39 +0400
commit31e365efae28ba3208e80511c4d18fe11a79541a (patch)
treef249682cc42490fc86382f5244a051001dc13c9e /sql/sql_parse.h
parent4374da63f03abc472f68f42e4e93261a18bfe417 (diff)
downloadmariadb-git-31e365efae28ba3208e80511c4d18fe11a79541a.tar.gz
MDEV-8010 - Avoid sql_alloc() in Items (Patch #1)
Added mandatory thd parameter to Item (and all derivative classes) constructor. Added thd parameter to all routines that may create items. Also removed "current_thd" from Item::Item. This reduced number of pthread_getspecific() calls from 290 to 177 per OLTP RO transaction.
Diffstat (limited to 'sql/sql_parse.h')
-rw-r--r--sql/sql_parse.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/sql/sql_parse.h b/sql/sql_parse.h
index d85bb87a4fb..c3c47567cf5 100644
--- a/sql/sql_parse.h
+++ b/sql/sql_parse.h
@@ -108,7 +108,7 @@ bool append_file_to_dir(THD *thd, const char **filename_ptr,
void execute_init_command(THD *thd, LEX_STRING *init_command,
mysql_rwlock_t *var_lock);
bool add_to_list(THD *thd, SQL_I_List<ORDER> &list, Item *group, bool asc);
-void add_join_on(TABLE_LIST *b,Item *expr);
+void add_join_on(THD *thd, TABLE_LIST *b, Item *expr);
void add_join_natural(TABLE_LIST *a,TABLE_LIST *b,List<String> *using_fields,
SELECT_LEX *lex);
bool add_proc_to_list(THD *thd, Item *item);
@@ -118,7 +118,7 @@ bool push_new_name_resolution_context(THD *thd,
void store_position_for_column(const char *name);
void init_update_queries(void);
bool check_simple_select();
-Item *normalize_cond(Item *cond);
+Item *normalize_cond(THD *thd, Item *cond);
Item *negate_expression(THD *thd, Item *expr);
bool check_stack_overrun(THD *thd, long margin, uchar *dummy);