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

Issue 2790623003: ui: Rework CompositorResizeLock interaction with DelegatedFrameHost (Closed)

Created:
3 years, 8 months ago by danakj
Modified:
3 years, 8 months ago
Reviewers:
piman
CC:
chromium-reviews, yusukes+watch_chromium.org, shuchen+watch_chromium.org, jam, jbauman+watch_chromium.org, nona+watch_chromium.org, darin-cc_chromium.org, piman+watch_chromium.org, kalyank, danakj+watch_chromium.org, James Su, xjz+watch_chromium.org, miu+watch_chromium.org, ericrk, wutao
Target Ref:
refs/heads/master
Project:
chromium
Visibility:
Public.

Description

Rework UI CompositorResizeLock interaction with DelegatedFrameHost This removes the CanLockCompositorState enum, and replaces it with 2 bools, in order to disconnect the resize lock from the renderer. The old code was built on the assumption that renderer frames will cause a commit in the UI but this is no longer the case as they go directly to the display compositor (which is now separate from the UI compositor). Now the bools track things for the UI compositor. The first bool |create_resize_lock_after_commit_| allows us to get rid of the resize lock if it times out. While this bool is true we do not remake a resize lock in the meantime, and once the UI makes a single frame and commits, we can re-lock the UI compositor as we make a new resize lock. The second bool is the only interaction of the resize lock with the renderer, allowing a renderer frame to be submitted once the lock has timed out, since we're allowing one UI frame through also, so that a slow renderer (causing timeout) will not remain at its original size indefinitely. This 2nd bool's name is |allow_one_renderer_frame_during_resize_lock_|. These changes I made also mean that we no longer entertain the concept of deferred resize locks. This was used to allow the UI to make a frame before locking the compositor. Now we just always hold/release the resize lock directly, along with |create_resize_lock_after_commit_| state to prevent relocking the UI before producing a frame after unlock. R=piman@chromium.org BUG=704928 Review-Url: https://codereview.chromium.org/2790623003 Cr-Commit-Position: refs/heads/master@{#461734} Committed: https://chromium.googlesource.com/chromium/src/+/62a56f6fcfea29c8dfd333156b0e704f0f1ff525

Patch Set 1 #

Patch Set 2 : shouldskip: . #

Patch Set 3 : shouldskip: . #

Total comments: 2

Patch Set 4 : shouldskip: . #

Patch Set 5 : shouldskip: mac-compile #

Patch Set 6 : shouldskip: dcheck #

Total comments: 1

Patch Set 7 : shouldskip: allowskipafterframe #

Messages

Total messages: 22 (16 generated)
piman
https://codereview.chromium.org/2790623003/diff/40001/content/browser/renderer_host/delegated_frame_host.cc File content/browser/renderer_host/delegated_frame_host.cc (right): https://codereview.chromium.org/2790623003/diff/40001/content/browser/renderer_host/delegated_frame_host.cc#newcode716 content/browser/renderer_host/delegated_frame_host.cc:716: // which will gutter anyways. Ok, here I think ...
3 years, 8 months ago (2017-03-31 00:31:55 UTC) #6
danakj
https://codereview.chromium.org/2790623003/diff/40001/content/browser/renderer_host/delegated_frame_host.cc File content/browser/renderer_host/delegated_frame_host.cc (right): https://codereview.chromium.org/2790623003/diff/40001/content/browser/renderer_host/delegated_frame_host.cc#newcode716 content/browser/renderer_host/delegated_frame_host.cc:716: // which will gutter anyways. On 2017/03/31 00:31:55, piman ...
3 years, 8 months ago (2017-03-31 19:34:42 UTC) #7
danakj
I also fixed the mac compile (had to delete an empty NOTREACHED method) and fixed ...
3 years, 8 months ago (2017-03-31 19:43:56 UTC) #9
piman
LGTM. I really appreciate the work on this. https://codereview.chromium.org/2790623003/diff/100001/content/browser/renderer_host/delegated_frame_host.cc File content/browser/renderer_host/delegated_frame_host.cc (right): https://codereview.chromium.org/2790623003/diff/100001/content/browser/renderer_host/delegated_frame_host.cc#newcode242 content/browser/renderer_host/delegated_frame_host.cc:242: allow_one_renderer_frame_during_resize_lock_ ...
3 years, 8 months ago (2017-04-04 00:16:25 UTC) #16
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2790623003/120001
3 years, 8 months ago (2017-04-04 14:55:50 UTC) #19
commit-bot: I haz the power
3 years, 8 months ago (2017-04-04 15:53:56 UTC) #22
Message was sent while issue was closed.
Committed patchset #7 (id:120001) as
https://chromium.googlesource.com/chromium/src/+/62a56f6fcfea29c8dfd333156b0e...

Powered by Google App Engine
This is Rietveld 408576698