From d0f1d4a75e7fdff18f2f870336322e67c3d3eb6b Mon Sep 17 00:00:00 2001 From: unknown Date: Tue, 21 Jan 2003 19:24:34 +0100 Subject: Two-level index structure for FULLTEXT indexes myisam/ftdefs.h: intermediate cleanup checkin myisam/mi_create.c: intermediate cleanup checkin myisam/myisamchk.c: intermediate cleanup checkin myisam/ft_parser.c: intermediate cleanup checkin myisam/ft_update.c: intermediate cleanup checkin myisam/mi_update.c: intermediate cleanup checkin mysql-test/r/fulltext.result: stopword test mysql-test/t/fulltext.test: stopword test mysys/mulalloc.c: function comments clarified include/my_handler.h: get_key_length_rdonly utility macro include/myisam.h: this kind of hacks bites :) myisam/ft_dump.c: bugfix myisam/mi_open.c: bugfix myisam/sort.c: bugfixing myisam/mi_rnext.c: not a solution at all, but a temporary fix to make mi_rnext to work on ft2 index. (only ft_dump uses mi_rnext on fulltext indexes for now). myisam/ft_boolean_search.c: ft_sintXkorr, ft_intXstore myisam/ft_nlq_search.c: ft_sintXkorr, ft_intXstore myisam/fulltext.h: ft_sintXkorr, ft_intXstore myisam/mi_check.c: ft_sintXkorr, ft_intXstore myisam/ft_static.c: two-level tree support in wi_write() myisam/mi_write.c: two-level tree support in wi_write() myisam/myisamdef.h: two-level tree support in wi_write() myisam/mi_delete.c: support for ft2 in mi_delete mysql-test/r/fulltext2.result: support for ft2 in mi_delete mysql-test/t/fulltext2.test: support for ft2 in mi_delete --- myisam/ft_parser.c | 32 -------------------------------- 1 file changed, 32 deletions(-) (limited to 'myisam/ft_parser.c') diff --git a/myisam/ft_parser.c b/myisam/ft_parser.c index 358706a8ffa..14c67333734 100644 --- a/myisam/ft_parser.c +++ b/myisam/ft_parser.c @@ -18,21 +18,10 @@ #include "ftdefs.h" -#ifdef EVAL_RUN -#ifdef PIVOT_STAT -ulong collstat=0; -#endif -#endif /* EVAL_RUN */ - typedef struct st_ft_docstat { FT_WORD *list; uint uniq; double sum; -#ifdef EVAL_RUN - uint words, totlen; - double max, nsum, nsum2; -#endif /* EVAL_RUN */ - } FT_DOCSTAT; static int FT_WORD_cmp(CHARSET_INFO* cs, FT_WORD *w1, FT_WORD *w2) @@ -44,15 +33,7 @@ static int FT_WORD_cmp(CHARSET_INFO* cs, FT_WORD *w1, FT_WORD *w2) static int walk_and_copy(FT_WORD *word,uint32 count,FT_DOCSTAT *docstat) { word->weight=LWS_IN_USE; - -#ifdef EVAL_RUN - word->cnt= (uchar) count; - if(docstat->max < word->weight) docstat->max=word->weight; - docstat->words+=count; - docstat->totlen+=word->len; -#endif /* EVAL_RUN */ docstat->sum+=word->weight; - memcpy_fixed((docstat->list)++,word,sizeof(FT_WORD)); return 0; } @@ -70,9 +51,6 @@ FT_WORD * ft_linearize(TREE *wtree) { docstat.list=wlist; docstat.uniq=wtree->elements_in_tree; -#ifdef EVAL_RUN - docstat.nsum=docstat.nsum2=docstat.max=docstat.words=docstat.totlen= -#endif /* EVAL_RUN */ docstat.sum=0; tree_walk(wtree,(tree_walk_action)&walk_and_copy,&docstat,left_root_right); } @@ -85,18 +63,8 @@ FT_WORD * ft_linearize(TREE *wtree) for (p=wlist;p->pos;p++) { p->weight=PRENORM_IN_USE; -#ifdef EVAL_RUN - docstat.nsum+=p->weight; - docstat.nsum2+=p->weight*p->weight; -#endif /* EVAL_RUN */ } -#ifdef EVAL_RUN -#ifdef PIVOT_STAT - collstat+=PIVOT_STAT; -#endif -#endif /* EVAL_RUN */ - for (p=wlist;p->pos;p++) { p->weight/=NORM_IN_USE; -- cgit v1.2.1