/kernel/linux/linux-5.10/fs/ubifs/ |
H A D | key.h | 21 * 4KiB offset in case of inode node, and direntry hash in case of a direntry 22 * node. We use "r5" hash borrowed from reiserfs. 35 * key_mask_hash - mask a valid hash value. 38 * We use hash values as offset in directories, so values %0 and %1 are 42 static inline uint32_t key_mask_hash(uint32_t hash) in key_mask_hash() argument 44 hash &= UBIFS_S_KEY_HASH_MASK; in key_mask_hash() 45 if (unlikely(hash <= 2)) in key_mask_hash() 46 hash += 3; in key_mask_hash() 47 return hash; in key_mask_hash() 51 * key_r5_hash - R5 hash functio 150 uint32_t hash = c->key_hash(fname_name(nm), fname_len(nm)); dent_key_init() local 165 dent_key_init_hash(const struct ubifs_info *c, union ubifs_key *key, ino_t inum, uint32_t hash) dent_key_init_hash() argument 186 uint32_t hash = c->key_hash(fname_name(nm), fname_len(nm)); dent_key_init_flash() local 219 uint32_t hash = c->key_hash(fname_name(nm), fname_len(nm)); xent_key_init() local 237 uint32_t hash = c->key_hash(fname_name(nm), fname_len(nm)); xent_key_init_flash() local [all...] |
/kernel/linux/linux-6.6/fs/ubifs/ |
H A D | key.h | 21 * 4KiB offset in case of inode node, and direntry hash in case of a direntry 22 * node. We use "r5" hash borrowed from reiserfs. 35 * key_mask_hash - mask a valid hash value. 38 * We use hash values as offset in directories, so values %0 and %1 are 42 static inline uint32_t key_mask_hash(uint32_t hash) in key_mask_hash() argument 44 hash &= UBIFS_S_KEY_HASH_MASK; in key_mask_hash() 45 if (unlikely(hash <= 2)) in key_mask_hash() 46 hash += 3; in key_mask_hash() 47 return hash; in key_mask_hash() 51 * key_r5_hash - R5 hash functio 150 uint32_t hash = c->key_hash(fname_name(nm), fname_len(nm)); dent_key_init() local 165 dent_key_init_hash(const struct ubifs_info *c, union ubifs_key *key, ino_t inum, uint32_t hash) dent_key_init_hash() argument 186 uint32_t hash = c->key_hash(fname_name(nm), fname_len(nm)); dent_key_init_flash() local 219 uint32_t hash = c->key_hash(fname_name(nm), fname_len(nm)); xent_key_init() local 237 uint32_t hash = c->key_hash(fname_name(nm), fname_len(nm)); xent_key_init_flash() local [all...] |
/kernel/linux/linux-5.10/arch/powerpc/crypto/ |
H A D | md5-glue.c | 10 #include <crypto/internal/hash.h> 34 sctx->hash[0] = MD5_H0; in ppc_md5_init() 35 sctx->hash[1] = MD5_H1; in ppc_md5_init() 36 sctx->hash[2] = MD5_H2; in ppc_md5_init() 37 sctx->hash[3] = MD5_H3; in ppc_md5_init() 60 ppc_md5_transform(sctx->hash, (const u8 *)sctx->block, 1); in ppc_md5_update() 66 ppc_md5_transform(sctx->hash, src, len >> 6); in ppc_md5_update() 89 ppc_md5_transform(sctx->hash, src, 1); in ppc_md5_final() 96 ppc_md5_transform(sctx->hash, src, 1); in ppc_md5_final() 98 dst[0] = cpu_to_le32(sctx->hash[ in ppc_md5_final() [all...] |
/kernel/linux/linux-6.6/arch/powerpc/crypto/ |
H A D | md5-glue.c | 10 #include <crypto/internal/hash.h> 34 sctx->hash[0] = MD5_H0; in ppc_md5_init() 35 sctx->hash[1] = MD5_H1; in ppc_md5_init() 36 sctx->hash[2] = MD5_H2; in ppc_md5_init() 37 sctx->hash[3] = MD5_H3; in ppc_md5_init() 60 ppc_md5_transform(sctx->hash, (const u8 *)sctx->block, 1); in ppc_md5_update() 66 ppc_md5_transform(sctx->hash, src, len >> 6); in ppc_md5_update() 89 ppc_md5_transform(sctx->hash, src, 1); in ppc_md5_final() 96 ppc_md5_transform(sctx->hash, src, 1); in ppc_md5_final() 98 dst[0] = cpu_to_le32(sctx->hash[ in ppc_md5_final() [all...] |
/kernel/linux/linux-6.6/crypto/ |
H A D | ahash.c | 5 * This is the asynchronous version of hash.c with notification of 22 #include "hash.h" 416 struct crypto_ahash *hash = __crypto_ahash_cast(tfm); in crypto_ahash_exit_tfm() local 417 struct ahash_alg *alg = crypto_ahash_alg(hash); in crypto_ahash_exit_tfm() 419 alg->exit_tfm(hash); in crypto_ahash_exit_tfm() 424 struct crypto_ahash *hash = __crypto_ahash_cast(tfm); in crypto_ahash_init_tfm() local 425 struct ahash_alg *alg = crypto_ahash_alg(hash); in crypto_ahash_init_tfm() 427 hash->setkey = ahash_nosetkey; in crypto_ahash_init_tfm() 429 crypto_ahash_set_statesize(hash, alg->halg.statesize); in crypto_ahash_init_tfm() 434 hash in crypto_ahash_init_tfm() 542 crypto_clone_ahash(struct crypto_ahash *hash) crypto_clone_ahash() argument [all...] |
/third_party/node/test/parallel/ |
H A D | test-webcrypto-export-import-rsa.js | 302 async function testImportSpki({ name, publicUsages }, size, hash, extractable) { 306 { name, hash }, 317 assert.strictEqual(key.algorithm.hash.name, hash); 335 hash, 340 { name, hash }, 351 assert.strictEqual(key.algorithm.hash.name, hash); 369 { name, hash }, 378 hash, [all...] |
/third_party/protobuf/java/core/src/main/java/com/google/protobuf/ |
H A D | AbstractMessage.java | 160 int hash = memoizedHashCode; in hashCode() 161 if (hash == 0) { in hashCode() 162 hash = 41; in hashCode() 163 hash = (19 * hash) + getDescriptorForType().hashCode(); in hashCode() 164 hash = hashFields(hash, getAllFields()); in hashCode() 165 hash = (29 * hash) + getUnknownFields().hashCode(); in hashCode() 166 memoizedHashCode = hash; in hashCode() 283 hashFields(int hash, Map<FieldDescriptor, Object> map) hashFields() argument [all...] |
/third_party/python/Python/ |
H A D | pyhash.c | 1 /* Set of hash utility functions to help maintaining the invariant that 2 if a==b then hash(a)==hash(b) 34 /* For numeric types, the hash of a number x is based on the reduction 36 hash(x) == hash(y) whenever x and y are numerically equal, even if 51 (2) Now for a rational number x, define hash(x) by: 57 integers, floats and Decimals) then use the predefined hash value 62 NaNs hash with a pointer hash 176 Py_uhash_t hash; _Py_HashBytes() local [all...] |
/kernel/liteos_a/fs/vfs/ |
H A D | vnode_hash.c | 53 PRINT_ERR("Create mutex for vnode hash list fail, status: %d", ret); in VnodeHashInit() 81 return (vnode->hash + vnode->originMount->hashseed); in VfsHashIndex() 84 static LOS_DL_LIST *VfsHashBucket(const struct Mount *mp, uint32_t hash) in VfsHashBucket() argument 86 return (&g_vnodeHashEntrys[(hash + mp->hashseed) & g_vnodeHashMask]); in VfsHashBucket() 89 int VfsHashGet(const struct Mount *mount, uint32_t hash, struct Vnode **vnode, VfsHashCmp *fn, void *arg) in VfsHashGet() argument 98 LOS_DL_LIST *list = VfsHashBucket(mount, hash); in VfsHashGet() 100 if (curVnode->hash != hash) { in VfsHashGet() 128 int VfsHashInsert(struct Vnode *vnode, uint32_t hash) in VfsHashInsert() argument 134 vnode->hash in VfsHashInsert() [all...] |
/third_party/json/include/nlohmann/detail/ |
H A D | hash.hpp | 13 #include <functional> // hash 30 @brief hash a JSON value 32 The hash function tries to rely on std::hash where possible. Furthermore, the 33 type of the JSON value is taken into account to have different hash values for 37 @param j JSON value to hash 38 @return hash value of j 41 std::size_t hash(const BasicJsonType& j) in hash() function 62 const auto h = std::hash<string_t> {}(element.key()); in hash() 64 seed = combine(seed, hash(elemen in hash() [all...] |
/third_party/node/lib/internal/crypto/ |
H A D | mac.js | 45 const { hash, name } = algorithm; 49 length = getBlockSize(hash.name); 68 { name, length, hash: { name: hash.name } }, 73 function getAlgorithmName(hash) { 74 switch (hash) { 79 return `HS${hash.slice(4)}`; 141 if (keyData.alg !== getAlgorithmName(algorithm.hash.name)) 161 hash: algorithm.hash, [all...] |
/third_party/node/deps/v8/tools/clusterfuzz/js_fuzzer/resources/ |
H A D | differential_fuzz_library.js | 15 // Track a hash of all printed values - printing is cut off after a 77 // Helper for calculating a hash code of a string. 79 let hash = 0; 81 return hash; 85 hash = ((hash << 5) - hash) + char; 86 hash = hash & hash; [all...] |
/kernel/linux/linux-6.6/scripts/basic/ |
H A D | fixdep.c | 111 unsigned int hash; member 120 /* fnv32 hash */ in strhash() 121 unsigned int i, hash = 2166136261U; in strhash() local 124 hash = (hash ^ str[i]) * 0x01000193; in strhash() 125 return hash; in strhash() 131 static void add_to_hashtable(const char *name, int len, unsigned int hash, in add_to_hashtable() argument 142 aux->hash = hash; in add_to_hashtable() 143 aux->next = hashtab[hash in add_to_hashtable() 154 unsigned int hash = strhash(name, len); in_hashtable() local [all...] |
/third_party/mbedtls/programs/ssl/ |
H A D | ssl_test_common_source.c | 273 #define MBEDTLS_SSL_SIG_ALG(hash) ((hash << 8) | MBEDTLS_SSL_SIG_ECDSA), \ 274 ((hash << 8) | MBEDTLS_SSL_SIG_RSA), \ 275 (0x800 | hash), 277 #define MBEDTLS_SSL_SIG_ALG(hash) ((hash << 8) | MBEDTLS_SSL_SIG_ECDSA), \ 278 ((hash << 8) | MBEDTLS_SSL_SIG_RSA), 281 #define MBEDTLS_SSL_SIG_ALG(hash) ((hash << 8) | MBEDTLS_SSL_SIG_ECDSA), 285 #define MBEDTLS_SSL_SIG_ALG(hash) ((has [all...] |
/third_party/mesa3d/src/gallium/auxiliary/cso_cache/ |
H A D | cso_cache.c | 74 struct cso_hash *hash, in sanitize_hash() 79 sc->sanitize_cb(hash, type, max_size, sc->sanitize_data); in sanitize_hash() 83 static inline void sanitize_cb(struct cso_hash *hash, enum cso_cache_type type, in sanitize_cb() argument 90 int hash_size = cso_hash_size(hash); in sanitize_cb() 98 struct cso_hash_iter iter = cso_hash_first_node(hash); in sanitize_cb() 99 void *cso = cso_hash_take(hash, cso_hash_iter_key(iter)); in sanitize_cb() 110 struct cso_hash *hash = _cso_hash_for_type(sc, type); in cso_insert_state() local 111 sanitize_hash(sc, hash, type, sc->max_size); in cso_insert_state() 113 return cso_hash_insert(hash, hash_key, state); in cso_insert_state() 120 struct cso_hash *hash in cso_find_state() local 73 sanitize_hash(struct cso_cache *sc, struct cso_hash *hash, enum cso_cache_type type, int max_size) sanitize_hash() argument 126 cso_hash_find_data_from_template( struct cso_hash *hash, unsigned hash_key, void *templ, int size ) cso_hash_find_data_from_template() argument 175 struct cso_hash *hash = _cso_hash_for_type(sc, type); cso_delete_all() local [all...] |
/third_party/skia/third_party/externals/freetype/src/cache/ |
H A D | ftccache.h | 62 FT_Offset hash; /* used for hashing too */ member 76 #define FTC_NODE_TOP_FOR_HASH( cache, hash ) \ 78 ( ( ( ( hash ) & ( cache )->mask ) < ( cache )->p ) \ 79 ? ( ( hash ) & ( ( cache )->mask * 2 + 1 ) ) \ 80 : ( ( hash ) & ( cache )->mask ) ) ) 84 FT_Offset hash ); 85 #define FTC_NODE_TOP_FOR_HASH( cache, hash ) \ 86 ftc_get_top_node_for_hash( ( cache ), ( hash ) ) 142 /* each cache really implements a dynamic hash table to manage its nodes */ 182 FT_Offset hash, [all...] |
/third_party/vk-gl-cts/framework/delibs/depool/ |
H A D | dePoolHashSet.h | 23 * \brief Memory pool hash-set class. 37 * \brief Declare a template pool hash-set (hash of sets) class interface. 38 * \param TYPENAME Type name of the declared hash-set. 44 * The functions for operating the hash are: 63 TYPENAME##Hash* hash; \ 79 if ((hashSet->hash = TYPENAME##Hash_create(pool)) == DE_NULL) \ 86 return TYPENAME##Hash_getNumElements(hashSet->hash); \ 91 return hashSet->hash; \ 96 TYPENAME##Set** setPtr = TYPENAME##Hash_find(hashSet->hash, ke [all...] |
/kernel/linux/linux-6.6/fs/smb/common/ |
H A D | cifs_md4.c | 54 static void md4_transform(u32 *hash, u32 const *in) in md4_transform() argument 58 a = hash[0]; in md4_transform() 59 b = hash[1]; in md4_transform() 60 c = hash[2]; in md4_transform() 61 d = hash[3]; in md4_transform() 114 hash[0] += a; in md4_transform() 115 hash[1] += b; in md4_transform() 116 hash[2] += c; in md4_transform() 117 hash[3] += d; in md4_transform() 123 md4_transform(ctx->hash, ct in md4_transform_helper() [all...] |
/third_party/mesa3d/src/glx/ |
H A D | glxhash.c | 1 /* glxhash.c -- Small hash table support for integer -> integer mapping 33 * hash table using self-organizing linked lists [Knuth73, pp. 398-399] for 42 * 2) The hash computation uses a table of random integers [Hanson97, 50 * dynamic hash tables was postponed until the need arises. A common (and 51 * naive) approach to dynamic hash table implementation simply creates a 52 * new hash table when necessary, rehashes all the data into the new table, 129 unsigned long hash = 0; in HashHash() local 145 hash = (hash << 1) + scatter[tmp & 0xff]; in HashHash() 149 hash in HashHash() 203 unsigned long hash = HashHash(key); HashFind() local 251 unsigned long hash; __glxHashInsert() local 276 unsigned long hash; __glxHashDelete() local [all...] |
/third_party/nghttp2/lib/ |
H A D | nghttp2_map.c | 94 static uint32_t hash(nghttp2_map_key_type key) { in hash() function 98 static size_t h2idx(uint32_t hash, uint32_t bits) { in h2idx() argument 99 return hash >> (32 - bits); in h2idx() 104 return (idx - h2idx(bkt->hash, tablelenbits)) & (tablelen - 1); in distance() 109 uint32_t h = bkt->hash; in map_bucket_swap() 113 bkt->hash = *phash; in map_bucket_swap() 122 static void map_bucket_set_data(nghttp2_map_bucket *bkt, uint32_t hash, in map_bucket_set_data() argument 124 bkt->hash = hash; in map_bucket_set_data() 143 idx = h2idx(bkt->hash, ma in nghttp2_map_print_distance() 151 insert(nghttp2_map_bucket *table, uint32_t tablelen, uint32_t tablelenbits, uint32_t hash, nghttp2_map_key_type key, void *data) insert() argument [all...] |
/third_party/node/deps/ngtcp2/ngtcp2/lib/ |
H A D | ngtcp2_map.c | 94 static uint32_t hash(ngtcp2_map_key_type key) { in hash() function 98 static size_t h2idx(uint32_t hash, uint32_t bits) { in h2idx() argument 99 return hash >> (32 - bits); in h2idx() 104 return (idx - h2idx(bkt->hash, tablelenbits)) & (tablelen - 1); in distance() 109 uint32_t h = bkt->hash; in map_bucket_swap() 113 bkt->hash = *phash; in map_bucket_swap() 122 static void map_bucket_set_data(ngtcp2_map_bucket *bkt, uint32_t hash, in map_bucket_set_data() argument 124 bkt->hash = hash; in map_bucket_set_data() 142 idx = h2idx(bkt->hash, ma in ngtcp2_map_print_distance() 149 insert(ngtcp2_map_bucket *table, uint32_t tablelen, uint32_t tablelenbits, uint32_t hash, ngtcp2_map_key_type key, void *data) insert() argument [all...] |
/third_party/node/deps/nghttp2/lib/ |
H A D | nghttp2_map.c | 94 static uint32_t hash(nghttp2_map_key_type key) { in hash() function 98 static size_t h2idx(uint32_t hash, uint32_t bits) { in h2idx() argument 99 return hash >> (32 - bits); in h2idx() 104 return (idx - h2idx(bkt->hash, tablelenbits)) & (tablelen - 1); in distance() 109 uint32_t h = bkt->hash; in map_bucket_swap() 113 bkt->hash = *phash; in map_bucket_swap() 122 static void map_bucket_set_data(nghttp2_map_bucket *bkt, uint32_t hash, in map_bucket_set_data() argument 124 bkt->hash = hash; in map_bucket_set_data() 142 idx = h2idx(bkt->hash, ma in nghttp2_map_print_distance() 149 insert(nghttp2_map_bucket *table, uint32_t tablelen, uint32_t tablelenbits, uint32_t hash, nghttp2_map_key_type key, void *data) insert() argument [all...] |
/third_party/node/deps/ngtcp2/nghttp3/lib/ |
H A D | nghttp3_map.c | 95 static uint32_t hash(nghttp3_map_key_type key) { in hash() function 99 static size_t h2idx(uint32_t hash, uint32_t bits) { in h2idx() argument 100 return hash >> (32 - bits); in h2idx() 105 return (idx - h2idx(bkt->hash, tablelenbits)) & (tablelen - 1); in distance() 110 uint32_t h = bkt->hash; in map_bucket_swap() 114 bkt->hash = *phash; in map_bucket_swap() 123 static void map_bucket_set_data(nghttp3_map_bucket *bkt, uint32_t hash, in map_bucket_set_data() argument 125 bkt->hash = hash; in map_bucket_set_data() 143 idx = h2idx(bkt->hash, ma in nghttp3_map_print_distance() 150 insert(nghttp3_map_bucket *table, uint32_t tablelen, uint32_t tablelenbits, uint32_t hash, nghttp3_map_key_type key, void *data) insert() argument [all...] |
/third_party/rust/crates/libc/src/unix/linux_like/android/b64/ |
H A D | mod.rs | 167 impl ::hash::Hash for pthread_mutex_t { 168 fn hash<H: ::hash::Hasher>(&self, state: &mut H) { in hash() functions 169 self.value.hash(state); in hash() 170 self.__reserved.hash(state); in hash() 196 impl ::hash::Hash for pthread_cond_t { 197 fn hash<H: ::hash::Hasher>(&self, state: &mut H) { in hash() functions 198 self.value.hash(state); in hash() 199 self.__reserved.hash(stat in hash() 234 fn hash<H: ::hash::Hasher>(&self, state: &mut H) { hash() functions [all...] |
/third_party/node/benchmark/crypto/ |
H A D | hkdf.js | 16 hash: ['sha256', 'sha512'], 20 function measureSync(n, size, salt, info, hash, key) { 23 hkdfSync(hash, key, salt, info, size); 27 function measureAsync(n, size, salt, info, hash, key) { 36 hkdf(hash, key, salt, info, size, done); 39 function main({ n, sync, size, salt, info, hash, key }) { 41 measureSync(n, size, salt, info, hash, key); 43 measureAsync(n, size, salt, info, hash, key);
|