RESOLVED FIXED Bug 75632
[Chromium] Avoid unnecessary TextureManager::reduceMemoryToLimit()
https://bugs.webkit.org/show_bug.cgi?id=75632
Summary [Chromium] Avoid unnecessary TextureManager::reduceMemoryToLimit()
Xianzhu Wang
Reported 2012-01-05 10:49:08 PST
(Split from bug 72078) Unnecessary TextureManager::reduceMemoryToLimit() will cause some tile textures that are required soon to be unnecessarily removed/replaced, when required texture memory is higher than the reclaim limit but lower than the absolute limit. This will and degrade performance, sometimes significantly. For example, CCLayerTreeHost::setViewport will be called during scrolling. The original code would call TextureManager::reduceMemoryToLimit(), causing some textures unnecessarily discarded and then recreated repeatedly during scrolling. It's also unnecessary to call TextureManager::reduceMemoryToLimit() from TextureManager::setPreferredMemoryLimitBytes() because the limit is not a hard limit. The callers should call reduceMemoryToLimit() explicitly if it wants it when setting the preferred memory limit.
Attachments
patch (updated based on the patch in bug 72078) (26.87 KB, patch)
2012-01-05 17:13 PST, Xianzhu Wang
no flags
Xianzhu Wang
Comment 1 2012-01-05 17:13:48 PST
Created attachment 121372 [details] patch (updated based on the patch in bug 72078)
Adrienne Walker
Comment 2 2012-01-06 13:33:14 PST
Nice catch. Calling reduceMemoryToLimit when setting limits really seems like the wrong thing to be doing.
James Robinson
Comment 3 2012-01-06 17:54:27 PST
Comment on attachment 121372 [details] patch (updated based on the patch in bug 72078) R=me, great tests! Set cq? when you're ready for this to land.
Xianzhu Wang
Comment 4 2012-01-09 09:51:27 PST
Comment on attachment 121372 [details] patch (updated based on the patch in bug 72078) Thanks for review. Try to cq+ by myself.
WebKit Review Bot
Comment 5 2012-01-09 12:16:59 PST
Comment on attachment 121372 [details] patch (updated based on the patch in bug 72078) Clearing flags on attachment: 121372 Committed r104474: <http://trac.webkit.org/changeset/104474>
WebKit Review Bot
Comment 6 2012-01-09 12:17:04 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.