summaryrefslogtreecommitdiff
path: root/sql/sp_rcontext.h
diff options
context:
space:
mode:
authorSergey Vojtovich <svoj@mariadb.org>2015-04-22 13:29:56 +0400
committerSergey Vojtovich <svoj@mariadb.org>2015-05-13 15:56:56 +0400
commitb22959903b89e798f8804ec9a815c88f75915cd9 (patch)
tree8b3443332de3bea57ced828a7932ade4add36ce0 /sql/sp_rcontext.h
parent8345bc692192788c25ec004134a3a095437aeb1c (diff)
downloadmariadb-git-b22959903b89e798f8804ec9a815c88f75915cd9.tar.gz
MDEV-7943 - pthread_getspecific() takes 0.76% in OLTP RO
Added THD argument to select_result and all derivative classes. This reduces number of pthread_getspecific calls from 796 to 776 per OLTP RO transaction.
Diffstat (limited to 'sql/sp_rcontext.h')
-rw-r--r--sql/sp_rcontext.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/sql/sp_rcontext.h b/sql/sp_rcontext.h
index c48025da93d..2640490fefa 100644
--- a/sql/sp_rcontext.h
+++ b/sql/sp_rcontext.h
@@ -281,7 +281,7 @@ public:
/// @return error flag.
/// @retval false on success.
/// @retval true on error.
- bool push_cursor(sp_lex_keeper *lex_keeper, sp_instr_cpush *i);
+ bool push_cursor(THD *thd, sp_lex_keeper *lex_keeper, sp_instr_cpush *i);
/// Pop and delete given number of sp_cursor instance from the cursor stack.
///
@@ -428,7 +428,7 @@ private:
List<sp_variable> *spvar_list;
uint field_count;
public:
- Select_fetch_into_spvars() {} /* Remove gcc warning */
+ Select_fetch_into_spvars(THD *thd_arg): select_result_interceptor(thd_arg) {}
uint get_field_count() { return field_count; }
void set_spvar_list(List<sp_variable> *vars) { spvar_list= vars; }
@@ -438,7 +438,7 @@ private:
};
public:
- sp_cursor(sp_lex_keeper *lex_keeper, sp_instr_cpush *i);
+ sp_cursor(THD *thd_arg, sp_lex_keeper *lex_keeper, sp_instr_cpush *i);
virtual ~sp_cursor()
{ destroy(); }