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

Issue 1813383002: Move all fast-path paint invalidation mapping into PaintInvalidationState (Closed)

Created:
4 years, 9 months ago by Xianzhu
Modified:
4 years, 9 months ago
CC:
blink-layers+watch_chromium.org, blink-reviews, blink-reviews-dom_chromium.org, blink-reviews-layout_chromium.org, blink-reviews-paint_chromium.org, chromium-reviews, dglazkov+blink, dshwang, krit, eae+blinkwatch, f(malita), fs, gyuyoung2, jchaffraix+rendering, kenneth.christiansen, kouhei+svg_chromium.org, leviw+renderwatch, pdr+renderingwatchlist_chromium.org, pdr+svgwatchlist_chromium.org, rwlbuis, Stephen Chennney, sof, slimming-paint-reviews_chromium.org, szager+layoutwatch_chromium.org, zoltan1
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Move all fast-path paint invalidation mapping into PaintInvalidationState - Remove the optional const PaintInvalidationState* parameter from paint invalidation mapping methods and move fast-path mapping code into PaintInvalidationState. - PaintLayer::computePaintInvalidationRect() is now PaintInvalidationState::computePaintInvalidationRectInBacking(); PaintLayer::positionFromPaintInvalidationBacking() is now PaintInvalidationState::positionFromPaintInvalidationBacking(); PaintLayer::mapRectToPaintInvalidationBacking() is now PaintInvalidationState::mapLocalRectToPaintInvalidationBacking(). - Change LayoutObject::clippedOverflowRectForPaintInvalidationBacking() to: * Non-SVG objects and LayoutSVGRoot: LayoutObject::localOverflowRectForPaintInvalidation() which doesn't map the rect to paint invalidation backing; * SVG objects except LayoutSVGRoot: Using existing paintInvalidationRectInLocalSVGCoordinates() PaintInvalidationState::computePaintInvalidationRectInBacking(), calls the above functions to get the local paint invalidation rect, and map to paintInvalidationContainer using fast path if possible, or slow path by calling LayoutObject::mapToVisibleRectToAncestor(). - Let selection paint invalidation go through fast-path if possible. BUG=591199 Committed: https://crrev.com/934f67a68da2054e526e13648c5452e2cf79c211 Cr-Commit-Position: refs/heads/master@{#383430}

Patch Set 1 #

Patch Set 2 : #

Patch Set 3 : #

Patch Set 4 : #

Patch Set 5 : #

Patch Set 6 : #

Patch Set 7 : #

Patch Set 8 : #

Total comments: 1

Patch Set 9 : Rebase; Fix multicol; TestExpectations #

Patch Set 10 : Reorganize conditions in PaintInvalidationState constructor #

Total comments: 47

Patch Set 11 : #

Total comments: 2

Patch Set 12 : #

Total comments: 4

Patch Set 13 : #

Total comments: 1

Patch Set 14 : #

Total comments: 5

Patch Set 15 : Rebase #

Total comments: 2

Patch Set 16 : Move absolute-position under relative-position inline to slow path; remove using directives #

Patch Set 17 : Disable fast-path/slow-path comparison because of saturated operations of LayoutUnit #

