diff options
author | unknown <malff/marcsql@weblab.(none)> | 2007-08-22 15:38:32 -0600 |
---|---|---|
committer | unknown <malff/marcsql@weblab.(none)> | 2007-08-22 15:38:32 -0600 |
commit | 5dc3e88947d55e23dd0419938d4cb671e400a6f3 (patch) | |
tree | 4d47b4acc13f3c844ff3f11e4a196a060f1390ef /sql/sql_lex.cc | |
parent | 49fea65f2bab0853f4c2217777fe2563f771a044 (diff) | |
download | mariadb-git-5dc3e88947d55e23dd0419938d4cb671e400a6f3.tar.gz |
Bug#30333 (Performance, expressions lists in the parser)
Before this patch, the parser would execute:
- Select->expr_list.push_front()
- Select->expr_list.pop()
when parsing expressions lists, in the following rules:
- udf_expr_list
- expr_list
- ident_list
This is unnecessary, and introduces overhead due to the memory allocations
performed with Select->expr_list
With this patch, this code has been removed.
The list being parsed is maintained in the parser stack instead.
Also, 'udf_expr_list' has been renamed 'opt_udf_expr_list', since this
production can be empty.
sql/sql_lex.cc:
Removed unused attribute expr_list
sql/sql_lex.h:
Removed unused attribute expr_list
sql/sql_yacc.yy:
Improved performances when parsing expression lists
Diffstat (limited to 'sql/sql_lex.cc')
-rw-r--r-- | sql/sql_lex.cc | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/sql/sql_lex.cc b/sql/sql_lex.cc index 78b4f034f98..7fe2ed04d51 100644 --- a/sql/sql_lex.cc +++ b/sql/sql_lex.cc @@ -323,7 +323,6 @@ void lex_start(THD *thd) lex->length=0; lex->part_info= 0; lex->select_lex.in_sum_expr=0; - lex->select_lex.expr_list.empty(); lex->select_lex.ftfunc_list_alloc.empty(); lex->select_lex.ftfunc_list= &lex->select_lex.ftfunc_list_alloc; lex->select_lex.group_list.empty(); @@ -1555,7 +1554,6 @@ void st_select_lex::init_select() options= 0; sql_cache= SQL_CACHE_UNSPECIFIED; braces= 0; - expr_list.empty(); interval_list.empty(); ftfunc_list_alloc.empty(); inner_sum_func_list= 0; |