/frameworks/native/opengl/tests/EGLTest/ |
D | egl_cache_test.cpp | 36 mCache = egl_cache_t::get(); in SetUp() 40 mCache->setCacheFilename(""); in TearDown() 41 mCache->terminate(); in TearDown() 44 egl_cache_t* mCache; member in android::EGLCacheTest 49 mCache->setBlob("abcd", 4, "efgh", 4); in TEST_F() 50 ASSERT_EQ(0, mCache->getBlob("abcd", 4, buf, 4)); in TEST_F() 59 mCache->initialize(egl_display_t::get(EGL_DEFAULT_DISPLAY)); in TEST_F() 60 mCache->setBlob("abcd", 4, "efgh", 4); in TEST_F() 61 ASSERT_EQ(4, mCache->getBlob("abcd", 4, buf, 4)); in TEST_F() 70 mCache->initialize(egl_display_t::get(EGL_DEFAULT_DISPLAY)); in TEST_F() [all …]
|
/frameworks/ml/nn/driver/cache/nnCache/ |
D | nnCache_test.cpp | 43 mCache = NNCache::get(); in SetUp() 47 mCache->setCacheFilename(""); in TearDown() 48 mCache->terminate(); in TearDown() 51 NNCache* mCache; member in android::NNCacheTest 66 mCache->setBlob("abcd", 4, "efgh", 4); in TEST_P() 67 ASSERT_EQ(0, mCache->getBlob("abcd", 4, buf, 4)); in TEST_P() 76 mCache->initialize(maxKeySize, maxValueSize, maxTotalSize, GetParam()); in TEST_P() 77 mCache->setBlob("abcd", 4, "efgh", 4); in TEST_P() 78 ASSERT_EQ(4, mCache->getBlob("abcd", 4, buf, 4)); in TEST_P() 87 mCache->initialize(maxKeySize, maxValueSize, maxTotalSize, GetParam()); in TEST_P() [all …]
|
/frameworks/base/core/tests/coretests/src/android/content/res/ |
D | ConfigurationBoundResourceCacheTest.java | 30 ConfigurationBoundResourceCache<Float> mCache; field in ConfigurationBoundResourceCacheTest 39 mCache = new ConfigurationBoundResourceCache<>(); in setUp() 45 assertNull(mCache.getInstance(-1, res, null)); in testGetEmpty() 50 mCache.put(1, null, new DummyFloatConstantState(5f)); in testSetGet() 52 assertEquals(5f, mCache.getInstance(1, res, null)); in testSetGet() 53 assertNotSame(5f, mCache.getInstance(1, res, null)); in testSetGet() 54 assertEquals(null, mCache.getInstance(1, res, getActivity().getTheme())); in testSetGet() 59 mCache.put(1, getActivity().getTheme(), new DummyFloatConstantState(5f)); in testSetGetThemed() 61 assertEquals(null, mCache.getInstance(1, res, null)); in testSetGetThemed() 62 assertEquals(5f, mCache.getInstance(1, res, getActivity().getTheme())); in testSetGetThemed() [all …]
|
/frameworks/base/services/tests/servicestests/src/com/android/server/wm/ |
D | TaskSnapshotCacheTest.java | 41 private TaskSnapshotCache mCache; field in TaskSnapshotCacheTest 46 mCache = new TaskSnapshotCache(sWm, mLoader); in setUp() 52 mCache.putSnapshot(window.getTask(), createSnapshot()); in testAppRemoved() 53 assertNotNull(mCache.getSnapshot(window.getTask().mTaskId, 0 /* userId */, in testAppRemoved() 55 mCache.onAppRemoved(window.mAppToken); in testAppRemoved() 56 assertNull(mCache.getSnapshot(window.getTask().mTaskId, 0 /* userId */, in testAppRemoved() 63 mCache.putSnapshot(window.getTask(), createSnapshot()); in testAppDied() 64 assertNotNull(mCache.getSnapshot(window.getTask().mTaskId, 0 /* userId */, in testAppDied() 66 mCache.onAppDied(window.mAppToken); in testAppDied() 67 assertNull(mCache.getSnapshot(window.getTask().mTaskId, 0 /* userId */, in testAppDied() [all …]
|
/frameworks/base/libs/hwui/ |
D | FboCache.cpp | 42 return mCache.size(); in getSize() 54 for (size_t i = 0; i < mCache.size(); i++) { in clear() 55 const GLuint fbo = mCache.itemAt(i); in clear() 58 mCache.clear(); in clear() 63 if (mCache.size() > 0) { in get() 64 fbo = mCache.itemAt(mCache.size() - 1); in get() 65 mCache.removeAt(mCache.size() - 1); in get() 73 if (mCache.size() < mMaxSize) { in put() 74 mCache.add(fbo); in put()
|
D | ResourceCache.cpp | 33 for (size_t i = 0; i < mCache->size(); ++i) { in logCache() 34 ResourceReference* ref = mCache->valueAt(i); in logCache() 36 i, mCache->keyAt(i), mCache->valueAt(i)); in logCache() 44 mCache = new KeyedVector<const void*, ResourceReference*>(); in ResourceCache() 49 delete mCache; in ~ResourceCache() 70 ssize_t index = mCache->indexOfKey(resource); in incrementRefcountLocked() 71 ResourceReference* ref = index >= 0 ? mCache->valueAt(index) : nullptr; in incrementRefcountLocked() 72 if (ref == nullptr || mCache->size() == 0) { in incrementRefcountLocked() 74 mCache->add(resource, ref); in incrementRefcountLocked() 89 ssize_t index = mCache->indexOfKey(resource); in decrementRefcountLocked() [all …]
|
D | RenderBufferCache.cpp | 99 for (auto entry : mCache) { in clear() 102 mCache.clear(); in clear() 109 auto iter = mCache.find(entry); in get() 111 if (iter != mCache.end()) { in get() 113 mCache.erase(iter); in get() 139 RenderBuffer* victim = mCache.begin()->mBuffer; in put() 141 mCache.erase(mCache.begin()); in put() 146 mCache.insert(entry); in put()
|
D | TextureCache.cpp | 37 : mCache(LruCache<uint32_t, Texture*>::kUnlimitedCapacity) in TextureCache() 41 mCache.setOnEntryRemovedListener(this); in TextureCache() 85 LruCache<uint32_t, Texture*>::Iterator iter(mCache); in resetMarkInUse() 127 Texture* texture = mCache.get(bitmap->getStableID()); in getCachedTexture() 138 Texture* oldest = mCache.peekOldestValue(); in getCachedTexture() 140 mCache.removeOldest(); in getCachedTexture() 154 mCache.put(bitmap->getStableID(), texture); in getCachedTexture() 199 return mCache.remove(pixelRefStableID); in destroyTexture() 203 mCache.clear(); in clear() 212 if (mFlushRate >= 1.0f || mCache.size() == 0) return; in flush() [all …]
|
D | TextDropShadowCache.cpp | 100 : mCache(LruCache<ShadowText, ShadowTexture*>::kUnlimitedCapacity) in TextDropShadowCache() 103 mCache.setOnEntryRemovedListener(this); in TextDropShadowCache() 108 mCache.clear(); in ~TextDropShadowCache() 145 mCache.clear(); in clear() 151 ShadowTexture* texture = mCache.get(entry); in get() 176 LOG_ALWAYS_FATAL_IF(!mCache.removeOldest(), in get() 178 PRIu32 ", mCache.size() = %zu", mSize, mCache.size()); in get() 196 mCache.put(entry, texture); in get()
|
/frameworks/opt/net/wifi/tests/wifitests/src/com/android/server/wifi/hotspot2/ |
D | AnqpCacheTest.java | 46 AnqpCache mCache; field in AnqpCacheTest 56 mCache = new AnqpCache(mClock); in setUp() 66 mCache.addEntry(ENTRY_KEY, null); in addAndGetEntry() 67 ANQPData data = mCache.getEntry(ENTRY_KEY); in addAndGetEntry() 79 assertNull(mCache.getEntry(ENTRY_KEY)); in getNonExistEntry() 89 mCache.addEntry(ENTRY_KEY, null); in sweepRemoveExpiredEntry() 94 mCache.sweep(); in sweepRemoveExpiredEntry() 95 assertNotNull(mCache.getEntry(ENTRY_KEY)); in sweepRemoveExpiredEntry() 99 mCache.sweep(); in sweepRemoveExpiredEntry() 100 assertNull(mCache.getEntry(ENTRY_KEY)); in sweepRemoveExpiredEntry()
|
/frameworks/base/rs/java/android/renderscript/ |
D | ScriptIntrinsicLUT.java | 28 private final byte mCache[] = new byte[1024]; field in ScriptIntrinsicLUT 35 mCache[ct] = (byte)ct; in ScriptIntrinsicLUT() 36 mCache[ct + 256] = (byte)ct; in ScriptIntrinsicLUT() 37 mCache[ct + 512] = (byte)ct; in ScriptIntrinsicLUT() 38 mCache[ct + 768] = (byte)ct; in ScriptIntrinsicLUT() 81 mCache[index] = (byte)value; in setRed() 93 mCache[index+256] = (byte)value; in setGreen() 105 mCache[index+512] = (byte)value; in setBlue() 117 mCache[index+768] = (byte)value; in setAlpha() 143 mTables.copyFromUnchecked(mCache); in forEach()
|
/frameworks/rs/support/java/src/android/support/v8/renderscript/ |
D | ScriptIntrinsicLUT.java | 30 private final byte mCache[] = new byte[1024]; field in ScriptIntrinsicLUT 60 si.mCache[ct] = (byte)ct; in create() 61 si.mCache[ct + 256] = (byte)ct; in create() 62 si.mCache[ct + 512] = (byte)ct; in create() 63 si.mCache[ct + 768] = (byte)ct; in create() 87 mCache[index] = (byte)value; 99 mCache[index+256] = (byte)value; 111 mCache[index+512] = (byte)value; 123 mCache[index+768] = (byte)value; 138 mTables.copyFromUnchecked(mCache);
|
/frameworks/base/core/java/android/widget/ |
D | RemoteViewsAdapter.java | 82 private final FixedSizeRemoteViewsCache mCache; field in RemoteViewsAdapter 252 synchronized (adapter.mCache) { in onServiceConnected() 253 adapter.mCache.commitTemporaryMetaData(); in onServiceConnected() 310 private final FixedSizeRemoteViewsCache mCache; field in RemoteViewsAdapter.RemoteViewsFrameLayout 314 mCache = cache; in RemoteViewsFrameLayout() 337 int viewHeight = mCache.getMetaData().getLoadingTemplate(getContext()).defaultHeight; in getDefaultView() 813 mCache = sCachedRemoteViewsCaches.get(key); in RemoteViewsAdapter() 814 synchronized (mCache.mMetaData) { in RemoteViewsAdapter() 815 if (mCache.mMetaData.count > 0) { in RemoteViewsAdapter() 822 mCache = new FixedSizeRemoteViewsCache(sDefaultCacheSize); in RemoteViewsAdapter() [all …]
|
/frameworks/opt/bitmap/src/com/android/bitmap/ |
D | UnrefedPooledCache.java | 46 private final LinkedHashMap<K, V> mCache; field in UnrefedPooledCache 60 mCache = new LinkedHashMap<K, V>(0, 0.75f, true); in UnrefedPooledCache() 74 synchronized (mCache) { in get() 75 V result = mCache.get(key); in get() 95 synchronized (mCache) { in put() 98 prev = mCache.put(key, value); in put() 129 synchronized (mCache) { in poll() 132 for (Map.Entry<K, V> entry : mCache.entrySet()) { in poll() 155 mCache.remove(eldestUnref.getKey()); in poll() 175 synchronized (mCache) { in toDebugString() [all …]
|
/frameworks/av/media/libstagefright/ |
D | NuCachedSource2.cpp | 189 mCache(new PageCache(kPageSize)), in NuCachedSource2() 235 delete mCache; in ~NuCachedSource2() 236 mCache = NULL; in ~NuCachedSource2() 339 mSource->reconnectAtOffset(mCacheOffset + mCache->totalSize()); in fetchInternal() 360 PageCache::Page *page = mCache->acquirePage(); in fetchInternal() 363 mCacheOffset + mCache->totalSize(), page->mData, kPageSize); in fetchInternal() 373 mCache->releasePage(page); in fetchInternal() 383 mCache->releasePage(page); in fetchInternal() 392 mCache->appendPage(page); in fetchInternal() 419 if (mFetching && mCache->totalSize() >= mHighwaterThresholdBytes) { in onFetch() [all …]
|
/frameworks/base/packages/SystemUI/src/com/android/systemui/recents/model/ |
D | TaskKeyLruCache.java | 37 private final LruCache<Integer, V> mCache; field in TaskKeyLruCache 46 mCache = new LruCache<Integer, V>(cacheSize) { in TaskKeyLruCache() 60 mCache.trimToSize(cacheSize); in trimToSize() 77 return mCache.get(id); in getCacheEntry() 82 mCache.put(id, value); in putCacheEntry() 87 mCache.remove(id); in removeCacheEntry() 92 mCache.evictAll(); in evictAllCache()
|
D | TaskKeyStrongCache.java | 34 private final ArrayMap<Integer, V> mCache = new ArrayMap<>(); field in TaskKeyStrongCache 39 put(key, other.mCache.get(key.id)); in copyEntries() 56 return mCache.get(id); in getCacheEntry() 61 mCache.put(id, value); in putCacheEntry() 66 mCache.remove(id); in removeCacheEntry() 71 mCache.clear(); in evictAllCache()
|
/frameworks/base/services/core/java/com/android/server/hdmi/ |
D | HdmiCecMessageCache.java | 39 private final SparseArray<SparseArray<HdmiCecMessage>> mCache = new SparseArray<>(); field in HdmiCecMessageCache 54 SparseArray<HdmiCecMessage> messages = mCache.get(address); in getMessage() 68 mCache.remove(address); in flushMessagesFrom() 75 mCache.clear(); in flushAll() 91 SparseArray<HdmiCecMessage> messages = mCache.get(source); in cacheMessage() 94 mCache.put(source, messages); in cacheMessage()
|
/frameworks/base/services/core/java/com/android/server/locksettings/ |
D | LockSettingsStorage.java | 89 private final Cache mCache = new Cache(); field in LockSettingsStorage 205 mCache.putKeyValue(key, value, userId); in writeKeyValue() 214 synchronized (mCache) { in readKeyValue() 215 if (mCache.hasKeyValue(key, userId)) { in readKeyValue() 216 return mCache.peekKeyValue(key, defaultValue, userId); in readKeyValue() 218 version = mCache.getVersion(); in readKeyValue() 233 mCache.putKeyValueIfUnchanged(key, result, userId, version); in readKeyValue() 239 synchronized (mCache) { in prefetchUser() 240 if (mCache.isFetched(userId)) { in prefetchUser() 243 mCache.setFetched(userId); in prefetchUser() [all …]
|
/frameworks/minikin/libs/minikin/ |
D | HbFontCache.cpp | 34 HbFontCache() : mCache(kMaxEntries) { in HbFontCache() 35 mCache.setOnEntryRemovedListener(this); in HbFontCache() 44 return mCache.get(fontId); in get() 48 mCache.put(fontId, font); in put() 52 mCache.clear(); in clear() 56 mCache.remove(fontId); in remove() 62 android::LruCache<int32_t, hb_font_t*> mCache; member in minikin::HbFontCache
|
/frameworks/support/samples/Support4Demos/src/com/example/android/supportv4/media/ |
D | AlbumArtCache.java | 49 private final LruCache<String, Bitmap[]> mCache; field in AlbumArtCache 62 mCache = new LruCache<String, Bitmap[]>(maxSize) { in AlbumArtCache() 72 Bitmap[] result = mCache.get(artUrl); in getBigImage() 77 Bitmap[] result = mCache.get(artUrl); in getIconImage() 86 Bitmap[] bitmap = mCache.get(artUrl); in fetch() 104 mCache.put(artUrl, bitmaps); in fetch() 108 Log.d(TAG, "doInBackground: putting bitmap in cache. cache size=" + mCache.size()); in fetch()
|
/frameworks/support/samples/SupportLeanbackDemos/src/com/example/android/leanback/ |
D | PlaybackSeekAsyncDataProvider.java | 40 final LruCache<Integer, Bitmap> mCache; field in PlaybackSeekAsyncDataProvider 75 mCache.put(mIndex, bitmap); in onPostExecute() 89 mCache = new LruCache<Integer, Bitmap>(cacheSize); in PlaybackSeekAsyncDataProvider() 105 Bitmap bitmap = mCache.get(key); in getThumbnail() 111 mCache.put(key, bitmap); in getThumbnail() 148 if (mCache.get(key) == null && mPrefetchCache.get(key) == null) { in prefetch() 166 mCache.evictAll(); in reset() 180 for (Iterator<Integer> it = mCache.snapshot().keySet().iterator(); it.hasNext();) { in toString() 182 if (mCache.get(key) != null) { in toString()
|
/frameworks/av/media/libheif/ |
D | HeifDecoderImpl.cpp | 88 std::unique_ptr<uint8_t> mCache; member in android::HeifDataSource 102 mCache.reset(new uint8_t[kInitialCacheBufferSize]); in init() 103 if (mCache.get() == nullptr) { in init() 158 memcpy(mMemory->pointer(), mCache.get() + offset - mCachedOffset, size); in readAt() 168 uint8_t* dst = mCache.get(); in readAt() 187 memcpy(dst, mCache.get() + newCachedOffset - mCachedOffset, newCachedSize); in readAt() 209 mCache.reset(newCache.release()); in readAt() 226 memcpy(newCache, mCache.get(), mCachedSize); in readAt() 227 mCache.reset(newCache); in readAt() 235 size_t bytesRead = mStream->read(mCache.get() + mCachedSize, bytesToRead); in readAt() [all …]
|
/frameworks/base/tests/Camera2Tests/SmartCamera/SimpleCamera/src/androidx/media/filterfw/ |
D | FrameManager.java | 58 private BackingCache mCache; field in FrameManager 294 mCache.setSize(bytes); in setCacheSize() 303 return mCache.getSize(); in getCacheSize() 380 mCache.clear(); in clearCache() 396 mCache = new BackingCacheNone(); in FrameManager() 399 mCache = new BackingCacheLru(); in FrameManager() 402 mCache = new BackingCacheLfu(); in FrameManager() 410 return mCache.fetchBacking(mode, access, dimensions, elemSize); in fetchBacking() 421 if (!backing.shouldCache() || !mCache.cacheBacking(backing)) { in onBackingAvailable() 436 mCache.clear(); in destroyBackings()
|
/frameworks/native/libs/binder/ |
D | PermissionCache.cpp | 43 ssize_t index = mCache.indexOf(e); in check() 45 *granted = mCache.itemAt(index).granted; in check() 66 index = mCache.indexOf(e); in cache() 68 mCache.add(e); in cache() 74 mCache.clear(); in purge()
|