Lines Matching refs:table

66 __collate_load_tables_l(const char *encoding, struct xlocale_collate *table);
71 struct xlocale_collate *table = t; in destruct_collate() local
72 if (table->map && (table->maplen > 0)) { in destruct_collate()
73 (void) munmap(table->map, table->maplen); in destruct_collate()
84 struct xlocale_collate *table = calloc(sizeof(struct xlocale_collate), 1); in __collate_load() local
85 table->header.header.destructor = destruct_collate; in __collate_load()
88 if (__collate_load_tables_l(encoding, table) != _LDP_LOADED) { in __collate_load()
89 xlocale_release(table); in __collate_load()
92 return table; in __collate_load()
105 __collate_load_tables_l(const char *encoding, struct xlocale_collate *table) in __collate_load_tables_l() argument
115 table->__collate_load_error = 1; in __collate_load_tables_l()
172 table->info = info; in __collate_load_tables_l()
173 table->char_pri_table = (void *)TMP; in __collate_load_tables_l()
178 table->subst_table[z] = (void *)TMP; in __collate_load_tables_l()
181 table->subst_table[z] = NULL; in __collate_load_tables_l()
186 table->chain_pri_table = (void *)TMP; in __collate_load_tables_l()
189 table->chain_pri_table = NULL; in __collate_load_tables_l()
191 table->large_pri_table = (void *)TMP; in __collate_load_tables_l()
193 table->large_pri_table = NULL; in __collate_load_tables_l()
195 table->__collate_load_error = 0; in __collate_load_tables_l()
200 substsearch(struct xlocale_collate *table, const wchar_t key, int pass) in substsearch() argument
203 int n = table->info->subst_count[pass]; in substsearch()
208 if (pass >= table->info->directive_count) in substsearch()
214 p = table->subst_table[pass] + (key & ~COLLATE_SUBST_PRIORITY); in substsearch()
220 chainsearch(struct xlocale_collate *table, const wchar_t *key, int *len) in chainsearch() argument
223 int high = table->info->chain_count - 1;; in chainsearch()
226 collate_chain_t *tab = table->chain_pri_table; in chainsearch()
252 largesearch(struct xlocale_collate *table, const wchar_t key) in largesearch() argument
255 int high = table->info->large_count - 1; in largesearch()
258 collate_large_t *tab = table->large_pri_table; in largesearch()
278 _collate_lookup(struct xlocale_collate *table, const wchar_t *t, int *len, in _collate_lookup() argument
290 if (which >= table->info->directive_count) { in _collate_lookup()
319 if (((p2 = chainsearch(table, t, &l)) != NULL) && in _collate_lookup()
331 *pri = table->char_pri_table[*t].pri[which]; in _collate_lookup()
333 } else if ((table->info->large_count > 0) && in _collate_lookup()
334 ((match = largesearch(table, *t)) != NULL)) { in _collate_lookup()
345 if (table->info->directive[which] & DIRECTIVE_UNDEFINED) { in _collate_lookup()
349 *pri = table->info->undef_pri[which]; in _collate_lookup()
367 if ((sptr = substsearch(table, *pri, which)) != NULL) { in _collate_lookup()
381 _collate_wxfrm(struct xlocale_collate *table, const wchar_t *src, wchar_t *xf, in _collate_wxfrm() argument
393 int ndir = table->info->directive_count; in _collate_wxfrm()
414 direc = table->info->directive[pass]; in _collate_wxfrm()
439 _collate_lookup(table, t, &len, &pri, pass, &state); in _collate_wxfrm()
458 _collate_lookup(table, t, &len, &pri, pass, &state); in _collate_wxfrm()
510 xfrm(struct xlocale_collate *table, unsigned char *p, int pri, int pass) in xfrm() argument
513 uint32_t val = (uint32_t)table->info->pri_count[pass]; in xfrm()
527 _collate_sxfrm(struct xlocale_collate *table, const wchar_t *src, char *xf, in _collate_sxfrm() argument
541 int ndir = table->info->directive_count; in _collate_sxfrm()
562 direc = table->info->directive[pass]; in _collate_sxfrm()
588 _collate_lookup(table, t, &len, &pri, pass, &state); in _collate_sxfrm()
599 b = xfrm(table, buf, pri, pass); in _collate_sxfrm()
614 _collate_lookup(table, t, &len, &pri, pass, &state); in _collate_sxfrm()
625 b = xfrm(table, buf, pri, pass); in _collate_sxfrm()
664 struct xlocale_collate *table = in __collate_equiv_value() local
667 if (table->__collate_load_error) in __collate_equiv_value()
673 e = table->char_pri_table[*str].pri[0]; in __collate_equiv_value()
674 else if (table->info->large_count > 0) { in __collate_equiv_value()
676 match_large = largesearch(table, *str); in __collate_equiv_value()
684 if (table->info->chain_count > 0) { in __collate_equiv_value()
691 match_chain = chainsearch(table, name, &clen); in __collate_equiv_value()