1
0
mirror of https://github.com/MariaDB/server.git synced 2026-01-06 05:22:24 +03:00

simple speed & space optimization:

- Avoid full inline of mark_trx_read_write() for many functions
- Avoid somewhat expensive tests for every write/update/delete row 

sql/handler.h:
  Adde ha_start_of_new_statement() to reset internal variables as part of the code in "open_table" that resets TABLE object for the new statement
  Faster mark_trx_read_write_part()
sql/sql_base.cc:
  Don't manipulate table->file internal structs directly
This commit is contained in:
Michael Widenius
2010-03-25 15:33:39 +02:00
parent 2b17c453a7
commit 2c77c9ea25
3 changed files with 22 additions and 6 deletions

View File

@@ -2996,7 +2996,7 @@ TABLE *open_table(THD *thd, TABLE_LIST *table_list, MEM_ROOT *mem_root,
table->status=STATUS_NO_RECORD;
table->insert_values= 0;
table->fulltext_searched= 0;
table->file->ft_handler= 0;
table->file->ha_start_of_new_statement();
table->reginfo.impossible_range= 0;
/* Catch wrong handling of the auto_increment_field_not_null. */
DBUG_ASSERT(!table->auto_increment_field_not_null);