My recent change to remove createRTFrom3DAPIState exposed a latent issue in the GrResource cache that ...
13 years, 3 months ago
(2011-08-19 19:01:31 UTC)
#1
My recent change to remove createRTFrom3DAPIState exposed a latent issue in the
GrResource cache that triggered a (probably benign) assert. The issue has been
around since my stencil buffer changes went in a few weeks ago.
When the cache destroys a GrRenderTarget in GrResourceCache::removeAll it can
cause a GrStencilBuffer to be unlocked. The unlock makes a call to
GrResourceCache::purgeAsNeeded while removeAll is still in its loop up-stack.
removeAll() doesn't keep the cache in a consistent state during its eviction
loop, causing assertions to fire in the nested purge.
GrResourceCache::purgeAsNeeded is already safe against nested calls. So, my fix
is to implement removeAll using purgeAsNeeded with a null cache budget and then
assert afterwards that all entries were removed.
Issue 4929042: Fix GrResourceCache::removeAll when one resource holds a lock on another
(Closed)
Created 13 years, 3 months ago by bsalomon
Modified 13 years, 2 months ago
Reviewers: Stephen White, reed1
Base URL: http://skia.googlecode.com/svn/trunk/
Comments: 0