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

Issue 2873313004: Harmonize LayerTreeHost/LayerTreeHostImpl synchronization steps (Closed)

Created:
3 years, 7 months ago by pdr.
Modified:
3 years, 7 months ago
CC:
cc-bugs_chromium.org, chromium-reviews
Target Ref:
refs/heads/master
Project:
chromium
Visibility:
Public.

Description

Harmonize LayerTreeHost/LayerTreeHostImpl synchronization steps Both LayerTreeHost::FinishCommitOnImpl and LayerTreeHostImpl::ActivateSyncTree follow these rough steps to synchronize with the LayerTreeHostImpl: 1) Update property trees. 2) Update layer properties, possibly with side effects. 3) Push layer tree host properties (e.g., viewport types and page scale factor). These steps have implicit dependencies: layer property updates may require property trees, and the viewport layer type update may require layer properties. Before this patch, LayerTreeHost and LayerTreeHostImpl followed these steps in different orders. This patch refactors the synchronization code to use the same ordering, and adds DCHECKs to enforce dependencies. BUG=693740 CQ_INCLUDE_TRYBOTS=master.tryserver.blink:linux_trusty_blink_rel;master.tryserver.chromium.linux:linux_layout_tests_slimming_paint_v2 Review-Url: https://codereview.chromium.org/2873313004 Cr-Commit-Position: refs/heads/master@{#472004} Committed: https://chromium.googlesource.com/chromium/src/+/80ecb98035a6654fff02e86877be39f51fcc3d54

Patch Set 1 #

Patch Set 2 : More harmonious #

Total comments: 23

Patch Set 3 : harmonize with reviewers #

Patch Set 4 : Improve comments #

Patch Set 5 : Fix merge conflict with https://codereview.chromium.org/2877033002 #

Total comments: 1

Patch Set 6 : Improve reviewability #

Total comments: 3

Patch Set 7 : Remove redundant codes #

Patch Set 8 : Ace of rebase #

Unified diffs Side-by-side diffs Delta from patch set Stats (+151 lines, -48 lines) Patch
M cc/layers/layer.cc View 1 2 3 4 1 chunk +4 lines, -0 lines 0 comments Download
M cc/trees/layer_tree_host.h View 1 2 3 4 5 6 7 1 chunk +3 lines, -1 line 0 comments Download
M cc/trees/layer_tree_host.cc View 1 2 3 4 5 6 7 8 chunks +49 lines, -30 lines 0 comments Download
M cc/trees/layer_tree_host_impl.cc View 1 2 3 4 5 6 7 2 chunks +10 lines, -13 lines 0 comments Download
M cc/trees/layer_tree_impl.h View 1 2 3 4 5 4 chunks +42 lines, -1 line 0 comments Download
M cc/trees/layer_tree_impl.cc View 1 2 3 4 5 6 8 chunks +43 lines, -3 lines 0 comments Download

Messages

