Bug 153325

Summary: CGImageSource sometimes retains temporary SharedBuffer data indefinitely, doubling memory cost.
Product: WebKit Reporter: Andreas Kling <kling>
Component: ImagesAssignee: Andreas Kling <kling>
Status: RESOLVED FIXED    
Severity: Normal CC: cdumez, commit-queue, japhet, koivisto
Priority: P2 Keywords: Performance
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch none

Andreas Kling
Reported 2016-01-21 14:40:56 PST
When replacing the internal buffer of a SharedBuffer with mmap'ed file-backed pages, we may still have an ImageSource (inside of CachedImage::m_image) retaining the old heap-allocated resource buffer. This means that we pay double the memory cost for encoded data in downloaded resources that get cached for the first time.
Attachments
Patch (4.77 KB, patch)
2016-01-21 14:41 PST, Andreas Kling
no flags
Andreas Kling
Comment 1 2016-01-21 14:41:35 PST
WebKit Commit Bot
Comment 2 2016-01-21 18:00:53 PST
Comment on attachment 269495 [details] Patch Clearing flags on attachment: 269495 Committed r195430: <http://trac.webkit.org/changeset/195430>
WebKit Commit Bot
Comment 3 2016-01-21 18:00:57 PST
All reviewed patches have been landed. Closing bug.
Note You need to log in before you can comment on or make changes to this bug.