Unified diffs Side-by-side diffs Delta from patch set Stats (+496 lines, -478 lines) Patch
M third_party/WebKit/LayoutTests/TestExpectations View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +2 lines, -0 lines 0 comments Download
M third_party/WebKit/LayoutTests/platform/linux/fast/repaint/repaint-during-scroll-with-zoom-expected.txt View 1 2 3 4 5 1 chunk +1 line, -2 lines 0 comments Download
M third_party/WebKit/LayoutTests/svg/as-object/nested-embedded-svg-size-changes-no-layout-triggers-1-expected.txt View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +3 lines, -3 lines 0 comments Download
M third_party/WebKit/LayoutTests/svg/as-object/nested-embedded-svg-size-changes-no-layout-triggers-2-expected.txt View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +3 lines, -3 lines 0 comments Download
M third_party/WebKit/Source/core/dom/IntersectionObservation.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +1 line, -1 line 0 comments Download
M third_party/WebKit/Source/core/frame/FrameView.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 13 3 chunks +4 lines, -7 lines 0 comments Download
M third_party/WebKit/Source/core/layout/LayoutBox.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 2 chunks +2 lines, -2 lines 0 comments Download
M third_party/WebKit/Source/core/layout/LayoutBox.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 13 6 chunks +11 lines, -15 lines 0 comments Download
M third_party/WebKit/Source/core/layout/LayoutBoxModelObject.cpp View 1 2 3 4 5 3 chunks +5 lines, -3 lines 0 comments Download
M third_party/WebKit/Source/core/layout/LayoutFlowThread.h View 1 2 3 4 5 6 7 8 9 10 11 12 2 chunks +1 line, -3 lines 0 comments Download
M third_party/WebKit/Source/core/layout/LayoutFlowThread.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 2 chunks +2 lines, -2 lines 0 comments Download
M third_party/WebKit/Source/core/layout/LayoutInline.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +2 lines, -2 lines 0 comments Download
M third_party/WebKit/Source/core/layout/LayoutInline.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 13 4 chunks +4 lines, -7 lines 0 comments Download
M third_party/WebKit/Source/core/layout/LayoutMultiColumnSpannerPlaceholder.h View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +1 line, -1 line 0 comments Download
M third_party/WebKit/Source/core/layout/LayoutMultiColumnSpannerPlaceholder.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +3 lines, -5 lines 0 comments Download
M third_party/WebKit/Source/core/layout/LayoutObject.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 9 chunks +14 lines, -16 lines 0 comments Download
M third_party/WebKit/Source/core/layout/LayoutObject.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 13 16 chunks +21 lines, -46 lines 0 comments Download
M third_party/WebKit/Source/core/layout/LayoutObjectTest.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 3 chunks +6 lines, -6 lines 0 comments Download
M third_party/WebKit/Source/core/layout/LayoutPart.cpp View 1 2 3 4 5 1 chunk +2 lines, -2 lines 0 comments Download
M third_party/WebKit/Source/core/layout/LayoutReplaced.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +1 line, -1 line 0 comments Download
M third_party/WebKit/Source/core/layout/LayoutTableCell.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +1 line, -1 line 0 comments Download
M third_party/WebKit/Source/core/layout/LayoutTableCell.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +3 lines, -3 lines 0 comments Download
M third_party/WebKit/Source/core/layout/LayoutView.h View 1 2 3 4 5 6 7 8 9 10 11 12 2 chunks +4 lines, -10 lines 0 comments Download
M third_party/WebKit/Source/core/layout/LayoutView.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 13 7 chunks +18 lines, -16 lines 0 comments Download
M third_party/WebKit/Source/core/layout/PaintInvalidationState.h View 1 2 3 4 5 6 7 8 9 10 11 12 5 chunks +26 lines, -37 lines 0 comments Download
M third_party/WebKit/Source/core/layout/PaintInvalidationState.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 6 chunks +231 lines, -105 lines 0 comments Download
M third_party/WebKit/Source/core/layout/compositing/CompositedLayerMapping.cpp View 1 chunk +1 line, -1 line 0 comments Download
M third_party/WebKit/Source/core/layout/svg/LayoutSVGBlock.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 2 chunks +4 lines, -4 lines 0 comments Download
M third_party/WebKit/Source/core/layout/svg/LayoutSVGBlock.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 3 chunks +7 lines, -8 lines 0 comments Download
M third_party/WebKit/Source/core/layout/svg/LayoutSVGGradientStop.h View 1 chunk +1 line, -1 line 0 comments Download
M third_party/WebKit/Source/core/layout/svg/LayoutSVGHiddenContainer.h View 1 2 3 4 6 1 chunk +2 lines, -1 line 0 comments Download
M third_party/WebKit/Source/core/layout/svg/LayoutSVGInline.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 1 chunk +2 lines, -2 lines 0 comments Download
M third_party/WebKit/Source/core/layout/svg/LayoutSVGInline.cpp View 1 2 3 4 3 chunks +6 lines, -5 lines 0 comments Download
M third_party/WebKit/Source/core/layout/svg/LayoutSVGInlineText.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 1 chunk +2 lines, -1 line 0 comments Download
M third_party/WebKit/Source/core/layout/svg/LayoutSVGInlineText.cpp View 1 2 3 4 5 6 7 8 1 chunk +7 lines, -5 lines 0 comments Download
M third_party/WebKit/Source/core/layout/svg/LayoutSVGModelObject.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 1 chunk +3 lines, -4 lines 0 comments Download
M third_party/WebKit/Source/core/layout/svg/LayoutSVGModelObject.cpp View 1 2 3 4 2 chunks +5 lines, -5 lines 0 comments Download
M third_party/WebKit/Source/core/layout/svg/LayoutSVGRoot.h View 1 2 3 4 5 6 7 8 9 10 11 12 2 chunks +3 lines, -3 lines 0 comments Download
M third_party/WebKit/Source/core/layout/svg/LayoutSVGRoot.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 3 chunks +11 lines, -11 lines 0 comments Download
M third_party/WebKit/Source/core/layout/svg/LayoutSVGShape.h View 1 2 1 chunk +0 lines, -2 lines 0 comments Download
M third_party/WebKit/Source/core/layout/svg/LayoutSVGShape.cpp View 1 2 1 chunk +0 lines, -9 lines 0 comments Download
M third_party/WebKit/Source/core/layout/svg/LayoutSVGText.cpp View 1 2 3 4 5 6 7 8 9 10 1 chunk +2 lines, -1 line 0 comments Download
M third_party/WebKit/Source/core/layout/svg/SVGLayoutSupport.h View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +5 lines, -6 lines 0 comments Download
M third_party/WebKit/Source/core/layout/svg/SVGLayoutSupport.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 3 chunks +40 lines, -60 lines 0 comments Download
M third_party/WebKit/Source/core/page/scrolling/ScrollingCoordinator.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +1 line, -1 line 0 comments Download
M third_party/WebKit/Source/core/paint/PaintInvalidationCapableScrollableArea.cpp View 1 2 3 4 5 6 7 8 9 10 1 chunk +1 line, -1 line 0 comments Download
M third_party/WebKit/Source/core/paint/PaintLayer.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +4 lines, -12 lines 0 comments Download
M third_party/WebKit/Source/core/paint/PaintLayer.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 13 4 chunks +10 lines, -31 lines 0 comments Download
M third_party/WebKit/Source/core/paint/SVGContainerPainter.cpp View 1 2 3 4 5 6 1 chunk +3 lines, -1 line 0 comments Download
M third_party/WebKit/Source/core/testing/Internals.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 13 2 chunks +2 lines, -2 lines 0 comments Download
M third_party/WebKit/Source/web/LinkHighlightImpl.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +1 line, -1 line 0 comments Download
M third_party/WebKit/Source/web/WebPluginContainerImpl.cpp View 1 chunk +1 line, -1 line 0 comments Download

