/external/v8/test/cctest/ |
D | test-asm-validator.cc | 20 #define FUNC_I_TYPE Bounds(Type::Function(cache.kAsmSigned, zone)) 21 #define FUNC_F_TYPE Bounds(Type::Function(cache.kAsmFloat, zone)) 22 #define FUNC_D_TYPE Bounds(Type::Function(cache.kAsmDouble, zone)) 24 Bounds(Type::Function(cache.kAsmDouble, cache.kAsmDouble, zone)) 26 Bounds(Type::Function(cache.kAsmFloat, Type::Number(zone), zone)) 28 Bounds(Type::Function(cache.kAsmSigned, cache.kAsmInt, zone)) 30 Bounds(Type::Function(cache.kAsmDouble, cache.kAsmInt, cache.kAsmInt, zone)) 32 Bounds(Type::Function(cache.kAsmSigned, cache.kAsmInt, cache.kAsmInt, zone)) 34 Bounds(Type::Function(cache.kAsmDouble, cache.kAsmDouble, cache.kAsmDouble, \ 43 #define FLOAT64_ARRAY_TYPE Bounds(Type::Array(cache.kAsmDouble, zone)) [all …]
|
/external/guava/guava-tests/test/com/google/common/cache/ |
D | CacheBuilderGwtTest.java | 17 package com.google.common.cache; 57 final Cache<Integer, Integer> cache = CacheBuilder.newBuilder() in testLoader() local 69 cache.put(0, 10); in testLoader() 71 assertEquals(Integer.valueOf(10), cache.get(0, loader)); in testLoader() 72 assertEquals(Integer.valueOf(1), cache.get(20, loader)); in testLoader() 73 assertEquals(Integer.valueOf(2), cache.get(34, loader)); in testLoader() 75 cache.invalidate(0); in testLoader() 76 assertEquals(Integer.valueOf(3), cache.get(0, loader)); in testLoader() 78 cache.put(0, 10); in testLoader() 79 cache.invalidateAll(); in testLoader() [all …]
|
D | CacheEvictionTest.java | 15 package com.google.common.cache; 17 import static com.google.common.cache.TestingCacheLoaders.identityLoader; 18 import static com.google.common.cache.TestingRemovalListeners.countingRemovalListener; 19 import static com.google.common.cache.TestingWeighers.constantWeigher; 20 import static com.google.common.cache.TestingWeighers.intKeyWeigher; 24 import com.google.common.cache.CacheTesting.Receiver; 25 import com.google.common.cache.LocalCache.ReferenceEntry; 26 import com.google.common.cache.TestingCacheLoaders.IdentityLoader; 27 import com.google.common.cache.TestingRemovalListeners.CountingRemovalListener; 46 LoadingCache<Object, Object> cache = CacheBuilder.newBuilder() in testEviction_setMaxSegmentSize() local [all …]
|
D | EmptyCachesTest.java | 15 package com.google.common.cache; 17 import static com.google.common.cache.CacheTesting.checkEmpty; 18 import static com.google.common.cache.TestingCacheLoaders.identityLoader; 24 import com.google.common.cache.CacheBuilderFactory.DurationSpec; 25 import com.google.common.cache.LocalCache.Strength; 47 for (LoadingCache<Object, Object> cache : caches()) { in testEmpty() 48 checkEmpty(cache); in testEmpty() 53 for (LoadingCache<Object, Object> cache : caches()) { in testInvalidate_empty() 54 cache.getUnchecked("a"); in testInvalidate_empty() 55 cache.getUnchecked("b"); in testInvalidate_empty() [all …]
|
D | CacheManualTest.java | 15 package com.google.common.cache; 30 Cache<Object, Object> cache = CacheBuilder.newBuilder().recordStats().build(); in testGetIfPresent() local 31 CacheStats stats = cache.stats(); in testGetIfPresent() 40 assertNull(cache.getIfPresent(one)); in testGetIfPresent() 41 stats = cache.stats(); in testGetIfPresent() 46 assertNull(cache.asMap().get(one)); in testGetIfPresent() 47 assertFalse(cache.asMap().containsKey(one)); in testGetIfPresent() 48 assertFalse(cache.asMap().containsValue(two)); in testGetIfPresent() 50 assertNull(cache.getIfPresent(two)); in testGetIfPresent() 51 stats = cache.stats(); in testGetIfPresent() [all …]
|
D | PopulatedCachesTest.java | 15 package com.google.common.cache; 17 import static com.google.common.cache.CacheTesting.checkEmpty; 18 import static com.google.common.cache.CacheTesting.checkValidState; 19 import static com.google.common.cache.TestingCacheLoaders.identityLoader; 25 import com.google.common.cache.CacheBuilderFactory.DurationSpec; 26 import com.google.common.cache.LocalCache.Strength; 57 for (LoadingCache<Object, Object> cache : caches()) { in testSize_populated() 59 List<Entry<Object, Object>> warmed = warmUp(cache); in testSize_populated() 60 assertEquals(WARMUP_SIZE, cache.size()); in testSize_populated() 61 assertMapSize(cache.asMap(), WARMUP_SIZE); in testSize_populated() [all …]
|
D | CacheExpirationTest.java | 15 package com.google.common.cache; 17 import static com.google.common.cache.TestingCacheLoaders.identityLoader; 18 import static com.google.common.cache.TestingRemovalListeners.countingRemovalListener; 23 import com.google.common.cache.TestingCacheLoaders.IdentityLoader; 24 import com.google.common.cache.TestingRemovalListeners.CountingRemovalListener; 53 LoadingCache<String, Integer> cache = CacheBuilder.newBuilder() in testExpiration_expireAfterWrite() local 58 checkExpiration(cache, loader, ticker, removalListener); in testExpiration_expireAfterWrite() 65 LoadingCache<String, Integer> cache = CacheBuilder.newBuilder() in testExpiration_expireAfterAccess() local 70 checkExpiration(cache, loader, ticker, removalListener); in testExpiration_expireAfterAccess() 73 private void checkExpiration(LoadingCache<String, Integer> cache, WatchedCreatorLoader loader, in checkExpiration() argument [all …]
|
D | CacheReferencesTest.java | 15 package com.google.common.cache; 17 import static com.google.common.cache.LocalCache.Strength.STRONG; 22 import com.google.common.cache.LocalCache.Strength; 23 import com.google.common.cache.TestingRemovalListeners.CountingRemovalListener; 63 for (LoadingCache<Key, String> cache : caches()) { 67 assertSame(value, cache.getUnchecked(key)); 68 assertTrue(cache.asMap().containsKey(key)); 69 assertTrue(cache.asMap().containsValue(value)); 70 assertEquals(1, cache.size()); 75 for (LoadingCache<Key, String> cache : caches()) { [all …]
|
D | CacheLoadingTest.java | 15 package com.google.common.cache; 17 import static com.google.common.cache.TestingCacheLoaders.bulkLoader; 18 import static com.google.common.cache.TestingCacheLoaders.constantLoader; 19 import static com.google.common.cache.TestingCacheLoaders.errorLoader; 20 import static com.google.common.cache.TestingCacheLoaders.exceptionLoader; 21 import static com.google.common.cache.TestingCacheLoaders.identityLoader; 22 import static com.google.common.cache.TestingRemovalListeners.countingRemovalListener; 28 import com.google.common.cache.CacheLoader.InvalidCacheLoadException; 29 import com.google.common.cache.TestingCacheLoaders.CountingLoader; 30 import com.google.common.cache.TestingCacheLoaders.IdentityLoader; [all …]
|
/external/squashfs-tools/squashfs-tools/ |
D | caches-queues-lists.c | 269 INSERT_HASH_TABLE(cache, struct cache, CALCULATE_CACHE_HASH, index, hash) 272 REMOVE_HASH_TABLE(cache, struct cache, CALCULATE_CACHE_HASH, index, hash); 283 struct cache *cache_init(int buffer_size, int max_buffers, int noshrink_lookup, in INSERT_LIST() 286 struct cache *cache = malloc(sizeof(struct cache)); in INSERT_LIST() local 288 if(cache == NULL) in INSERT_LIST() 291 cache->max_buffers = max_buffers; in INSERT_LIST() 292 cache->buffer_size = buffer_size; in INSERT_LIST() 293 cache->count = 0; in INSERT_LIST() 294 cache->used = 0; in INSERT_LIST() 295 cache->free_list = NULL; in INSERT_LIST() [all …]
|
/external/mesa3d/src/gallium/auxiliary/util/ |
D | u_cache.c | 85 ensure_sanity(const struct util_cache *cache); 95 struct util_cache *cache; in util_cache_create() local 97 cache = CALLOC_STRUCT(util_cache); in util_cache_create() 98 if(!cache) in util_cache_create() 101 cache->hash = hash; in util_cache_create() 102 cache->compare = compare; in util_cache_create() 103 cache->destroy = destroy; in util_cache_create() 105 make_empty_list(&cache->lru); in util_cache_create() 108 cache->size = size; in util_cache_create() 110 cache->entries = CALLOC(size, sizeof(struct util_cache_entry)); in util_cache_create() [all …]
|
/external/libnl/lib/ |
D | cache.c | 58 int nl_cache_nitems(struct nl_cache *cache) in nl_cache_nitems() argument 60 return cache->c_nitems; in nl_cache_nitems() 68 int nl_cache_nitems_filter(struct nl_cache *cache, struct nl_object *filter) in nl_cache_nitems_filter() argument 74 if (cache->c_ops == NULL) in nl_cache_nitems_filter() 77 ops = cache->c_ops->co_obj_ops; in nl_cache_nitems_filter() 79 nl_list_for_each_entry(obj, &cache->c_items, ce_list) { in nl_cache_nitems_filter() 94 int nl_cache_is_empty(struct nl_cache *cache) in nl_cache_is_empty() argument 96 return nl_list_empty(&cache->c_items); in nl_cache_is_empty() 103 struct nl_cache_ops *nl_cache_get_ops(struct nl_cache *cache) in nl_cache_get_ops() argument 105 return cache->c_ops; in nl_cache_get_ops() [all …]
|
/external/freetype/src/cache/ |
D | ftccache.c | 91 ftc_get_top_node_for_hash( FTC_Cache cache, in ftc_get_top_node_for_hash() argument 98 idx = hash & cache->mask; in ftc_get_top_node_for_hash() 99 if ( idx < cache->p ) in ftc_get_top_node_for_hash() 100 idx = hash & ( 2 * cache->mask + 1 ); in ftc_get_top_node_for_hash() 101 pnode = cache->buckets + idx; in ftc_get_top_node_for_hash() 113 ftc_cache_resize( FTC_Cache cache ) in ftc_cache_resize() argument 118 FT_UFast p = cache->p; in ftc_cache_resize() 119 FT_UFast mask = cache->mask; in ftc_cache_resize() 124 if ( cache->slack < 0 ) in ftc_cache_resize() 134 FT_Memory memory = cache->memory; in ftc_cache_resize() [all …]
|
/external/mesa3d/src/mesa/drivers/dri/i965/ |
D | brw_state_cache.c | 82 search_cache(struct brw_cache *cache, GLuint hash, in search_cache() argument 90 for (c = cache->items[hash % cache->size]; c; c = c->next) in search_cache() 93 fprintf(stderr, "bucket %d/%d = %d/%d items\n", hash % cache->size, in search_cache() 94 cache->size, bucketcount, cache->n_items); in search_cache() 97 for (c = cache->items[hash % cache->size]; c; c = c->next) { in search_cache() 107 rehash(struct brw_cache *cache) in rehash() argument 113 size = cache->size * 3; in rehash() 116 for (i = 0; i < cache->size; i++) in rehash() 117 for (c = cache->items[i]; c; c = next) { in rehash() 123 FREE(cache->items); in rehash() [all …]
|
/external/mesa3d/src/mesa/program/ |
D | prog_cache.c | 82 rehash(struct gl_program_cache *cache) in rehash() argument 88 cache->last = NULL; in rehash() 90 size = cache->size * 3; in rehash() 94 for (i = 0; i < cache->size; i++) in rehash() 95 for (c = cache->items[i]; c; c = next) { in rehash() 101 free(cache->items); in rehash() 102 cache->items = items; in rehash() 103 cache->size = size; in rehash() 108 clear_cache(struct gl_context *ctx, struct gl_program_cache *cache, in clear_cache() argument 114 cache->last = NULL; in clear_cache() [all …]
|
/external/squashfs-tools/kernel/fs/squashfs/ |
D | cache.c | 67 struct squashfs_cache *cache, u64 block, int length) in squashfs_cache_get() argument 72 spin_lock(&cache->lock); in squashfs_cache_get() 75 for (i = 0; i < cache->entries; i++) in squashfs_cache_get() 76 if (cache->entry[i].block == block) in squashfs_cache_get() 79 if (i == cache->entries) { in squashfs_cache_get() 84 if (cache->unused == 0) { in squashfs_cache_get() 85 cache->num_waiters++; in squashfs_cache_get() 86 spin_unlock(&cache->lock); in squashfs_cache_get() 87 wait_event(cache->wait_queue, cache->unused); in squashfs_cache_get() 88 spin_lock(&cache->lock); in squashfs_cache_get() [all …]
|
/external/icu/icu4c/source/test/intltest/ |
D | unifiedcachetest.cpp | 96 const UnifiedCache *cache = UnifiedCache::getInstance(status); in TestEvictionUnderStress() local 97 int64_t evictedCountBefore = cache->autoEvictedCount(); in TestEvictionUnderStress() 101 int64_t evictedCountAfter = cache->autoEvictedCount(); in TestEvictionUnderStress() 120 UnifiedCache cache(status); in TestEvictionPolicy() local 124 cache.setEvictionPolicy(0, 100, status); in TestEvictionPolicy() 135 cache.get( in TestEvictionPolicy() 137 &cache, in TestEvictionPolicy() 144 cache.get( in TestEvictionPolicy() 147 &cache, in TestEvictionPolicy() 154 assertEquals("", UPRV_LENGTHOF(usedReferences), cache.unusedCount()); in TestEvictionPolicy() [all …]
|
/external/skia/tests/ |
D | ResourceCacheTest.cpp | 91 GrTextureProvider* cache = context->textureProvider(); in DEF_GPUTEST_FOR_RENDERING_CONTEXTS() local 94 SkAutoTUnref<GrTexture> smallRT0(cache->createTexture(smallDesc, SkBudgeted::kYes)); in DEF_GPUTEST_FOR_RENDERING_CONTEXTS() 99 SkAutoTUnref<GrTexture> smallRT1(cache->createTexture(smallDesc, SkBudgeted::kYes)); in DEF_GPUTEST_FOR_RENDERING_CONTEXTS() 111 SkAutoTUnref<GrTexture> smallRT2(cache->createTexture(smallDesc, SkBudgeted::kNo)); in DEF_GPUTEST_FOR_RENDERING_CONTEXTS() 128 SkAutoTUnref<GrTexture> bigRT(cache->createTexture(bigDesc, SkBudgeted::kNo)); in DEF_GPUTEST_FOR_RENDERING_CONTEXTS() 142 SkAutoTUnref<GrTexture> smallMSAART0(cache->createTexture(smallMSAADesc, SkBudgeted::kNo)); in DEF_GPUTEST_FOR_RENDERING_CONTEXTS() 158 SkAutoTUnref<GrTexture> smallMSAART1(cache->createTexture(smallMSAADesc, SkBudgeted::kNo)); in DEF_GPUTEST_FOR_RENDERING_CONTEXTS() 174 smallMSAART1.reset(cache->createTexture(smallMSAADesc, SkBudgeted::kNo)); in DEF_GPUTEST_FOR_RENDERING_CONTEXTS() 176 cache->createTexture(smallMSAADesc, SkBudgeted::kNo)); in DEF_GPUTEST_FOR_RENDERING_CONTEXTS() 340 GrResourceCache* cache = fContext->getResourceCache(); in Mock() local [all …]
|
/external/okhttp/okhttp-tests/src/test/java/com/squareup/okhttp/internal/ |
D | DiskLruCacheTest.java | 62 private DiskLruCache cache; field in DiskLruCacheTest 70 cache = new DiskLruCache(fileSystem, cacheDir, appVersion, 2, maxSize, executor); in createNewCacheWithSize() 71 synchronized (cache) { in createNewCacheWithSize() 72 cache.initialize(); in createNewCacheWithSize() 74 toClose.add(cache); in createNewCacheWithSize() 91 cache.close(); in emptyCache() 99 cache.edit(key); in validateKey() 106 cache.edit(key); in validateKey() 113 cache.edit(key); in validateKey() 120 cache.edit(key); in validateKey() [all …]
|
/external/guava/guava-gwt/test/com/google/common/cache/ |
D | CacheBuilderTest_gwt.java | 16 package com.google.common.cache; 22 …com.google.common.cache.CacheBuilderTest testCase = new com.google.common.cache.CacheBuilderTest(); in testConcurrencyLevel_large() 27 …com.google.common.cache.CacheBuilderTest testCase = new com.google.common.cache.CacheBuilderTest(); in testConcurrencyLevel_setTwice() 32 …com.google.common.cache.CacheBuilderTest testCase = new com.google.common.cache.CacheBuilderTest(); in testConcurrencyLevel_zero() 37 …com.google.common.cache.CacheBuilderTest testCase = new com.google.common.cache.CacheBuilderTest(); in testInitialCapacity_large() 42 …com.google.common.cache.CacheBuilderTest testCase = new com.google.common.cache.CacheBuilderTest(); in testInitialCapacity_negative() 47 …com.google.common.cache.CacheBuilderTest testCase = new com.google.common.cache.CacheBuilderTest(); in testInitialCapacity_setTwice() 52 …com.google.common.cache.CacheBuilderTest testCase = new com.google.common.cache.CacheBuilderTest(); in testMaximumSize_negative() 57 …com.google.common.cache.CacheBuilderTest testCase = new com.google.common.cache.CacheBuilderTest(); in testMaximumSize_setTwice() 62 …com.google.common.cache.CacheBuilderTest testCase = new com.google.common.cache.CacheBuilderTest(); in testNewBuilder() [all …]
|
D | CacheBuilderGwtTest_gwt.java | 16 package com.google.common.cache; 22 …com.google.common.cache.CacheBuilderGwtTest testCase = new com.google.common.cache.CacheBuilderGwt… in testAsMapEntrySet() 28 …com.google.common.cache.CacheBuilderGwtTest testCase = new com.google.common.cache.CacheBuilderGwt… in testAsMapKeySet() 34 …com.google.common.cache.CacheBuilderGwtTest testCase = new com.google.common.cache.CacheBuilderGwt… in testAsMapKeySet_contains() 40 …com.google.common.cache.CacheBuilderGwtTest testCase = new com.google.common.cache.CacheBuilderGwt… in testAsMapValues_contains() 46 …com.google.common.cache.CacheBuilderGwtTest testCase = new com.google.common.cache.CacheBuilderGwt… in testAsMapValues_iteratorRemove() 52 …com.google.common.cache.CacheBuilderGwtTest testCase = new com.google.common.cache.CacheBuilderGwt… in testAsMap_containsKey() 58 …com.google.common.cache.CacheBuilderGwtTest testCase = new com.google.common.cache.CacheBuilderGwt… in testAsMap_containsValue() 64 …com.google.common.cache.CacheBuilderGwtTest testCase = new com.google.common.cache.CacheBuilderGwt… in testExpireAfterAccess() 70 …com.google.common.cache.CacheBuilderGwtTest testCase = new com.google.common.cache.CacheBuilderGwt… in testExpireAfterWrite() [all …]
|
/external/boringssl/src/crypto/x509v3/ |
D | pcy_cache.c | 79 X509_POLICY_CACHE *cache = x->policy_cache; in policy_cache_create() local 84 cache->data = sk_X509_POLICY_DATA_new(policy_data_cmp); in policy_cache_create() 85 if (!cache->data) in policy_cache_create() 98 if (cache->anyPolicy) in policy_cache_create() 103 cache->anyPolicy = data; in policy_cache_create() 105 else if (sk_X509_POLICY_DATA_find(cache->data, NULL, data)) in policy_cache_create() 110 else if (!sk_X509_POLICY_DATA_push(cache->data, data)) in policy_cache_create() 123 sk_X509_POLICY_DATA_pop_free(cache->data, policy_data_free); in policy_cache_create() 124 cache->data = NULL; in policy_cache_create() 132 X509_POLICY_CACHE *cache; in policy_cache_new() local [all …]
|
/external/mesa3d/src/gallium/drivers/svga/ |
D | svga_screen_cache.c | 95 struct svga_host_surface_cache *cache = &svgascreen->cache; in svga_screen_cache_lookup() local 107 pipe_mutex_lock(cache->mutex); in svga_screen_cache_lookup() 109 curr = cache->bucket[bucket].next; in svga_screen_cache_lookup() 111 while (curr != &cache->bucket[bucket]) { in svga_screen_cache_lookup() 131 LIST_ADD(&entry->head, &cache->empty); in svga_screen_cache_lookup() 135 assert(surf_size <= cache->total_size); in svga_screen_cache_lookup() 136 if (surf_size > cache->total_size) in svga_screen_cache_lookup() 137 cache->total_size = 0; /* should never happen, but be safe */ in svga_screen_cache_lookup() 139 cache->total_size -= surf_size; in svga_screen_cache_lookup() 148 pipe_mutex_unlock(cache->mutex); in svga_screen_cache_lookup() [all …]
|
/external/elfutils/libdw/ |
D | fde.c | 66 intern_fde (Dwarf_CFI *cache, const Dwarf_FDE *entry) in intern_fde() argument 69 struct dwarf_cie *cie = __libdw_find_cie (cache, entry->CIE_pointer); in intern_fde() 82 if (unlikely (read_encoded_value (cache, cie->fde_encoding, in intern_fde() 84 || unlikely (read_encoded_value (cache, cie->fde_encoding & 0x0f, in intern_fde() 122 struct dwarf_fde **tres = tsearch (fde, &cache->fde_tree, &compare_fde); in intern_fde() 143 __libdw_fde_by_offset (Dwarf_CFI *cache, Dwarf_Off offset) in __libdw_fde_by_offset() argument 147 int result = INTUSE(dwarf_next_cfi) (cache->e_ident, in __libdw_fde_by_offset() 148 &cache->data->d, CFI_IS_EH (cache), in __libdw_fde_by_offset() 162 struct dwarf_fde *fde = intern_fde (cache, &entry.fde); in __libdw_fde_by_offset() 167 if (cache->next_offset == offset) in __libdw_fde_by_offset() [all …]
|
D | encoded-value.h | 75 __libdw_cfi_read_address_inc (const Dwarf_CFI *cache, in __libdw_cfi_read_address_inc() argument 79 width = width ?: cache->e_ident[EI_CLASS] == ELFCLASS32 ? 4 : 8; in __libdw_cfi_read_address_inc() 81 if (cache->dbg != NULL) in __libdw_cfi_read_address_inc() 82 return __libdw_read_address_inc (cache->dbg, IDX_debug_frame, in __libdw_cfi_read_address_inc() 88 const unsigned char *endp = cache->data->d.d_buf + cache->data->d.d_size; in __libdw_cfi_read_address_inc() 89 Dwarf eh_dbg = { .other_byte_order = MY_ELFDATA != cache->e_ident[EI_DATA] }; in __libdw_cfi_read_address_inc() 112 read_encoded_value (const Dwarf_CFI *cache, uint8_t encoding, in read_encoded_value() argument 121 *result = (cache->frame_vaddr in read_encoded_value() 122 + (*p - (const uint8_t *) cache->data->d.d_buf)); in read_encoded_value() 126 *result = cache->textrel; in read_encoded_value() [all …]
|