/system/bt/common/ |
D | lru_unittest.cc | 33 LegacyLruCache<int, int> cache(3, "testing"); // capacity = 3; in TEST() local 34 cache.Put(1, 10); in TEST() 35 EXPECT_EQ(cache.Size(), 1); in TEST() 36 EXPECT_FALSE(cache.Put(2, 20)); in TEST() 37 EXPECT_FALSE(cache.Put(3, 30)); in TEST() 38 EXPECT_EQ(cache.Size(), 3); in TEST() 41 EXPECT_TRUE(cache.Get(1, value)); in TEST() 43 EXPECT_TRUE(cache.Get(2, value)); in TEST() 45 EXPECT_TRUE(cache.Get(3, value)); in TEST() 47 EXPECT_EQ(cache.Size(), 3); in TEST() [all …]
|
/system/bt/gd/common/ |
D | lru_cache_test.cc | 30 LruCache<int, int> cache(3); // capacity = 3; in TEST() local 31 EXPECT_EQ(cache.size(), 0); in TEST() 32 EXPECT_EQ(cache.find(42), cache.end()); in TEST() 33 cache.clear(); // should not crash in TEST() 34 EXPECT_EQ(cache.find(42), cache.end()); in TEST() 35 EXPECT_FALSE(cache.contains(42)); in TEST() 36 EXPECT_FALSE(cache.extract(42)); in TEST() 72 LruCache<int, int> cache(2); in TEST() local 73 cache.insert_or_assign(1, 10); in TEST() 74 cache.insert_or_assign(2, 20); in TEST() [all …]
|
/system/core/libutils/ |
D | LruCache_test.cpp | 154 LruCache<SimpleKey, StringValue> cache(100); in TEST_F() local 156 EXPECT_EQ(nullptr, cache.get(0)); in TEST_F() 157 EXPECT_EQ(0u, cache.size()); in TEST_F() 161 LruCache<SimpleKey, StringValue> cache(100); in TEST_F() local 163 cache.put(1, "one"); in TEST_F() 164 cache.put(2, "two"); in TEST_F() 165 cache.put(3, "three"); in TEST_F() 166 EXPECT_STREQ("one", cache.get(1)); in TEST_F() 167 EXPECT_STREQ("two", cache.get(2)); in TEST_F() 168 EXPECT_STREQ("three", cache.get(3)); in TEST_F() [all …]
|
D | LruCache_fuzz.cpp | 37 [](FuzzedDataProvider*, FuzzCache* cache) -> void { cache->removeOldest(); }, in __anon8490bc0f0102() 38 [](FuzzedDataProvider*, FuzzCache* cache) -> void { cache->peekOldestValue(); }, in __anon8490bc0f0202() 39 [](FuzzedDataProvider*, FuzzCache* cache) -> void { cache->clear(); }, in __anon8490bc0f0302() 40 [](FuzzedDataProvider*, FuzzCache* cache) -> void { cache->size(); }, in __anon8490bc0f0402() 41 [](FuzzedDataProvider*, FuzzCache* cache) -> void { in __anon8490bc0f0502() 42 android::LruCache<size_t, size_t>::Iterator iter(*cache); in __anon8490bc0f0502() 48 [](FuzzedDataProvider* dataProvider, FuzzCache* cache) -> void { in __anon8490bc0f0602() 51 cache->put(key, val); in __anon8490bc0f0602() 53 [](FuzzedDataProvider* dataProvider, FuzzCache* cache) -> void { in __anon8490bc0f0702() 55 cache->get(key); in __anon8490bc0f0702() [all …]
|
/system/logging/liblog/ |
D | properties.cpp | 56 struct cache { struct 62 struct cache cache; member 66 static int check_cache(struct cache* cache) { in check_cache() argument 67 return cache->pinfo && __system_property_serial(cache->pinfo) != cache->serial; in check_cache() 73 static void refresh_cache(struct cache_char* cache, const char* key) { in refresh_cache() argument 76 if (!cache->cache.pinfo) { in refresh_cache() 77 cache->cache.pinfo = __system_property_find(key); in refresh_cache() 78 if (!cache->cache.pinfo) { in refresh_cache() 82 cache->cache.serial = __system_property_serial(cache->cache.pinfo); in refresh_cache() 83 __system_property_read(cache->cache.pinfo, 0, buf); in refresh_cache() [all …]
|
/system/extras/simpleperf/ |
D | CallChainJoiner_test.cpp | 26 static bool JoinCallChain(LRUCache& cache, uint32_t tid, const std::vector<uint64_t>& input_ip, in JoinCallChain() argument 32 cache.AddCallChain(tid, tmp_ip, tmp_sp); in JoinCallChain() 37 LRUCache cache(sizeof(CacheNode) * 2, 1); in TEST() local 38 ASSERT_EQ(cache.Stat().max_node_count, 2u); in TEST() 42 ASSERT_TRUE(JoinCallChain(cache, 0, ip, sp, ip, sp)); in TEST() 43 ASSERT_TRUE(JoinCallChain(cache, 1, ip, sp, ip, sp)); in TEST() 44 ASSERT_EQ(cache.Stat().used_node_count, 2u); in TEST() 45 ASSERT_EQ(cache.Stat().recycled_node_count, 0u); in TEST() 46 ASSERT_NE(cache.FindNode(0, ip[0], sp[0]), nullptr); in TEST() 47 ASSERT_NE(cache.FindNode(1, ip[0], sp[0]), nullptr); in TEST() [all …]
|
/system/security/keystore2/src/ |
D | boot_level_keys.rs | 133 cache: VecDeque<ZVec>, field 143 let mut cache: VecDeque<ZVec> = VecDeque::new(); in new() localVariable 144 cache.push_back(level_zero_key); in new() 145 Self { current: 0, cache } in new() 153 boot_level >= self.current && !self.cache.is_empty() in level_accessible() 164 let first_not_cached = self.current + self.cache.len(); in get_hkdf_key() 170 let highest_key = self.cache.back().unwrap(); in get_hkdf_key() 173 self.cache.push_back(next_key); in get_hkdf_key() 177 Ok(Some(self.cache.get(boot_level - self.current).unwrap())) in get_hkdf_key() 191 self.cache.len() in advance_boot_level() [all …]
|
/system/sepolicy/prebuilts/api/28.0/public/ |
D | otapreopt_slot.te | 4 # from /data/ota to /data/dalvik-cache. 10 # The otapreopt_slot renames the OTA dalvik-cache to the regular dalvik-cache, and cleans up 17 # Delete old content of the dalvik-cache. 26 # Needed so we can move artifacts into /data/dalvik-cache/dalvik-cache.
|
/system/sepolicy/prebuilts/api/26.0/public/ |
D | otapreopt_slot.te | 4 # from /data/ota to /data/dalvik-cache. 10 # The otapreopt_slot renames the OTA dalvik-cache to the regular dalvik-cache, and cleans up 17 # Delete old content of the dalvik-cache. 26 # Needed so we can move artifacts into /data/dalvik-cache/dalvik-cache.
|
/system/sepolicy/prebuilts/api/27.0/public/ |
D | otapreopt_slot.te | 4 # from /data/ota to /data/dalvik-cache. 10 # The otapreopt_slot renames the OTA dalvik-cache to the regular dalvik-cache, and cleans up 17 # Delete old content of the dalvik-cache. 26 # Needed so we can move artifacts into /data/dalvik-cache/dalvik-cache.
|
/system/sepolicy/prebuilts/api/31.0/private/ |
D | otapreopt_slot.te | 2 # from /data/ota to /data/dalvik-cache. 11 # The otapreopt_slot renames the OTA dalvik-cache to the regular dalvik-cache, and cleans up 18 # Delete old content of the dalvik-cache. 27 # Needed so we can move artifacts into /data/dalvik-cache/dalvik-cache.
|
D | mediaprovider.te | 12 # DownloadProvider uses /cache. 15 # /cache is a symlink to /data/cache on some devices. Allow reading the link. 17 # mediaprovider searches through /cache looking for orphans 18 # Ignore denials to /cache/recovery and /cache/backup.
|
D | file_contexts_overlayfs | 4 /cache/overlay/(system|product)/upper u:object_r:system_file:s0 5 /cache/overlay/(vendor|odm)/upper u:object_r:vendor_file:s0 6 /cache/overlay/oem/upper u:object_r:vendor_file:s0
|
/system/sepolicy/prebuilts/api/30.0/private/ |
D | mediaprovider.te | 12 # DownloadProvider uses /cache. 15 # /cache is a symlink to /data/cache on some devices. Allow reading the link. 17 # mediaprovider searches through /cache looking for orphans 18 # Ignore denials to /cache/recovery and /cache/backup.
|
D | otapreopt_slot.te | 2 # from /data/ota to /data/dalvik-cache. 11 # The otapreopt_slot renames the OTA dalvik-cache to the regular dalvik-cache, and cleans up 18 # Delete old content of the dalvik-cache. 27 # Needed so we can move artifacts into /data/dalvik-cache/dalvik-cache.
|
D | file_contexts_overlayfs | 4 /cache/overlay/(system|product)/upper u:object_r:system_file:s0 5 /cache/overlay/(vendor|odm)/upper u:object_r:vendor_file:s0 6 /cache/overlay/oem/upper u:object_r:vendor_file:s0
|
/system/sepolicy/private/ |
D | otapreopt_slot.te | 2 # from /data/ota to /data/dalvik-cache. 11 # The otapreopt_slot renames the OTA dalvik-cache to the regular dalvik-cache, and cleans up 18 # Delete old content of the dalvik-cache. 27 # Needed so we can move artifacts into /data/dalvik-cache/dalvik-cache.
|
D | mediaprovider.te | 12 # DownloadProvider uses /cache. 15 # /cache is a symlink to /data/cache on some devices. Allow reading the link. 17 # mediaprovider searches through /cache looking for orphans 18 # Ignore denials to /cache/recovery and /cache/backup.
|
D | file_contexts_overlayfs | 4 /cache/overlay/(system|product)/upper u:object_r:system_file:s0 5 /cache/overlay/(vendor|odm)/upper u:object_r:vendor_file:s0 6 /cache/overlay/oem/upper u:object_r:vendor_file:s0
|
/system/sepolicy/prebuilts/api/28.0/private/ |
D | mediaprovider.te | 12 # DownloadProvider uses /cache. 15 # /cache is a symlink to /data/cache on some devices. Allow reading the link. 17 # mediaprovider searches through /cache looking for orphans 18 # Ignore denials to /cache/recovery and /cache/backup.
|
/system/sepolicy/prebuilts/api/29.0/private/ |
D | otapreopt_slot.te | 2 # from /data/ota to /data/dalvik-cache. 11 # The otapreopt_slot renames the OTA dalvik-cache to the regular dalvik-cache, and cleans up 18 # Delete old content of the dalvik-cache. 27 # Needed so we can move artifacts into /data/dalvik-cache/dalvik-cache.
|
D | mediaprovider.te | 12 # DownloadProvider uses /cache. 15 # /cache is a symlink to /data/cache on some devices. Allow reading the link. 17 # mediaprovider searches through /cache looking for orphans 18 # Ignore denials to /cache/recovery and /cache/backup.
|
D | file_contexts_overlayfs | 4 /cache/overlay/(system|product)/upper u:object_r:system_file:s0 5 /cache/overlay/(vendor|odm)/upper u:object_r:vendor_file:s0 6 /cache/overlay/oem/upper u:object_r:vendor_file:s0
|
/system/bt/gd/storage/ |
D | legacy_config_file.cc | 43 ConfigCache cache(temp_devices_capacity, Device::kLinkKeyProperties); in Read() local 67 cache.SetProperty(section, tokens[0], std::move(tokens[1])); in Read() 70 return cache; in Read() 73 bool LegacyConfigFile::Write(const ConfigCache& cache) { in Write() argument 74 return os::WriteToFile(path_, cache.SerializeToLegacyFormat()); in Write()
|
/system/extras/tests/pagingtest/ |
D | pageinout_test.c | 12 int pageinout_test(int test_runs, bool cache, unsigned long long file_size) { in pageinout_test() argument 47 if (!cache) { in pageinout_test() 88 printf("%scached page-in: %llu MB/s\n", cache ? "" : "un", in pageinout_test() 91 printf("%scached page-out (clean): %llu MB/s\n", cache ? "" : "un", in pageinout_test()
|