Lines Matching refs:hash

3 #define	FICL_ASSERT_PHASH(hash, expression)	FICL_ASSERT(NULL, expression)  argument
12 ficlHashForget(ficlHash *hash, void *where) in ficlHashForget() argument
17 FICL_ASSERT_PHASH(hash, hash); in ficlHashForget()
18 FICL_ASSERT_PHASH(hash, where); in ficlHashForget()
20 for (i = 0; i < hash->size; i++) { in ficlHashForget()
21 pWord = hash->table[i]; in ficlHashForget()
27 hash->table[i] = pWord; in ficlHashForget()
70 ficlHashInsertWord(ficlHash *hash, ficlWord *word) in ficlHashInsertWord() argument
74 FICL_ASSERT_PHASH(hash, hash); in ficlHashInsertWord()
75 FICL_ASSERT_PHASH(hash, word); in ficlHashInsertWord()
77 if (hash->size == 1) { in ficlHashInsertWord()
78 pList = hash->table; in ficlHashInsertWord()
80 pList = hash->table + (word->hash % hash->size); in ficlHashInsertWord()
97 ficlHashLookup(ficlHash *hash, ficlString name, ficlUnsigned16 hashCode) in ficlHashLookup() argument
106 for (; hash != NULL; hash = hash->link) { in ficlHashLookup()
107 if (hash->size > 1) in ficlHashLookup()
108 hashIdx = (ficlUnsigned16)(hashCode % hash->size); in ficlHashLookup()
112 for (word = hash->table[hashIdx]; word; word = word->link) { in ficlHashLookup()
117 FICL_ASSERT_PHASH(hash, word != word->link); in ficlHashLookup()
130 ficlHashReset(ficlHash *hash) in ficlHashReset() argument
134 FICL_ASSERT_PHASH(hash, hash); in ficlHashReset()
136 for (i = 0; i < hash->size; i++) { in ficlHashReset()
137 hash->table[i] = NULL; in ficlHashReset()
140 hash->link = NULL; in ficlHashReset()
141 hash->name = NULL; in ficlHashReset()