diff options
author | unknown <bar@gw.udmsearch.izhnet.ru> | 2002-04-25 13:36:55 +0500 |
---|---|---|
committer | unknown <bar@gw.udmsearch.izhnet.ru> | 2002-04-25 13:36:55 +0500 |
commit | 139a73cade4827ca2a41d6cfc9db379b2c696fa3 (patch) | |
tree | 5b8a058772659a40e41e2025e66f79531e604613 /isam | |
parent | 0e4445850dd29493d61e06650a7b2a430ca42ec8 (diff) | |
download | mariadb-git-139a73cade4827ca2a41d6cfc9db379b2c696fa3.tar.gz |
RB-Tree indexes support in HEAP tables
Renamed _hp_func -> hp_func
mi_key_cmp moved to /mysys/my_handler.c
New tests for HEAP tables
heap/_check.c:
RB-tree index
Renamed _hp_func -> hp_func
heap/_rectest.c:
RB-tree index
Renamed _hp_func -> hp_func
heap/heapdef.h:
RB-tree index
Renamed _hp_func -> hp_func
heap/hp_block.c:
RB-tree index
Renamed _hp_func -> hp_func
heap/hp_clear.c:
RB-tree index
Renamed _hp_func -> hp_func
heap/hp_close.c:
RB-tree index
Renamed _hp_func -> hp_func
heap/hp_create.c:
RB-tree index
Renamed _hp_func -> hp_func
heap/hp_delete.c:
RB-tree index
Renamed _hp_func -> hp_func
heap/hp_hash.c:
RB-tree index
Renamed _hp_func -> hp_func
heap/hp_open.c:
RB-tree index
Renamed _hp_func -> hp_func
heap/hp_panic.c:
RB-tree index
Renamed _hp_func -> hp_func
heap/hp_rename.c:
RB-tree index
Renamed _hp_func -> hp_func
heap/hp_rfirst.c:
RB-tree index
Renamed _hp_func -> hp_func
heap/hp_rkey.c:
RB-tree index
Renamed _hp_func -> hp_func
heap/hp_rlast.c:
RB-tree index
Renamed _hp_func -> hp_func
heap/hp_rnext.c:
RB-tree index
Renamed _hp_func -> hp_func
heap/hp_rprev.c:
RB-tree index
Renamed _hp_func -> hp_func
heap/hp_rrnd.c:
RB-tree index
Renamed _hp_func -> hp_func
heap/hp_rsame.c:
RB-tree index
Renamed _hp_func -> hp_func
heap/hp_scan.c:
RB-tree index
Renamed _hp_func -> hp_func
heap/hp_test1.c:
RB-tree index
Renamed _hp_func -> hp_func
heap/hp_test2.c:
RB-tree index
Renamed _hp_func -> hp_func
heap/hp_update.c:
RB-tree index
Renamed _hp_func -> hp_func
heap/hp_write.c:
RB-tree index
Renamed _hp_func -> hp_func
include/Makefile.am:
New include
include/heap.h:
RB-Tree index
include/my_tree.h:
new search functions
new custom_arg argument
include/myisam.h:
Removed MI_KEYSEG
isam/isamlog.c:
Add custom_arg
isam/pack_isam.c:
Add custom_arg
myisam/ft_nlq_search.c:
Add custom_arg
myisam/ft_parser.c:
Add custom_arg
myisam/ft_stopwords.c:
Add custom_arg
myisam/mi_search.c:
Remove mi_key_cmp
myisam/mi_write.c:
Add custom_arg
myisam/myisamdef.h:
Remove mi_key_cmp
myisam/myisamlog.c:
Add custom_arg
myisam/myisampack.c:
Add custom_arg
mysys/Makefile.am:
New file my_handler.c
mysys/tree.c:
custom_arg
new search functions
sql/ha_heap.cc:
RBTree
sql/ha_myisam.cc:
RBTree
sql/item_sum.cc:
custom_arg
sql/sql_analyse.cc:
custom_arg
sql/sql_class.h:
custom_arg
sql/sql_table.cc:
Remove duplicate code
sql/sql_yacc.yy:
UNDEF by default
sql/table.cc:
Remove dirty hack
Diffstat (limited to 'isam')
-rw-r--r-- | isam/isamlog.c | 6 | ||||
-rw-r--r-- | isam/pack_isam.c | 6 |
2 files changed, 7 insertions, 5 deletions
diff --git a/isam/isamlog.c b/isam/isamlog.c index 6d2bde42bf7..3c38caaf141 100644 --- a/isam/isamlog.c +++ b/isam/isamlog.c @@ -342,7 +342,7 @@ static int examine_log(my_string file_name, char **table_names) file_info.process=0; result=uint2korr(head+7); if ((curr_file_info=(struct isamlog_file_info*) - tree_search(&tree,&file_info))) + tree_search(&tree, &file_info, tree.custom_arg))) { curr_file_info->accessed=access_time; if (update && curr_file_info->used && curr_file_info->closed) @@ -444,7 +444,7 @@ static int examine_log(my_string file_name, char **table_names) files_open++; file_info.closed=0; } - VOID(tree_insert(&tree,(gptr) &file_info,0)); + VOID(tree_insert(&tree, (gptr) &file_info, 0, tree.custom_arg)); if (file_info.used) { if (verbose && !record_pos_file) @@ -463,7 +463,7 @@ static int examine_log(my_string file_name, char **table_names) { if (!curr_file_info->closed) files_open--; - VOID(tree_delete(&tree,(gptr) curr_file_info)); + VOID(tree_delete(&tree, (gptr) curr_file_info, tree.custom_arg)); } break; case LOG_EXTRA: diff --git a/isam/pack_isam.c b/isam/pack_isam.c index 4a3a787ff5c..6122a4e6024 100644 --- a/isam/pack_isam.c +++ b/isam/pack_isam.c @@ -762,7 +762,8 @@ static int get_statistic(MRG_INFO *mrg,HUFF_COUNTS *huff_counts) if (count->tree_buff) { global_count=count; - if (!(element=tree_insert(&count->int_tree,pos,0)) || + if (!(element=tree_insert(&count->int_tree, pos, 0, + count->int_tree.custom_arg)) || ((element->count == 1 && count->tree_buff + tree_buff_length < count->tree_pos + count->field_length) || @@ -1733,7 +1734,8 @@ static int compress_isam_file(MRG_INFO *mrg, HUFF_COUNTS *huff_counts) break; case FIELD_INTERVALL: global_count=count; - pos=(byte*) tree_search(&count->int_tree,start_pos); + pos=(byte*) tree_search(&count->int_tree, start_pos, + count->int_tree.custom_arg); intervall=(uint) (pos - count->tree_buff)/field_length; write_bits(tree->code[intervall],(uint) tree->code_len[intervall]); start_pos=end_pos; |