• unknown's avatar
    Bug#30333 (Performance, expressions lists in the parser) · 5dc3e889
    unknown authored
    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
    5dc3e889
sql_lex.h 54.4 KB