Total messages: 51 (29 generated)
pdr.
3 years, 7 months ago (2017-05-12 16:09:39 UTC) #7
enne (OOO)
Excited about this overall, but have a bunch of cleanup thoughts: https://codereview.chromium.org/2873313004/diff/20001/cc/trees/layer_tree_host_impl.h File cc/trees/layer_tree_host_impl.h (right): ...
3 years, 7 months ago (2017-05-12 17:25:07 UTC) #8
jaydasika
https://codereview.chromium.org/2873313004/diff/20001/cc/trees/layer_tree_impl.cc File cc/trees/layer_tree_impl.cc (right): https://codereview.chromium.org/2873313004/diff/20001/cc/trees/layer_tree_impl.cc#newcode206 cc/trees/layer_tree_impl.cc:206: // DCHECK(layer_tree_host_impl_->SyncStateComplete(SYNCED_LAYER_PROPERTIES)); Something related I just noticed : LayerImpl::SetBounds ...
3 years, 7 months ago (2017-05-12 18:19:16 UTC) #9
pdr.
On 2017/05/12 at 17:25:07, enne wrote: > Excited about this overall, but have a bunch ...
3 years, 7 months ago (2017-05-12 21:49:59 UTC) #10
enne (OOO)
I'm fine with your original approach here, but I'd like to move towards putting them ...
3 years, 7 months ago (2017-05-12 22:12:47 UTC) #11
chrishtr
https://codereview.chromium.org/2873313004/diff/20001/cc/trees/layer_tree_host.cc File cc/trees/layer_tree_host.cc (right): https://codereview.chromium.org/2873313004/diff/20001/cc/trees/layer_tree_host.cc#newcode332 cc/trees/layer_tree_host.cc:332: PushPropertiesTo(sync_tree); How about renaming this to PushLayerTreeHostPropertiesTo, and also ...
3 years, 7 months ago (2017-05-12 23:13:30 UTC) #12
pdr.
PTAL! https://codereview.chromium.org/2873313004/diff/20001/cc/trees/layer_tree_host.cc File cc/trees/layer_tree_host.cc (right): https://codereview.chromium.org/2873313004/diff/20001/cc/trees/layer_tree_host.cc#newcode332 cc/trees/layer_tree_host.cc:332: PushPropertiesTo(sync_tree); On 2017/05/12 at 23:13:29, chrishtr wrote: > ...
3 years, 7 months ago (2017-05-15 18:30:24 UTC) #19
chrishtr
https://codereview.chromium.org/2873313004/diff/80001/cc/layers/layer_impl.cc File cc/layers/layer_impl.cc (left): https://codereview.chromium.org/2873313004/diff/80001/cc/layers/layer_impl.cc#oldcode284 cc/layers/layer_impl.cc:284: // Ensure our viewport layer type is updated. Per ...
3 years, 7 months ago (2017-05-15 18:50:45 UTC) #22
pdr.
https://codereview.chromium.org/2873313004/diff/20001/cc/trees/layer_tree_impl.cc File cc/trees/layer_tree_impl.cc (right): https://codereview.chromium.org/2873313004/diff/20001/cc/trees/layer_tree_impl.cc#newcode1008 cc/trees/layer_tree_impl.cc:1008: // TODO(pdr): This DCHECK fails on existing tests but ...
3 years, 7 months ago (2017-05-15 18:56:42 UTC) #23
chrishtr
Looking good to me. I will wait for Enne's review of the lifecycle pattern.
3 years, 7 months ago (2017-05-15 18:57:15 UTC) #24
enne (OOO)
lgtm https://codereview.chromium.org/2873313004/diff/100001/cc/trees/layer_tree_impl.cc File cc/trees/layer_tree_impl.cc (right): https://codereview.chromium.org/2873313004/diff/100001/cc/trees/layer_tree_impl.cc#newcode64 cc/trees/layer_tree_impl.cc:64: state_ = next_state; Redundant? https://codereview.chromium.org/2873313004/diff/100001/cc/trees/layer_tree_impl.cc#newcode410 cc/trees/layer_tree_impl.cc:410: if (target_tree->property_trees()->changed) ...
3 years, 7 months ago (2017-05-15 20:48:16 UTC) #27
pdr.
https://codereview.chromium.org/2873313004/diff/100001/cc/trees/layer_tree_impl.cc File cc/trees/layer_tree_impl.cc (right): https://codereview.chromium.org/2873313004/diff/100001/cc/trees/layer_tree_impl.cc#newcode64 cc/trees/layer_tree_impl.cc:64: state_ = next_state; On 2017/05/15 at 20:48:16, enne wrote: ...
3 years, 7 months ago (2017-05-15 20:51:07 UTC) #28
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/2873313004/120001
3 years, 7 months ago (2017-05-15 20:58:13 UTC) #31
commit-bot: I haz the power
Try jobs failed on following builders: win_chromium_x64_rel_ng on master.tryserver.chromium.win (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.win/builders/win_chromium_x64_rel_ng/builds/427202)
3 years, 7 months ago (2017-05-15 22:50:44 UTC) #33
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/2873313004/120001
3 years, 7 months ago (2017-05-15 22:54:19 UTC) #35
commit-bot: I haz the power
Try jobs failed on following builders: chromium_presubmit on master.tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/chromium_presubmit/builds/437542)
3 years, 7 months ago (2017-05-15 23:06:36 UTC) #37
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/2873313004/140001
3 years, 7 months ago (2017-05-15 23:23:25 UTC) #40
commit-bot: I haz the power
Try jobs failed on following builders: win_chromium_rel_ng on master.tryserver.chromium.win (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.win/builders/win_chromium_rel_ng/builds/445166)
3 years, 7 months ago (2017-05-16 01:16:08 UTC) #42
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/2873313004/140001
3 years, 7 months ago (2017-05-16 01:40:51 UTC) #44
commit-bot: I haz the power
Try jobs failed on following builders: win_chromium_rel_ng on master.tryserver.chromium.win (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.win/builders/win_chromium_rel_ng/builds/445344)
3 years, 7 months ago (2017-05-16 02:05:16 UTC) #46
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/2873313004/140001
3 years, 7 months ago (2017-05-16 02:28:07 UTC) #48
commit-bot: I haz the power
3 years, 7 months ago (2017-05-16 03:40:25 UTC) #51
Message was sent while issue was closed.
Committed patchset #8 (id:140001) as
https://chromium.googlesource.com/chromium/src/+/80ecb98035a6654fff02e86877be...

Powered by Google App Engine
This is Rietveld 408576698