[webkit-reviews] review granted: [Bug 94386] [Chromium] Implementing a global limit on memory consumed by deferred 2D canvases : [Attachment 160208] Patch

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Thu Aug 23 12:41:29 PDT 2012


Stephen White <senorblanco at chromium.org> has granted Justin Novosad
<junov at chromium.org>'s request for review:
Bug 94386: [Chromium] Implementing a global limit on memory consumed by
deferred 2D canvases
https://bugs.webkit.org/show_bug.cgi?id=94386

Attachment 160208: Patch
https://bugs.webkit.org/attachment.cgi?id=160208&action=review

------- Additional Comments from Stephen White <senorblanco at chromium.org>
View in context: https://bugs.webkit.org/attachment.cgi?id=160208&action=review


Thanks for the fixes.  Remaining comments are optional.  r=me

> Source/WebCore/platform/graphics/chromium/Canvas2DLayerBridge.cpp:114
> +    Canvas2DLayerManager::get().layerAllocatedStorageChanged(this);

If you wanted to, I think you could remove m_newBytesAllocated in each layer by
passing the old and new sizes (or the delta) directly to the manager when
they're changed on the layer.  Then you wouldn't need to pick them up later.

> Source/WebCore/platform/graphics/chromium/Canvas2DLayerBridge.cpp:127
> +    m_newBytesAllocated = deferredCanvas()->storageAllocatedForRecording();

Same as above.


More information about the webkit-reviews mailing list