Bug 1920678 - Add a pool for the memory chunks used by per-frame allocators. r=gfx-reviewers,lsalzman
Instead of dropping the frame's memory chunk when a frame is replaced, place the chunks into a global pool. This mostly helps when running stress tests like motionmark's html suite that cause intense allocation spikes (around 90 chunks per frame). We should revisit whether this is needed if the cost of deallocating large regions of memory in mozjemalloc improves in the future. Differential Revision: https://phabricator.services.mozilla.com/D223924
This commit is contained in:
@@ -138,7 +138,7 @@ class NewRenderer : public RendererEvent {
|
||||
gfx::gfxVars::UseWebRenderScissoredCacheClears(), swgl, gl,
|
||||
compositor->SurfaceOriginIsTopLeft(), progCache, shaders,
|
||||
aRenderThread.ThreadPool().Raw(),
|
||||
aRenderThread.ThreadPoolLP().Raw(),
|
||||
aRenderThread.ThreadPoolLP().Raw(), aRenderThread.MemoryChunkPool(),
|
||||
aRenderThread.GlyphRasterThread().Raw(), &WebRenderMallocSizeOf,
|
||||
&WebRenderMallocEnclosingSizeOf, 0, compositor.get(),
|
||||
compositor->ShouldUseNativeCompositor(),
|
||||
|
||||
Reference in New Issue
Block a user