Home
last modified time | relevance | path

Searched refs:cache (Results 1 – 25 of 1012) sorted by relevance

12345678910>>...41

/external/freetype/src/cache/
Dftccache.c92 ftc_get_top_node_for_hash( FTC_Cache cache, in ftc_get_top_node_for_hash() argument
99 idx = (FT_UInt)( hash & cache->mask ); in ftc_get_top_node_for_hash()
100 if ( idx < cache->p ) in ftc_get_top_node_for_hash()
101 idx = (FT_UInt)( hash & ( 2 * cache->mask + 1 ) ); in ftc_get_top_node_for_hash()
102 pnode = cache->buckets + idx; in ftc_get_top_node_for_hash()
114 ftc_cache_resize( FTC_Cache cache ) in ftc_cache_resize() argument
119 FT_UFast p = cache->p; in ftc_cache_resize()
120 FT_UFast mask = cache->mask; in ftc_cache_resize()
125 if ( cache->slack < 0 ) in ftc_cache_resize()
135 FT_Memory memory = cache->memory; in ftc_cache_resize()
[all …]
Dftcglyph.c43 FTC_Cache cache ) in FTC_GNode_UnselectFamily() argument
50 FTC_FAMILY_FREE( family, cache ); in FTC_GNode_UnselectFamily()
56 FTC_Cache cache ) in FTC_GNode_Done() argument
61 FTC_GNode_UnselectFamily( gnode, cache ); in FTC_GNode_Done()
68 FTC_Cache cache, in ftc_gnode_compare() argument
73 FT_UNUSED( cache ); in ftc_gnode_compare()
88 FTC_Cache cache, in FTC_GNode_Compare() argument
92 cache, list_changed ); in FTC_GNode_Compare()
107 FTC_Cache cache ) in FTC_Family_Init() argument
109 FTC_GCacheClass clazz = FTC_CACHE__GCACHE_CLASS( cache ); in FTC_Family_Init()
[all …]
/external/chromium/net/base/
Dhost_cache_unittest.cc30 HostCache cache(kMaxCacheEntries, kSuccessEntryTTL, kFailureEntryTTL); in TEST() local
38 EXPECT_EQ(0U, cache.size()); in TEST()
41 EXPECT_TRUE(cache.Lookup(Key("foobar.com"), base::TimeTicks()) == NULL); in TEST()
42 cache.Set(Key("foobar.com"), OK, AddressList(), now); in TEST()
43 entry1 = cache.Lookup(Key("foobar.com"), base::TimeTicks()); in TEST()
45 EXPECT_EQ(1U, cache.size()); in TEST()
51 EXPECT_TRUE(cache.Lookup(Key("foobar2.com"), base::TimeTicks()) == NULL); in TEST()
52 cache.Set(Key("foobar2.com"), OK, AddressList(), now); in TEST()
53 entry2 = cache.Lookup(Key("foobar2.com"), base::TimeTicks()); in TEST()
55 EXPECT_EQ(2U, cache.size()); in TEST()
[all …]
Dssl_client_auth_cache_unittest.cc14 SSLClientAuthCache cache; in TEST() local
34 EXPECT_FALSE(cache.Lookup(server1, &cached_cert)); in TEST()
37 cache.Add(server1, cert1); in TEST()
39 EXPECT_TRUE(cache.Lookup(server1, &cached_cert)); in TEST()
43 cache.Add(server2, cert2); in TEST()
45 EXPECT_TRUE(cache.Lookup(server1, &cached_cert)); in TEST()
48 EXPECT_TRUE(cache.Lookup(server2, &cached_cert)); in TEST()
52 cache.Add(server1, cert3); in TEST()
54 EXPECT_TRUE(cache.Lookup(server1, &cached_cert)); in TEST()
57 EXPECT_TRUE(cache.Lookup(server2, &cached_cert)); in TEST()
[all …]
/external/guava/guava-tests/test/com/google/common/cache/
DCacheEvictionTest.java15 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 …]
DEmptyCachesTest.java15 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;
45 for (LoadingCache<Object, Object> cache : caches()) { in testEmpty()
46 checkEmpty(cache); in testEmpty()
51 for (LoadingCache<Object, Object> cache : caches()) { in testInvalidate_empty()
52 cache.getUnchecked("a"); in testInvalidate_empty()
53 cache.getUnchecked("b"); in testInvalidate_empty()
[all …]
DCacheManualTest.java15 package com.google.common.cache;
30 Cache<Object, Object> cache = CacheBuilder.newBuilder().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 …]
DPopulatedCachesTest.java15 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;
27 import com.google.common.cache.CacheBuilderFactory.DurationSpec;
28 import com.google.common.cache.LocalCache.Strength;
58 for (LoadingCache<Object, Object> cache : caches()) { in testSize_populated()
60 List<Entry<Object, Object>> warmed = warmUp(cache); in testSize_populated()
61 assertEquals(WARMUP_SIZE, cache.size()); in testSize_populated()
62 assertMapSize(cache.asMap(), WARMUP_SIZE); in testSize_populated()
[all …]
DCacheReferencesTest.java15 package com.google.common.cache;
17 import static com.google.common.cache.LocalCache.Strength.STRONG;
18 import static com.google.common.cache.TestingRemovalListeners.countingRemovalListener;
23 import com.google.common.cache.LocalCache.Strength;
24 import com.google.common.cache.TestingRemovalListeners.CountingRemovalListener;
64 for (LoadingCache<Key, String> cache : caches()) {
68 assertSame(value, cache.getUnchecked(key));
69 assertTrue(cache.asMap().containsKey(key));
70 assertTrue(cache.asMap().containsValue(value));
71 assertEquals(1, cache.size());
[all …]
DCacheExpirationTest.java15 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 …]
DCacheLoadingTest.java15 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;
27 import com.google.common.cache.CacheLoader.InvalidCacheLoadException;
28 import com.google.common.cache.TestingCacheLoaders.CountingLoader;
29 import com.google.common.cache.TestingCacheLoaders.IdentityLoader;
[all …]
DCacheRefreshTest.java15 package com.google.common.cache;
17 import static com.google.common.cache.TestingCacheLoaders.incrementingLoader;
20 import com.google.common.cache.TestingCacheLoaders.IncrementingLoader;
34 LoadingCache<Integer, Integer> cache = CacheBuilder.newBuilder() in testAutoRefresh() local
43 assertEquals(Integer.valueOf(i), cache.getUnchecked(i)); in testAutoRefresh()
50 assertEquals(Integer.valueOf(0), cache.getUnchecked(0)); in testAutoRefresh()
51 assertEquals(Integer.valueOf(1), cache.getUnchecked(1)); in testAutoRefresh()
52 assertEquals(Integer.valueOf(2), cache.getUnchecked(2)); in testAutoRefresh()
58 assertEquals(Integer.valueOf(1), cache.getUnchecked(0)); in testAutoRefresh()
60 assertEquals(Integer.valueOf(1), cache.getUnchecked(1)); in testAutoRefresh()
[all …]
DCacheTesting.java15 package com.google.common.cache;
26 import com.google.common.cache.LocalCache.LocalLoadingCache;
27 import com.google.common.cache.LocalCache.ReferenceEntry;
28 import com.google.common.cache.LocalCache.Segment;
29 import com.google.common.cache.LocalCache.ValueReference;
64 static <K, V> void simulateValueReclamation(Cache<K, V> cache, K key) { in simulateValueReclamation() argument
65 ReferenceEntry<K, V> entry = getReferenceEntry(cache, key); in simulateValueReclamation()
83 static <K, V> void simulateKeyReclamation(Cache<K, V> cache, K key) { in simulateKeyReclamation() argument
84 ReferenceEntry<K, V> entry = getReferenceEntry(cache, key); in simulateKeyReclamation()
93 static <K, V> ReferenceEntry<K, V> getReferenceEntry(Cache<K, V> cache, K key) { in getReferenceEntry() argument
[all …]
/external/chromium/net/http/
Dhttp_cache_unittest.cc693 explicit DeleteCacheCompletionCallback(MockHttpCache* cache) in DeleteCacheCompletionCallback() argument
694 : cache_(cache) {} in DeleteCacheCompletionCallback()
718 void RunTransactionTestWithRequestAndLog(net::HttpCache* cache, in RunTransactionTestWithRequestAndLog() argument
728 int rv = cache->CreateTransaction(&trans); in RunTransactionTestWithRequestAndLog()
746 void RunTransactionTestWithRequest(net::HttpCache* cache, in RunTransactionTestWithRequest() argument
750 RunTransactionTestWithRequestAndLog(cache, trans_info, request, in RunTransactionTestWithRequest()
754 void RunTransactionTestWithLog(net::HttpCache* cache, in RunTransactionTestWithLog() argument
758 cache, trans_info, MockHttpRequest(trans_info), NULL, log); in RunTransactionTestWithLog()
761 void RunTransactionTest(net::HttpCache* cache, in RunTransactionTest() argument
763 RunTransactionTestWithLog(cache, trans_info, net::BoundNetLog()); in RunTransactionTest()
[all …]
Dhttp_auth_cache_unittest.cc77 HttpAuthCache cache; in TEST() local
87 cache.Add(origin, realm1_handler->realm(), realm1_handler->auth_scheme(), in TEST()
95 cache.Add(origin, realm2_handler->realm(), realm2_handler->auth_scheme(), in TEST()
103 cache.Add(origin, realm3_basic_handler->realm(), in TEST()
112 cache.Add(origin, realm3_digest_handler->realm(), in TEST()
121 cache.Add(origin, realm4_basic_handler->realm(), in TEST()
127 entry = cache.Lookup(origin, kRealm5, HttpAuth::AUTH_SCHEME_BASIC); in TEST()
131 entry = cache.Lookup(GURL("https://www.google.com"), kRealm3, in TEST()
136 entry = cache.Lookup in TEST()
141 entry = cache.Lookup( in TEST()
[all …]
/external/chromium/net/ftp/
Dftp_auth_cache_unittest.cc32 FtpAuthCache cache; in TEST() local
38 EXPECT_TRUE(cache.Lookup(origin1) == NULL); in TEST()
41 cache.Add(origin1, kUsername1, kPassword1); in TEST()
42 FtpAuthCache::Entry* entry1 = cache.Lookup(origin1); in TEST()
49 cache.Add(origin2, kUsername2, kPassword2); in TEST()
50 FtpAuthCache::Entry* entry2 = cache.Lookup(origin2); in TEST()
57 EXPECT_EQ(entry1, cache.Lookup(origin1)); in TEST()
60 cache.Add(origin1, kUsername3, kPassword3); in TEST()
61 FtpAuthCache::Entry* entry3 = cache.Lookup(origin1); in TEST()
68 cache.Remove(origin1, kUsername3, kPassword3); in TEST()
[all …]
/external/okhttp/src/test/java/com/squareup/okhttp/internal/
DDiskLruCacheTest.java49 private DiskLruCache cache; field in DiskLruCacheTest
59 cache = DiskLruCache.open(cacheDir, appVersion, 2, Integer.MAX_VALUE); in setUp()
63 cache.close(); in tearDown()
67 cache.close(); in emptyCache()
72 DiskLruCache.Editor creator = cache.edit("k1"); in writeAndReadEntry()
81 DiskLruCache.Snapshot snapshot = cache.get("k1"); in writeAndReadEntry()
87 DiskLruCache.Editor creator = cache.edit("k1"); in readAndWriteEntryAcrossCacheOpenAndClose()
91 cache.close(); in readAndWriteEntryAcrossCacheOpenAndClose()
93 cache = DiskLruCache.open(cacheDir, appVersion, 2, Integer.MAX_VALUE); in readAndWriteEntryAcrossCacheOpenAndClose()
94 DiskLruCache.Snapshot snapshot = cache.get("k1"); in readAndWriteEntryAcrossCacheOpenAndClose()
[all …]
/external/e2fsprogs/lib/blkid/
Dcache.c59 static blkid_debug_dump_cache(int mask, blkid_cache cache)
63 if (!cache) {
68 printf("cache: time = %lu\n", cache->bic_time);
69 printf("cache: flags = 0x%08X\n", cache->bic_flags);
71 list_for_each(p, &cache->bic_devs) {
80 blkid_cache cache; in blkid_get_cache() local
95 if (!(cache = (blkid_cache) calloc(1, sizeof(struct blkid_struct_cache)))) in blkid_get_cache()
98 INIT_LIST_HEAD(&cache->bic_devs); in blkid_get_cache()
99 INIT_LIST_HEAD(&cache->bic_tags); in blkid_get_cache()
107 cache->bic_filename = blkid_strdup(filename); in blkid_get_cache()
[all …]
/external/openssl/crypto/x509v3/
Dpcy_cache.c78 X509_POLICY_CACHE *cache = x->policy_cache; in policy_cache_create() local
83 cache->data = sk_X509_POLICY_DATA_new(policy_data_cmp); in policy_cache_create()
84 if (!cache->data) in policy_cache_create()
97 if (cache->anyPolicy) in policy_cache_create()
102 cache->anyPolicy = data; in policy_cache_create()
104 else if (sk_X509_POLICY_DATA_find(cache->data, data) != -1) in policy_cache_create()
109 else if (!sk_X509_POLICY_DATA_push(cache->data, data)) in policy_cache_create()
122 sk_X509_POLICY_DATA_pop_free(cache->data, policy_data_free); in policy_cache_create()
123 cache->data = NULL; in policy_cache_create()
131 X509_POLICY_CACHE *cache; in policy_cache_new() local
[all …]
/external/chromium/chrome/browser/policy/
Duser_policy_cache_unittest.cc102 void SetPolicy(UserPolicyCache* cache, in SetPolicy() argument
107 registrar.Init(cache->GetManagedPolicyProvider(), &observer); in SetPolicy()
112 cache->SetPolicy(*policy); in SetPolicy()
120 const PolicyMap& mandatory_policy(const UserPolicyCache& cache) { in mandatory_policy() argument
121 return cache.mandatory_policy_; in mandatory_policy()
124 const PolicyMap& recommended_policy(const UserPolicyCache& cache) { in recommended_policy() argument
125 return cache.recommended_policy_; in recommended_policy()
195 UserPolicyCache cache(test_file()); in TEST_F() local
197 EXPECT_TRUE(empty.Equals(mandatory_policy(cache))); in TEST_F()
198 EXPECT_TRUE(empty.Equals(recommended_policy(cache))); in TEST_F()
[all …]
/external/chromium/chrome/browser/notifications/
Dnotifications_prefs_cache_unittest.cc13 scoped_refptr<NotificationsPrefsCache> cache(new NotificationsPrefsCache()); in TEST() local
23 cache->SetCacheAllowedOrigins(allowed_origins); in TEST()
24 cache->SetCacheDeniedOrigins(denied_origins); in TEST()
25 cache->SetCacheDefaultContentSetting(CONTENT_SETTING_DEFAULT); in TEST()
28 cache->set_is_initialized(true); in TEST()
34 cache->CacheAllowedOrigin(GURL("http://allowed2.com")); in TEST()
35 cache->CacheDeniedOrigin(GURL("http://denied2.com")); in TEST()
37 EXPECT_EQ(cache->HasPermission(GURL("http://allowed.com")), in TEST()
39 EXPECT_EQ(cache->HasPermission(GURL("http://allowed2.com")), in TEST()
42 EXPECT_EQ(cache->HasPermission(GURL("http://denied.com")), in TEST()
[all …]
/external/valgrind/main/drd/
Ddrd_bitmap.h351 void bm_cache_rotate(struct bm_cache_elem cache[], const int n) in bm_cache_rotate() argument
358 t = cache[0]; in bm_cache_rotate()
360 cache[0] = cache[1]; in bm_cache_rotate()
362 cache[1] = cache[2]; in bm_cache_rotate()
364 cache[2] = cache[3]; in bm_cache_rotate()
366 cache[3] = cache[4]; in bm_cache_rotate()
368 cache[4] = cache[5]; in bm_cache_rotate()
370 cache[5] = cache[6]; in bm_cache_rotate()
372 cache[6] = cache[7]; in bm_cache_rotate()
373 cache[n - 1] = t; in bm_cache_rotate()
[all …]
/external/chromium/chrome/browser/ui/cocoa/
Dtable_row_nsimage_cache_unittest.mm51 TableRowNSImageCache cache(&table);
53 NSImage* image0 = cache.GetImageForRow(0);
54 NSImage* image1 = cache.GetImageForRow(1);
55 NSImage* image2 = cache.GetImageForRow(2);
69 cache.OnModelChanged();
71 EXPECT_NE(image0, cache.GetImageForRow(0));
72 image0 = cache.GetImageForRow(0);
74 EXPECT_NE(image1, cache.GetImageForRow(1));
75 image1 = cache.GetImageForRow(1);
77 EXPECT_NE(image2, cache.GetImageForRow(2));
[all …]
/external/webkit/Source/WebKit/chromium/src/
DWebCache.cpp59 MemoryCache* cache = WebCore::memoryCache(); in setCapacities() local
60 if (cache) in setCapacities()
61 cache->setCapacities(static_cast<unsigned int>(minDeadCapacity), in setCapacities()
68 MemoryCache* cache = WebCore::memoryCache(); in clear() local
69 if (cache && !cache->disabled()) { in clear()
70 cache->setDisabled(true); in clear()
71 cache->setDisabled(false); in clear()
79 MemoryCache* cache = WebCore::memoryCache(); in getUsageStats() local
80 if (cache) { in getUsageStats()
81 result->minDeadCapacity = cache->m_minDeadCapacity; in getUsageStats()
[all …]
/external/webkit/Source/WebCore/loader/appcache/
DApplicationCacheHost.cpp277 ApplicationCache* cache = applicationCache(); in fillResourceList() local
278 if (!cache || !cache->isComplete()) in fillResourceList()
281 ApplicationCache::ResourceMap::const_iterator end = cache->end(); in fillResourceList()
282 for (ApplicationCache::ResourceMap::const_iterator it = cache->begin(); it != end; ++it) { in fillResourceList()
296 ApplicationCache* cache = applicationCache(); in applicationCacheInfo() local
297 if (!cache || !cache->isComplete()) in applicationCacheInfo()
301 return CacheInfo(cache->manifestResource()->url(), 0, 0, cache->estimatedSizeInStorage()); in applicationCacheInfo()
338 ApplicationCache* cache = applicationCache(); in shouldLoadResourceFromApplicationCache() local
339 if (!cache || !cache->isComplete()) in shouldLoadResourceFromApplicationCache()
344 …IsHTTPOrHTTPSGet(request) || !equalIgnoringCase(request.url().protocol(), cache->manifestResource(… in shouldLoadResourceFromApplicationCache()
[all …]

12345678910>>...41