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

Issue 209003014: update3dRenderingContext is 13.5% of GraphicsLayerUpdater::rebuildTree (Closed)

Created:
6 years, 9 months ago by abarth-chromium
Modified:
6 years, 9 months ago
Reviewers:
Ian Vollick, esprehn, ojan
CC:
blink-reviews, bemjb+rendering_chromium.org, dsinclair, zoltan1, eae+blinkwatch, leviw+renderwatch, abarth-chromium, blink-layers+watch_chromium.org, jchaffraix+rendering, pdr., rune+blink, ojan, Ian Vollick
Visibility:
Public.

Description

update3dRenderingContext is 13.5% of GraphicsLayerUpdater::rebuildTree Prior to this CL, we were recomputing the 3D rendering context root for every RenderLayer every frame. That work accounted for 13.5% of GraphicsLayerUpdater::rebuildTree and 2.4% of the entire compositing update. This work is almost entirely wasted because the 3D rendering context is completely determined by style information and therefore can change only when style changes. Elliott and I looked at integrating this computation with recalc style, but upon studying the code closely, I realize that this function doesn't actually walk up the tree very far. Instead, it looks only at the enclosing render layer of the containing block. That means we don't need to cache this data on RenderLayer at all. Instead, we can recompute it when needed by the one caller: CompositedLayerMapping::updateRenderingContext. That caller only cares about RenderLayers that actually have a composited layer mapping, which is vastly fewer than all RenderLayers. Moreover, that caller already understands dirtiness caused by style changes. Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=170090

Patch Set 1 #

Total comments: 3

Patch Set 2 : Fix stray add #

Total comments: 5

Patch Set 3 : Fixenate #

Patch Set 4 : More fixing #

Total comments: 1

Patch Set 5 : Account for crazy code #

Unified diffs Side-by-side diffs Delta from patch set Stats (+26 lines, -28 lines) Patch
M Source/core/rendering/RenderLayer.h View 1 2 3 chunks +2 lines, -7 lines 0 comments Download
M Source/core/rendering/RenderLayer.cpp View 1 2 3 4 2 chunks +15 lines, -12 lines 0 comments Download
M Source/core/rendering/RenderObject.cpp View 1 2 3 4 1 chunk +8 lines, -7 lines 0 comments Download
M Source/core/rendering/compositing/CompositedLayerMapping.cpp View 1 2 3 4 1 chunk +1 line, -1 line 0 comments Download
M Source/core/rendering/compositing/GraphicsLayerUpdater.cpp View 1 2 1 chunk +0 lines, -1 line 0 comments Download

Messages

