diff options
Diffstat (limited to 'libs/hwui/renderthread/CacheManager.cpp')
-rw-r--r-- | libs/hwui/renderthread/CacheManager.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/libs/hwui/renderthread/CacheManager.cpp b/libs/hwui/renderthread/CacheManager.cpp index 7cb241d22668..1b638c12ac7b 100644 --- a/libs/hwui/renderthread/CacheManager.cpp +++ b/libs/hwui/renderthread/CacheManager.cpp @@ -126,6 +126,10 @@ void CacheManager::trimMemory(TrimMemoryMode mode) { SkGraphics::SetFontCacheLimit(mMaxCpuFontCacheBytes); break; } + + // We must sync the cpu to make sure deletions of resources still queued up on the GPU actually + // happen. + mGrContext->flush(kSyncCpu_GrFlushFlag, 0, nullptr); } void CacheManager::trimStaleResources() { |