Lines Matching refs:patlen
57 unsigned int patlen; member
67 int shift = bm->patlen - 1, bs; in bm_find()
79 for (i = 0; i < bm->patlen; i++) in bm_find()
82 != bm->pattern[bm->patlen-1-i]) in bm_find()
87 return consumed += (shift-(bm->patlen-1)); in bm_find()
123 bm->bad_shift[i] = bm->patlen; in compute_prefix_tbl()
124 for (i = 0; i < bm->patlen - 1; i++) { in compute_prefix_tbl()
125 bm->bad_shift[bm->pattern[i]] = bm->patlen - 1 - i; in compute_prefix_tbl()
128 = bm->patlen - 1 - i; in compute_prefix_tbl()
134 for (i = 1; i < bm->patlen; i++) in compute_prefix_tbl()
135 bm->good_shift[i] = bm->patlen; in compute_prefix_tbl()
136 for (i = bm->patlen-1, g = 1; i > 0; g++, i--) { in compute_prefix_tbl()
139 bm->good_shift[g] = bm->patlen-j-g; in compute_prefix_tbl()
160 bm->patlen = len; in bm_init()
181 return bm->patlen; in bm_get_pattern_len()