Total messages: 41 (0 generated)
abarth-chromium
6 years, 9 months ago (2014-03-25 01:21:30 UTC) #1
ojan
lgtm https://codereview.chromium.org/209003014/diff/1/Source/core/rendering/RenderLayer.cpp File Source/core/rendering/RenderLayer.cpp (right): https://codereview.chromium.org/209003014/diff/1/Source/core/rendering/RenderLayer.cpp#newcode569 Source/core/rendering/RenderLayer.cpp:569: // FIXME: Why doesn't this need to be ...
6 years, 9 months ago (2014-03-25 01:35:59 UTC) #2
abarth-chromium
https://codereview.chromium.org/209003014/diff/1/Source/core/rendering/compositing/GraphicsLayerUpdater.cpp File Source/core/rendering/compositing/GraphicsLayerUpdater.cpp (right): https://codereview.chromium.org/209003014/diff/1/Source/core/rendering/compositing/GraphicsLayerUpdater.cpp#newcode161 Source/core/rendering/compositing/GraphicsLayerUpdater.cpp:161: On 2014/03/25 01:36:00, ojan wrote: > Did you mean ...
6 years, 9 months ago (2014-03-25 02:31:37 UTC) #3
abarth-chromium
The CQ bit was checked by abarth@chromium.org
6 years, 9 months ago (2014-03-25 02:34:58 UTC) #4
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/abarth@chromium.org/209003014/20001
6 years, 9 months ago (2014-03-25 02:35:03 UTC) #5
esprehn
This changes the behavior. The function previously would reset the value if you were !shouldFlattenTransform() ...
6 years, 9 months ago (2014-03-25 02:39:35 UTC) #6
esprehn
The CQ bit was unchecked by esprehn@chromium.org
6 years, 9 months ago (2014-03-25 02:39:38 UTC) #7
abarth-chromium
https://codereview.chromium.org/209003014/diff/20001/Source/core/rendering/RenderLayer.cpp File Source/core/rendering/RenderLayer.cpp (right): https://codereview.chromium.org/209003014/diff/20001/Source/core/rendering/RenderLayer.cpp#newcode566 Source/core/rendering/RenderLayer.cpp:566: if (!shouldFlattenTransform()) On 2014/03/25 02:39:35, esprehn wrote: > I ...
6 years, 9 months ago (2014-03-25 02:59:38 UTC) #8
ojan
https://codereview.chromium.org/209003014/diff/20001/Source/core/rendering/RenderLayer.cpp File Source/core/rendering/RenderLayer.cpp (right): https://codereview.chromium.org/209003014/diff/20001/Source/core/rendering/RenderLayer.cpp#newcode566 Source/core/rendering/RenderLayer.cpp:566: if (!shouldFlattenTransform()) On 2014/03/25 02:59:39, abarth wrote: > On ...
6 years, 9 months ago (2014-03-25 04:16:27 UTC) #9
Ian Vollick
The 3D rendering context id is an ancestor dependent property like containing block or scroll ...
6 years, 9 months ago (2014-03-25 14:40:01 UTC) #10
abarth-chromium
Thanks for the detailed explanation. IMHO, the first step here is for me to write ...
6 years, 9 months ago (2014-03-25 15:12:42 UTC) #11
abarth-chromium
I made a test case that fails, but fixing this code didn't actually fix it. ...
6 years, 9 months ago (2014-03-25 22:28:49 UTC) #12
abarth-chromium
The CQ bit was checked by abarth@chromium.org
6 years, 9 months ago (2014-03-25 22:28:54 UTC) #13
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/abarth@chromium.org/209003014/90001
6 years, 9 months ago (2014-03-25 22:28:58 UTC) #14
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 9 months ago (2014-03-25 23:23:28 UTC) #15
commit-bot: I haz the power
Try jobs failed on following builders: tryserver.blink on linux_blink_dbg
6 years, 9 months ago (2014-03-25 23:23:29 UTC) #16
esprehn
The CQ bit was checked by esprehn@chromium.org
6 years, 9 months ago (2014-03-25 23:26:41 UTC) #17
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/abarth@chromium.org/209003014/90001
6 years, 9 months ago (2014-03-25 23:26:43 UTC) #18
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 9 months ago (2014-03-26 00:03:14 UTC) #19
commit-bot: I haz the power
Try jobs failed on following builders: tryserver.blink on linux_blink_dbg
6 years, 9 months ago (2014-03-26 00:03:14 UTC) #20
esprehn
The CQ bit was checked by esprehn@chromium.org
6 years, 9 months ago (2014-03-26 00:04:53 UTC) #21
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/abarth@chromium.org/209003014/90001
6 years, 9 months ago (2014-03-26 00:05:17 UTC) #22
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 9 months ago (2014-03-26 00:34:18 UTC) #23
commit-bot: I haz the power
Try jobs failed on following builders: tryserver.blink on linux_blink_dbg
6 years, 9 months ago (2014-03-26 00:34:19 UTC) #24
abarth-chromium
https://codereview.chromium.org/209003014/diff/90001/Source/core/rendering/RenderObject.cpp File Source/core/rendering/RenderObject.cpp (right): https://codereview.chromium.org/209003014/diff/90001/Source/core/rendering/RenderObject.cpp#newcode532 Source/core/rendering/RenderObject.cpp:532: ASSERT_NOT_REACHED(); Looks like this line can be reached. /me ...
6 years, 9 months ago (2014-03-26 05:24:21 UTC) #25
abarth-chromium
Turns out FrameView::paintContents is calling enclosingLayer on a null pointer. I've removed the ASSERT for ...
6 years, 9 months ago (2014-03-26 17:28:23 UTC) #26
abarth-chromium
The CQ bit was checked by abarth@chromium.org
6 years, 9 months ago (2014-03-26 17:28:28 UTC) #27
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/abarth@chromium.org/209003014/260001
6 years, 9 months ago (2014-03-26 17:28:38 UTC) #28
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 9 months ago (2014-03-26 17:39:01 UTC) #29
commit-bot: I haz the power
Try jobs failed on following builders: tryserver.blink on win_blink_rel
6 years, 9 months ago (2014-03-26 17:39:02 UTC) #30
esprehn
The CQ bit was checked by esprehn@chromium.org
6 years, 9 months ago (2014-03-26 17:40:15 UTC) #31
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/abarth@chromium.org/209003014/260001
6 years, 9 months ago (2014-03-26 17:40:21 UTC) #32
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 9 months ago (2014-03-26 18:16:24 UTC) #33
commit-bot: I haz the power
Try jobs failed on following builders: tryserver.blink on win_blink_rel
6 years, 9 months ago (2014-03-26 18:16:25 UTC) #34
esprehn
The CQ bit was checked by esprehn@chromium.org
6 years, 9 months ago (2014-03-26 18:32:22 UTC) #35
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/abarth@chromium.org/209003014/260001
6 years, 9 months ago (2014-03-26 18:32:32 UTC) #36
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 9 months ago (2014-03-26 18:33:33 UTC) #37
commit-bot: I haz the power
Try jobs failed on following builders: tryserver.blink on linux_blink_dbg
6 years, 9 months ago (2014-03-26 18:33:34 UTC) #38
esprehn
The CQ bit was checked by esprehn@chromium.org
6 years, 9 months ago (2014-03-26 19:03:45 UTC) #39
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/abarth@chromium.org/209003014/260001
6 years, 9 months ago (2014-03-26 19:03:57 UTC) #40
commit-bot: I haz the power
6 years, 9 months ago (2014-03-26 20:06:56 UTC) #41
Message was sent while issue was closed.
Change committed as 170090

Powered by Google App Engine
This is Rietveld 408576698