/bionic/libc/bionic/ |
D | pthread_key.cpp | 66 static inline bool KeyInValidRange(pthread_key_t key) { in KeyInValidRange() argument 69 return (key < (KEY_VALID_FLAG | BIONIC_PTHREAD_KEY_COUNT)); in KeyInValidRange() 124 int pthread_key_create(pthread_key_t* key, void (*key_destructor)(void*)) { in pthread_key_create() argument 130 *key = i | KEY_VALID_FLAG; in pthread_key_create() 143 int pthread_key_delete(pthread_key_t key) { in pthread_key_delete() argument 144 if (__predict_false(!KeyInValidRange(key))) { in pthread_key_delete() 147 key &= ~KEY_VALID_FLAG; in pthread_key_delete() 149 uintptr_t seq = atomic_load_explicit(&key_map[key].seq, memory_order_relaxed); in pthread_key_delete() 151 if (atomic_compare_exchange_strong(&key_map[key].seq, &seq, seq + SEQ_INCREMENT_STEP)) { in pthread_key_delete() 159 void* pthread_getspecific(pthread_key_t key) { in pthread_getspecific() argument [all …]
|
D | system_property_set.cpp | 276 int __system_property_set(const char* key, const char* value) { in __system_property_set() argument 277 if (key == nullptr) return -1; in __system_property_set() 286 if (strlen(key) >= PROP_NAME_MAX) return -1; in __system_property_set() 292 strlcpy(msg.name, key, sizeof msg.name); in __system_property_set() 298 if (strlen(value) >= PROP_VALUE_MAX && strncmp(key, "ro.", 3) != 0) return -1; in __system_property_set() 300 PropertyServiceConnection connection(key); in __system_property_set() 304 "Unable to set property \"%s\" to \"%s\": connection failed: %m", key, in __system_property_set() 310 if (!writer.WriteUint32(PROP_MSG_SETPROP2).WriteString(key).WriteString(value).Send()) { in __system_property_set() 313 "Unable to set property \"%s\" to \"%s\": write failed: %m", key, in __system_property_set() 322 "Unable to set property \"%s\" to \"%s\": recv failed: %m", key, value); in __system_property_set() [all …]
|
D | sys_shm.cpp | 67 int shmget(key_t key, size_t size, int flags) { in shmget() argument 69 return syscall(SYS_shmget, key, size, flags); in shmget() 71 return syscall(SYS_ipc, SHMGET, key, size, flags, 0, 0); in shmget()
|
D | sys_msg.cpp | 46 int msgget(key_t key, int flags) { in msgget() argument 48 return syscall(SYS_msgget, key, flags); in msgget() 50 return syscall(SYS_ipc, MSGGET, key, flags, 0, 0, 0); in msgget()
|
D | sys_sem.cpp | 51 int semget(key_t key, int n, int flags) { in semget() argument 53 return syscall(SYS_semget, key, n, flags); in semget() 55 return syscall(SYS_ipc, SEMGET, key, n, flags, 0, 0); in semget()
|
D | tdestroy.cpp | 21 char* key; member 39 (*destroy_func)(root_node->key); in tdestroy()
|
/bionic/tests/ |
D | sys_hwprobe_test.cpp | 100 riscv_hwprobe probes[] = {{.key = RISCV_HWPROBE_KEY_IMA_EXT_0}, in TEST() 101 {.key = RISCV_HWPROBE_KEY_CPUPERF_0}}; in TEST() 103 EXPECT_EQ(RISCV_HWPROBE_KEY_IMA_EXT_0, probes[0].key); in TEST() 111 EXPECT_EQ(RISCV_HWPROBE_KEY_CPUPERF_0, probes[1].key); in TEST() 120 riscv_hwprobe probes_vdso[] = {{.key = RISCV_HWPROBE_KEY_IMA_EXT_0}, in TEST() 121 {.key = RISCV_HWPROBE_KEY_CPUPERF_0}}; in TEST() 124 riscv_hwprobe probes_syscall[] = {{.key = RISCV_HWPROBE_KEY_IMA_EXT_0}, in TEST() 125 {.key = RISCV_HWPROBE_KEY_CPUPERF_0}}; in TEST() 129 EXPECT_EQ(RISCV_HWPROBE_KEY_IMA_EXT_0, probes_syscall[0].key); in TEST() 130 EXPECT_EQ(probes_vdso[0].key, probes_syscall[0].key); in TEST() [all …]
|
D | search_test.cpp | 221 ASSERT_STREQ(expected_key, reinterpret_cast<char*>(e->key)); in AssertEntry() 230 e = hsearch(ENTRY{.key = const_cast<char*>("a"), .data = const_cast<char*>("A")}, ENTER); in TEST() 232 e = hsearch(ENTRY{.key = const_cast<char*>("aa"), .data = const_cast<char*>("B")}, ENTER); in TEST() 234 e = hsearch(ENTRY{.key = const_cast<char*>("aaa"), .data = const_cast<char*>("C")}, ENTER); in TEST() 238 e = hsearch(ENTRY{.key = const_cast<char*>("aaaa"), .data = nullptr}, FIND); in TEST() 242 e = hsearch(ENTRY{.key = const_cast<char*>("aa"), .data = nullptr}, FIND); in TEST() 246 e = hsearch(ENTRY{.key = const_cast<char*>("aa"), .data = const_cast<char*>("X")}, ENTER); in TEST() 251 e = hsearch(ENTRY{.key = const_cast<char*>("aa"), .data = nullptr}, FIND); in TEST() 254 e = hsearch(ENTRY{.key = const_cast<char*>("a"), .data = nullptr}, FIND); in TEST() 256 e = hsearch(ENTRY{.key = const_cast<char*>("aaa"), .data = nullptr}, FIND); in TEST() [all …]
|
D | threads_test.cpp | 462 tss_t key; in TEST() 463 ASSERT_EQ(thrd_success, tss_create(&key, nullptr)); in TEST() 464 tss_delete(key); in TEST() 473 tss_t key; in TEST() 474 ASSERT_EQ(thrd_success, tss_create(&key, dtor)); in TEST() 476 ASSERT_EQ(thrd_success, tss_set(key, strdup("hello"))); in TEST() 477 std::thread([&key] { in TEST() 478 ASSERT_EQ(thrd_success, tss_set(key, strdup("world"))); in TEST() 486 ASSERT_EQ(thrd_success, tss_set(key, strdup("hello"))); in TEST() 493 tss_delete(key); in TEST() [all …]
|
D | sys_shm_test.cpp | 42 key_t key = ftok(dir.path, 1); in TEST() local 43 int id = shmget(key, 1234, IPC_CREAT|0666); in TEST()
|
D | pthread_test.cpp | 54 pthread_key_t key; in TEST() local 55 ASSERT_EQ(0, pthread_key_create(&key, nullptr)); in TEST() 56 ASSERT_EQ(0, pthread_key_delete(key)); in TEST() 58 ASSERT_EQ(EINVAL, pthread_key_delete(key)); in TEST() 78 for (const auto& key : keys) { in TEST() local 79 EXPECT_EQ(0, pthread_key_delete(key)); in TEST() 84 pthread_key_t key; in TEST() local 86 ASSERT_EQ(0, pthread_key_create(&key, nullptr)) << i << " of " << nkeys; in TEST() 87 keys.push_back(key); in TEST() 88 ASSERT_EQ(0, pthread_setspecific(key, reinterpret_cast<void*>(i))); in TEST() [all …]
|
/bionic/benchmarks/ |
D | pthread_benchmark.cpp | 33 pthread_key_t key; in BM_pthread_getspecific() local 34 pthread_key_create(&key, nullptr); in BM_pthread_getspecific() 37 pthread_getspecific(key); in BM_pthread_getspecific() 40 pthread_key_delete(key); in BM_pthread_getspecific() 45 pthread_key_t key; in BM_pthread_setspecific() local 46 pthread_key_create(&key, nullptr); in BM_pthread_setspecific() 49 pthread_setspecific(key, nullptr); in BM_pthread_setspecific() 52 pthread_key_delete(key); in BM_pthread_setspecific() 220 pthread_key_t key; in BM_pthread_key_create() local 221 pthread_key_create(&key, nullptr); in BM_pthread_key_create() [all …]
|
/bionic/libc/upstream-openbsd/lib/libc/stdlib/ |
D | tsearch.c | 18 char *key; member 28 char *key = (char *)vkey; in tsearch() local 36 if ((r = (*compar)(key, (*rootp)->key)) == 0) /* T2: */ in tsearch() 45 q->key = key; /* initialize new node */ in tsearch() 57 char *key = (char *)vkey; in tdelete() local 65 while ((cmp = (*compar)(key, (*rootp)->key)) != 0) { in tdelete()
|
D | lsearch.c | 42 lsearch(const void *key, void *base, size_t *nelp, size_t width, in lsearch() argument 45 void *element = lfind(key, base, nelp, width, compar); in lsearch() 52 element = memmove((char *)base + *nelp * width, key, width); in lsearch() 59 lfind(const void *key, const void *base, size_t *nelp, size_t width, in lfind() argument 66 if (!compar(key, element)) /* key found */ in lfind()
|
D | tfind.c | 17 char *key; member 26 char *key = (char *)vkey; in tfind() local 33 if ((r = (*compar)(key, (*rootp)->key)) == 0) /* T2: */ in tfind()
|
/bionic/libc/kernel/uapi/linux/ |
D | tls.h | 80 unsigned char key[TLS_CIPHER_AES_GCM_128_KEY_SIZE]; member 87 unsigned char key[TLS_CIPHER_AES_GCM_256_KEY_SIZE]; member 94 unsigned char key[TLS_CIPHER_AES_CCM_128_KEY_SIZE]; member 101 unsigned char key[TLS_CIPHER_CHACHA20_POLY1305_KEY_SIZE]; member 108 unsigned char key[TLS_CIPHER_SM4_GCM_KEY_SIZE]; member 115 unsigned char key[TLS_CIPHER_SM4_CCM_KEY_SIZE]; member 122 unsigned char key[TLS_CIPHER_ARIA_GCM_128_KEY_SIZE]; member 129 unsigned char key[TLS_CIPHER_ARIA_GCM_256_KEY_SIZE]; member
|
D | sed-opal.h | 49 __u8 key[OPAL_KEY_MAX]; member 55 struct opal_key key; member 93 struct opal_key key; member 98 struct opal_key key; member 103 struct opal_key key; member 114 struct opal_key key; member 147 struct opal_key key; member
|
D | agpgart.h | 57 int key; member 63 int key; member 67 int key; member
|
D | pr.h | 27 __u64 key; member 44 __u64 key; member
|
/bionic/libc/upstream-freebsd/lib/libc/stdlib/ |
D | hsearch_r.c | 50 if (entry->key == NULL) in hsearch_lookup_free() 83 hash = hsearch_hash(hsearch->offset_basis, item.key); in hsearch_r() 91 if (entry->key == NULL) in hsearch_r() 93 if (strcmp(entry->key, item.key) == 0) { in hsearch_r() 126 if (entry->key != NULL) { in hsearch_r() 128 entry->key); in hsearch_r()
|
/bionic/libc/upstream-netbsd/lib/libc/stdlib/ |
D | bsearch.c | 62 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/malloc_debug/ |
D | PointerData.h | 71 std::size_t operator()(const FrameKeyType& key) const { 72 std::size_t cur_hash = key.frames[0]; 74 size_t max_frames = (key.num_frames > 5) ? 5 : key.num_frames; 76 cur_hash ^= key.frames[i];
|
/bionic/apex/ |
D | Android.bp | 27 name: "com.android.runtime.key", 63 key: "com.android.runtime.key",
|
/bionic/libc/dns/resolv/ |
D | res_cache.c | 1333 _cache_check_pending_request_locked( struct resolv_cache** cache, Entry* key, unsigned netid ) in _cache_check_pending_request_locked() argument 1338 if (*cache && key) { in _cache_check_pending_request_locked() 1342 if (ri->hash == key->hash) { in _cache_check_pending_request_locked() 1353 ri->hash = key->hash; in _cache_check_pending_request_locked() 1373 _cache_notify_waiting_tid_locked( struct resolv_cache* cache, Entry* key ) in _cache_notify_waiting_tid_locked() argument 1377 if (cache && key) { in _cache_notify_waiting_tid_locked() 1381 if (ri->hash == key->hash) { in _cache_notify_waiting_tid_locked() 1404 Entry key[1]; in _resolv_cache_query_failed() local 1407 if (!entry_init_key(key, query, querylen)) in _resolv_cache_query_failed() 1415 _cache_notify_waiting_tid_locked(cache, key); in _resolv_cache_query_failed() [all …]
|
/bionic/benchmarks/linker_relocation/regen/ |
D | dump_relocs.py | 60 key = repr(cmdline) 61 if key in g_readelf_cache: return g_readelf_cache[key].splitlines() 63 g_readelf_cache[key] = out
|