Home
last modified time | relevance | path

Searched refs:key (Results 1 – 25 of 37) sorted by relevance

12

/bionic/libc/bionic/
Dpthread_key.cpp65 static inline bool KeyInValidRange(pthread_key_t key) { in KeyInValidRange() argument
68 return (key < (KEY_VALID_FLAG | BIONIC_PTHREAD_KEY_COUNT)); in KeyInValidRange()
118 int pthread_key_create(pthread_key_t* key, void (*key_destructor)(void*)) { in pthread_key_create() argument
124 *key = i | KEY_VALID_FLAG; in pthread_key_create()
136 int pthread_key_delete(pthread_key_t key) { in pthread_key_delete() argument
137 if (__predict_false(!KeyInValidRange(key))) { in pthread_key_delete()
140 key &= ~KEY_VALID_FLAG; in pthread_key_delete()
142 uintptr_t seq = atomic_load_explicit(&key_map[key].seq, memory_order_relaxed); in pthread_key_delete()
144 if (atomic_compare_exchange_strong(&key_map[key].seq, &seq, seq + SEQ_INCREMENT_STEP)) { in pthread_key_delete()
151 void* pthread_getspecific(pthread_key_t key) { in pthread_getspecific() argument
[all …]
Dtdestroy.cpp34 (*destroy_func)(root_node->key); in tdestroy()
/bionic/libc/upstream-openbsd/lib/libc/stdlib/
Dlsearch.c44 lsearch(const void *key, void *base, size_t *nelp, size_t width, in lsearch() argument
48 return(linear_base(key, base, nelp, width, compar, 1)); in lsearch()
52 lfind(const void *key, const void *base, size_t *nelp, size_t width, in lfind() argument
55 return(linear_base(key, base, nelp, width, compar, 0)); in lfind()
59 linear_base(const void *key, const void *base, size_t *nelp, size_t width, in linear_base() argument
66 if (!compar(key, element)) /* key found */ in linear_base()
82 memcpy((void *)end, key, width); in linear_base()
Dtfind.c18 char *key; member
27 char *key = (char *)vkey; in tfind() local
34 if ((r = (*compar)(key, (*rootp)->key)) == 0) /* T2: */ in tfind()
Dtsearch.c19 char *key; member
29 char *key = (char *)vkey; in tsearch() local
37 if ((r = (*compar)(key, (*rootp)->key)) == 0) /* T2: */ in tsearch()
46 q->key = key; /* initialize new node */ in tsearch()
58 char *key = (char *)vkey; in tdelete() local
66 while ((cmp = (*compar)(key, (*rootp)->key)) != 0) { in tdelete()
/bionic/libc/malloc_debug/tests/
Dproperty_fake.cpp34 extern "C" int property_get(const char* key, char* value, const char* default_value) { in property_get() argument
35 if (g_properties.count(key) == 0) { in property_get()
41 strncpy(value, g_properties[key].c_str(), PROP_VALUE_MAX-1); in property_get()
47 extern "C" int __system_property_get(const char* key, char* value) { in __system_property_get() argument
48 if (g_properties.count(key) == 0) { in __system_property_get()
51 strncpy(value, g_properties[key].c_str(), PROP_VALUE_MAX-1); in __system_property_get()
/bionic/libc/upstream-netbsd/lib/libc/resolv/
Dmtctxres.c15 static pthread_key_t key; variable
38 pthread_keycreate_ret = pthread_key_create(&key, __res_destroy_ctx); in _mtctxres_init()
67 if (pthread_getspecific(key) != 0) { in __res_init_ctx()
79 if ((ret = pthread_setspecific(key, mt)) != 0) { in __res_init_ctx()
122 if (((mt = pthread_getspecific(key)) != 0) || in ___mtctxres()
124 (mt = pthread_getspecific(key)) != 0)) { in ___mtctxres()
/bionic/benchmarks/
Dpthread_benchmark.cpp32 pthread_key_t key; in BM_pthread_getspecific() local
33 pthread_key_create(&key, NULL); in BM_pthread_getspecific()
36 pthread_getspecific(key); in BM_pthread_getspecific()
39 pthread_key_delete(key); in BM_pthread_getspecific()
44 pthread_key_t key; in BM_pthread_setspecific() local
45 pthread_key_create(&key, NULL); in BM_pthread_setspecific()
48 pthread_setspecific(key, NULL); in BM_pthread_setspecific()
51 pthread_key_delete(key); in BM_pthread_setspecific()
173 pthread_key_t key; in BM_pthread_key_create() local
174 pthread_key_create(&key, NULL); in BM_pthread_key_create()
[all …]
/bionic/libc/upstream-netbsd/lib/libc/stdlib/
Dbsearch.c62 bsearch(const void *key, const void *base0, size_t nmemb, size_t size, in bsearch() argument
70 _DIAGASSERT(key != NULL); in bsearch()
76 cmp = (*compar)(key, p); in bsearch()
/bionic/libc/kernel/uapi/linux/
Dagpgart.h81 int key; member
89 int key; member
94 int key; member
Dpr.h32 __u64 key; member
54 __u64 key; member
Dipc.h25 __kernel_key_t key; member
Dbcache.h58 #define BKEY_PADDED(key) union { struct bkey key; __u64 key ##_pad[BKEY_PAD]; } argument
Dhyperv.h182 __u8 key[HV_KVP_EXCHANGE_MAX_KEY_SIZE]; member
206 __u8 key[HV_KVP_EXCHANGE_MAX_KEY_SIZE]; member
Dbpf.h116 __aligned_u64 key; member
/bionic/libc/kernel/uapi/asm-generic/
Dipcbuf.h22 __kernel_key_t key; member
/bionic/libc/include/sys/
Dsystem_properties.h51 int __system_property_set(const char *key, const char *value);
/bionic/libc/include/
Dsearch.h24 char* key; member
/bionic/libc/kernel/uapi/linux/netfilter/
Dnf_conntrack_tuple_common.h50 __be16 key; member
/bionic/tests/
Dpthread_test.cpp43 pthread_key_t key; in TEST() local
44 ASSERT_EQ(0, pthread_key_create(&key, NULL)); in TEST()
45 ASSERT_EQ(0, pthread_key_delete(key)); in TEST()
47 ASSERT_EQ(EINVAL, pthread_key_delete(key)); in TEST()
67 for (const auto& key : keys) { in TEST() local
68 EXPECT_EQ(0, pthread_key_delete(key)); in TEST()
73 pthread_key_t key; in TEST() local
75 ASSERT_EQ(0, pthread_key_create(&key, NULL)) << i << " of " << nkeys; in TEST()
76 keys.push_back(key); in TEST()
77 ASSERT_EQ(0, pthread_setspecific(key, reinterpret_cast<void*>(i))); in TEST()
[all …]
/bionic/libc/dns/resolv/
Dres_cache.c1281 _cache_check_pending_request_locked( struct resolv_cache** cache, Entry* key, unsigned netid ) in _cache_check_pending_request_locked() argument
1286 if (*cache && key) { in _cache_check_pending_request_locked()
1290 if (ri->hash == key->hash) { in _cache_check_pending_request_locked()
1301 ri->hash = key->hash; in _cache_check_pending_request_locked()
1321 _cache_notify_waiting_tid_locked( struct resolv_cache* cache, Entry* key ) in _cache_notify_waiting_tid_locked() argument
1325 if (cache && key) { in _cache_notify_waiting_tid_locked()
1329 if (ri->hash == key->hash) { in _cache_notify_waiting_tid_locked()
1352 Entry key[1]; in _resolv_cache_query_failed() local
1355 if (!entry_init_key(key, query, querylen)) in _resolv_cache_query_failed()
1363 _cache_notify_waiting_tid_locked(cache, key); in _resolv_cache_query_failed()
[all …]
Dres_data.c239 res_sendsigned(const u_char *buf, int buflen, ns_tsig_key *key, in res_sendsigned() argument
247 return (res_nsendsigned(&_nres, buf, buflen, key, ans, anssiz)); in res_sendsigned()
/bionic/libc/kernel/uapi/sound/
Dasound_fm.h100 char key[4]; member
Dcompress_offload.h81 __u32 key; member
Dsfnt_info.h30 unsigned short key; member

12