Messages

Total messages: 37 (12 generated)
Xianzhu
The CL is big but all parts are required to work. Please start review from ...
4 years, 9 months ago (2016-03-22 23:32:42 UTC) #7
pdr.
This patch is too large to review thoroughly. Is it possible to separate the SVG ...
4 years, 9 months ago (2016-03-23 22:50:07 UTC) #9
Xianzhu
I tried to split the CL into multiple parts, but didn't succeed. However, you can ...
4 years, 9 months ago (2016-03-23 23:52:34 UTC) #10
chrishtr
https://codereview.chromium.org/1813383002/diff/220001/third_party/WebKit/Source/core/layout/LayoutObject.cpp File third_party/WebKit/Source/core/layout/LayoutObject.cpp (left): https://codereview.chromium.org/1813383002/diff/220001/third_party/WebKit/Source/core/layout/LayoutObject.cpp#oldcode1372 third_party/WebKit/Source/core/layout/LayoutObject.cpp:1372: return selectionRectForPaintInvalidation(view()); Delete the selectionRectForPaintInvalidation() function? https://codereview.chromium.org/1813383002/diff/220001/third_party/WebKit/Source/core/layout/LayoutObject.cpp File third_party/WebKit/Source/core/layout/LayoutObject.cpp ...
4 years, 9 months ago (2016-03-24 00:53:52 UTC) #11
chrishtr
https://codereview.chromium.org/1813383002/diff/220001/third_party/WebKit/Source/core/layout/LayoutInline.cpp File third_party/WebKit/Source/core/layout/LayoutInline.cpp (left): https://codereview.chromium.org/1813383002/diff/220001/third_party/WebKit/Source/core/layout/LayoutInline.cpp#oldcode1055 third_party/WebKit/Source/core/layout/LayoutInline.cpp:1055: if (style()->visibility() != VISIBLE) Did you lose this optimization? ...
4 years, 9 months ago (2016-03-24 01:05:42 UTC) #12
chrishtr
https://codereview.chromium.org/1813383002/diff/220001/third_party/WebKit/Source/core/layout/LayoutTableCell.cpp File third_party/WebKit/Source/core/layout/LayoutTableCell.cpp (left): https://codereview.chromium.org/1813383002/diff/220001/third_party/WebKit/Source/core/layout/LayoutTableCell.cpp#oldcode368 third_party/WebKit/Source/core/layout/LayoutTableCell.cpp:368: r.setY(r.y()); On 2016/03/24 at 01:05:42, chrishtr wrote: > What ...
4 years, 9 months ago (2016-03-24 16:58:53 UTC) #13
trchen
https://codereview.chromium.org/1813383002/diff/220001/third_party/WebKit/Source/core/layout/LayoutTableCell.cpp File third_party/WebKit/Source/core/layout/LayoutTableCell.cpp (left): https://codereview.chromium.org/1813383002/diff/220001/third_party/WebKit/Source/core/layout/LayoutTableCell.cpp#oldcode368 third_party/WebKit/Source/core/layout/LayoutTableCell.cpp:368: r.setY(r.y()); On 2016/03/24 01:05:42, chrishtr wrote: > What about ...
4 years, 9 months ago (2016-03-25 00:00:45 UTC) #15
pdr.
https://codereview.chromium.org/1813383002/diff/220001/third_party/WebKit/Source/core/layout/PaintInvalidationState.h File third_party/WebKit/Source/core/layout/PaintInvalidationState.h (right): https://codereview.chromium.org/1813383002/diff/220001/third_party/WebKit/Source/core/layout/PaintInvalidationState.h#newcode48 third_party/WebKit/Source/core/layout/PaintInvalidationState.h:48: void updateForChildren(); There's quite a bit of logic to ...
4 years, 9 months ago (2016-03-25 01:08:02 UTC) #16
trchen
https://codereview.chromium.org/1813383002/diff/260001/third_party/WebKit/Source/core/layout/LayoutObject.h File third_party/WebKit/Source/core/layout/LayoutObject.h (right): https://codereview.chromium.org/1813383002/diff/260001/third_party/WebKit/Source/core/layout/LayoutObject.h#newcode101 third_party/WebKit/Source/core/layout/LayoutObject.h:101: DontApplyFrameScrollOffsetAndClip = 1 << 4, Just had an offline ...
4 years, 9 months ago (2016-03-25 01:08:49 UTC) #17
trchen
https://codereview.chromium.org/1813383002/diff/220001/third_party/WebKit/Source/core/layout/PaintInvalidationState.h File third_party/WebKit/Source/core/layout/PaintInvalidationState.h (right): https://codereview.chromium.org/1813383002/diff/220001/third_party/WebKit/Source/core/layout/PaintInvalidationState.h#newcode48 third_party/WebKit/Source/core/layout/PaintInvalidationState.h:48: void updateForChildren(); On 2016/03/25 01:08:01, pdr wrote: > There's ...
4 years, 9 months ago (2016-03-25 01:20:22 UTC) #18
pdr.
https://codereview.chromium.org/1813383002/diff/260001/third_party/WebKit/Source/core/layout/LayoutObject.cpp File third_party/WebKit/Source/core/layout/LayoutObject.cpp (right): https://codereview.chromium.org/1813383002/diff/260001/third_party/WebKit/Source/core/layout/LayoutObject.cpp#newcode1340 third_party/WebKit/Source/core/layout/LayoutObject.cpp:1340: invalidatePaintOfSubtreesIfNeeded(paintInvalidationState); should this be newPaintInvalidationState?
4 years, 9 months ago (2016-03-25 01:51:46 UTC) #19
Xianzhu
https://codereview.chromium.org/1813383002/diff/220001/third_party/WebKit/Source/core/layout/LayoutInline.cpp File third_party/WebKit/Source/core/layout/LayoutInline.cpp (left): https://codereview.chromium.org/1813383002/diff/220001/third_party/WebKit/Source/core/layout/LayoutInline.cpp#oldcode1055 third_party/WebKit/Source/core/layout/LayoutInline.cpp:1055: if (style()->visibility() != VISIBLE) On 2016/03/24 01:05:42, chrishtr wrote: ...
4 years, 9 months ago (2016-03-25 16:35:55 UTC) #20
Xianzhu
I'm separating some simple parts of this CL out into other CLs. Please hold off ...
4 years, 9 months ago (2016-03-25 17:04:48 UTC) #21
pdr.
On 2016/03/25 at 17:04:48, wangxianzhu wrote: > I'm separating some simple parts of this CL ...
4 years, 9 months ago (2016-03-25 18:06:29 UTC) #22
Xianzhu
Done separating out https://codereview.chromium.org/1837533002/ and https://codereview.chromium.org/1829353004/ (landed). Most of the previous comments still apply. Ptal. ...
4 years, 9 months ago (2016-03-25 19:15:21 UTC) #23
pdr.
On 2016/03/25 at 19:15:21, wangxianzhu wrote: > Done separating out https://codereview.chromium.org/1837533002/ and https://codereview.chromium.org/1829353004/ (landed). > ...
4 years, 9 months ago (2016-03-25 20:12:06 UTC) #24
chrishtr
https://codereview.chromium.org/1813383002/diff/300001/third_party/WebKit/Source/core/layout/LayoutView.cpp File third_party/WebKit/Source/core/layout/LayoutView.cpp (right): https://codereview.chromium.org/1813383002/diff/300001/third_party/WebKit/Source/core/layout/LayoutView.cpp#newcode517 third_party/WebKit/Source/core/layout/LayoutView.cpp:517: mode &= ~InputIsInFrameCoordinates here? https://codereview.chromium.org/1813383002/diff/300001/third_party/WebKit/Source/core/layout/svg/LayoutSVGInline.h File third_party/WebKit/Source/core/layout/svg/LayoutSVGInline.h (right): https://codereview.chromium.org/1813383002/diff/300001/third_party/WebKit/Source/core/layout/svg/LayoutSVGInline.h#newcode55 ...
4 years, 9 months ago (2016-03-25 22:18:53 UTC) #25
leviw_travelin_and_unemployed
https://codereview.chromium.org/1813383002/diff/320001/third_party/WebKit/Source/core/layout/PaintInvalidationState.cpp File third_party/WebKit/Source/core/layout/PaintInvalidationState.cpp (right): https://codereview.chromium.org/1813383002/diff/320001/third_party/WebKit/Source/core/layout/PaintInvalidationState.cpp#newcode301 third_party/WebKit/Source/core/layout/PaintInvalidationState.cpp:301: #if !defined(NDEBUG) && ENABLE(ASSERT) Drive-by: isn't ENABLE(ASSERT) enough?
4 years, 9 months ago (2016-03-25 22:26:31 UTC) #27
Xianzhu
https://codereview.chromium.org/1813383002/diff/300001/third_party/WebKit/Source/core/layout/LayoutView.cpp File third_party/WebKit/Source/core/layout/LayoutView.cpp (right): https://codereview.chromium.org/1813383002/diff/300001/third_party/WebKit/Source/core/layout/LayoutView.cpp#newcode517 third_party/WebKit/Source/core/layout/LayoutView.cpp:517: On 2016/03/25 22:18:53, chrishtr wrote: > mode &= ~InputIsInFrameCoordinates ...
4 years, 9 months ago (2016-03-25 22:27:15 UTC) #28
chrishtr
lgtm
4 years, 9 months ago (2016-03-25 23:28:08 UTC) #29
trchen
lgtm too.
4 years, 9 months ago (2016-03-25 23:35:27 UTC) #30
Xianzhu
https://codereview.chromium.org/1813383002/diff/320001/third_party/WebKit/Source/core/layout/PaintInvalidationState.cpp File third_party/WebKit/Source/core/layout/PaintInvalidationState.cpp (right): https://codereview.chromium.org/1813383002/diff/320001/third_party/WebKit/Source/core/layout/PaintInvalidationState.cpp#newcode301 third_party/WebKit/Source/core/layout/PaintInvalidationState.cpp:301: #if !defined(NDEBUG) && ENABLE(ASSERT) On 2016/03/25 22:26:31, leviw wrote: ...
4 years, 9 months ago (2016-03-25 23:44:44 UTC) #31
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1813383002/360001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1813383002/360001
4 years, 9 months ago (2016-03-25 23:52:01 UTC) #34
commit-bot: I haz the power
Committed patchset #17 (id:360001)
4 years, 9 months ago (2016-03-26 01:09:46 UTC) #35
commit-bot: I haz the power
4 years, 9 months ago (2016-03-26 01:11:16 UTC) #37
Message was sent while issue was closed.
Patchset 17 (id:??) landed as
https://crrev.com/934f67a68da2054e526e13648c5452e2cf79c211
Cr-Commit-Position: refs/heads/master@{#383430}

Powered by Google App Engine
This is Rietveld 408576698