Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(195)

Issue 2417343003: [Merge M55] aw: Fix effective frame source leak after detach (Closed)

Created:
4 years, 2 months ago by boliu
Modified:
4 years, 2 months ago
Reviewers:
CC:
chromium-reviews, android-webview-reviews_chromium.org
Target Ref:
refs/pending/branch-heads/2883
Project:
chromium
Visibility:
Public.

Description

[Merge M55] aw: Fix effective frame source leak after detach shouqun@ discovered that destroying the SurfaceFactory before all resources belonging to that surface are returned will lead to those resources being dropped completely, since cc::Display only holds onto a weakptr to SurfaceFactory to return resources. Webview goes through this cycle each time it's detached and re-attached, so the "lost" resources will keep growing until the memory budget is reached. Note though that destroying the webview does free these resources, so they are not lost forever. But detach/attach is very common, and this is still a severe leak. Fix by submitting an empty frame into the Surface, which forces resources from the previous frame to be returned. BUG=655434 Review-Url: https://codereview.chromium.org/2423473002 Cr-Commit-Position: refs/heads/master@{#425466} (cherry picked from commit 2fd5e46f7fba4945e86a5c4cd9297a6eaf2417df) Committed: https://chromium.googlesource.com/chromium/src/+/75fa605f8ee74897558c6ccba1f6ed525c9d3fe1

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+8 lines, -0 lines) Patch
M android_webview/browser/hardware_renderer.cc View 1 chunk +8 lines, -0 lines 0 comments Download

Messages

Total messages: 2 (1 generated)
boliu
4 years, 2 months ago (2016-10-14 23:01:03 UTC) #2
Message was sent while issue was closed.
Committed patchset #1 (id:1) manually as
75fa605f8ee74897558c6ccba1f6ed525c9d3fe1.

Powered by Google App Engine
This is Rietveld 408576698