Fix traverseNonCompositingDescendantsInPaintOrder for float-under-inline cases (issue 2639283003 by wangxianzhu@chromium.org)

2 views
Skip to first unread message

wangx...@chromium.org

unread,
Jan 18, 2017, 5:46:49 PM1/18/17
to chri...@chromium.org, trc...@chromium.org, chromium...@chromium.org, blink-...@chromium.org, dongseo...@intel.com, blink-rev...@chromium.org
Reviewers: chrishtr, trchen
CL: https://codereview.chromium.org/2639283003/

Description:
Fix traverseNonCompositingDescendantsInPaintOrder for float-under-inline cases

We should traverse into composited inlines even if they are stacking
context, because there might be floating objects which belong to
ancestors in paint order.

During traverse for paint invalidation, when we encounter a floating
object, we should mark the real painting layer for paint invalidation
which may be above the tip of the subtree being traversed.

BUG=644144
CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:linux_layout_tests_slimming_paint_v2

Affected files (+201, -25 lines):
M third_party/WebKit/Source/core/paint/ObjectPaintInvalidator.cpp
M third_party/WebKit/Source/core/paint/ObjectPaintInvalidatorTest.cpp


wangx...@chromium.org

unread,
Jan 18, 2017, 7:18:14 PM1/18/17
to chri...@chromium.org, trc...@chromium.org, chromium...@chromium.org, blink-...@chromium.org, dongseo...@intel.com, blink-rev...@chromium.org
There are failures in telemetry_perf_unittests. Debugging.

https://codereview.chromium.org/2639283003/

chri...@chromium.org

unread,
Jan 19, 2017, 4:22:27 PM1/19/17
to wangx...@chromium.org, trc...@chromium.org, blink-...@chromium.org, blink-rev...@chromium.org, chromium...@chromium.org, dongseo...@intel.com

https://codereview.chromium.org/2639283003/diff/40001/third_party/WebKit/Source/core/paint/ObjectPaintInvalidator.cpp
File third_party/WebKit/Source/core/paint/ObjectPaintInvalidator.cpp
(right):

https://codereview.chromium.org/2639283003/diff/40001/third_party/WebKit/Source/core/paint/ObjectPaintInvalidator.cpp#newcode80
third_party/WebKit/Source/core/paint/ObjectPaintInvalidator.cpp:80: if
(!object.isLayoutBlockFlow() && descendant->isFloating()) {
&& !isStacked() ? See https://codereview.chromium.org/2640053004

https://codereview.chromium.org/2639283003/diff/40001/third_party/WebKit/Source/core/paint/ObjectPaintInvalidator.cpp#newcode149
third_party/WebKit/Source/core/paint/ObjectPaintInvalidator.cpp:149: }
else if (object.isFloating() && object.parent() &&
Same here: skip isStacked() objects?

https://codereview.chromium.org/2639283003/

wangx...@chromium.org

unread,
Jan 20, 2017, 12:38:12 PM1/20/17
to chri...@chromium.org, trc...@chromium.org, blink-...@chromium.org, blink-rev...@chromium.org, chromium...@chromium.org, dongseo...@intel.com

https://codereview.chromium.org/2639283003/diff/40001/third_party/WebKit/Source/core/paint/ObjectPaintInvalidator.cpp
File third_party/WebKit/Source/core/paint/ObjectPaintInvalidator.cpp
(right):

https://codereview.chromium.org/2639283003/diff/40001/third_party/WebKit/Source/core/paint/ObjectPaintInvalidator.cpp#newcode80
third_party/WebKit/Source/core/paint/ObjectPaintInvalidator.cpp:80: if
(!object.isLayoutBlockFlow() && descendant->isFloating()) {
On 2017/01/19 21:22:26, chrishtr wrote:
> && !isStacked() ? See https://codereview.chromium.org/2640053004

Yes. Moved the case under the condition at new line 86.


https://codereview.chromium.org/2639283003/diff/40001/third_party/WebKit/Source/core/paint/ObjectPaintInvalidator.cpp#newcode149
third_party/WebKit/Source/core/paint/ObjectPaintInvalidator.cpp:149: }
else if (object.isFloating() && object.parent() &&
On 2017/01/19 21:22:26, chrishtr wrote:
> Same here: skip isStacked() objects?

chri...@chromium.org

unread,
Jan 20, 2017, 11:01:04 PM1/20/17
to wangx...@chromium.org, trc...@chromium.org, blink-...@chromium.org, blink-rev...@chromium.org, chromium...@chromium.org, dongseo...@intel.com
lgtm




https://codereview.chromium.org/2639283003/diff/80001/third_party/WebKit/Source/core/paint/ObjectPaintInvalidator.cpp
File third_party/WebKit/Source/core/paint/ObjectPaintInvalidator.cpp
(right):

https://codereview.chromium.org/2639283003/diff/80001/third_party/WebKit/Source/core/paint/ObjectPaintInvalidator.cpp#newcode72
third_party/WebKit/Source/core/paint/ObjectPaintInvalidator.cpp:72: //
descendants may not belong to |object| but belong to an ancestor. This
Add an example of why non-block-flow elements might have this problem.

https://codereview.chromium.org/2639283003/

wangx...@chromium.org

unread,
Jan 24, 2017, 1:38:39 AM1/24/17
to chri...@chromium.org, trc...@chromium.org, blink-...@chromium.org, blink-rev...@chromium.org, chromium...@chromium.org, dongseo...@intel.com

https://codereview.chromium.org/2639283003/diff/80001/third_party/WebKit/Source/core/paint/ObjectPaintInvalidator.cpp
File third_party/WebKit/Source/core/paint/ObjectPaintInvalidator.cpp
(right):

https://codereview.chromium.org/2639283003/diff/80001/third_party/WebKit/Source/core/paint/ObjectPaintInvalidator.cpp#newcode72
third_party/WebKit/Source/core/paint/ObjectPaintInvalidator.cpp:72: //
descendants may not belong to |object| but belong to an ancestor. This
On 2017/01/21 04:01:04, chrishtr wrote:
> Add an example of why non-block-flow elements might have this problem.

commit-bot@chromium.org via codereview.chromium.org

unread,
Jan 24, 2017, 1:40:28 AM1/24/17
to wangx...@chromium.org, chri...@chromium.org, trc...@chromium.org, commi...@chromium.org, blink-...@chromium.org, blink-rev...@chromium.org, chromium...@chromium.org, dongseo...@intel.com

commit-bot@chromium.org via codereview.chromium.org

unread,
Jan 24, 2017, 3:16:17 AM1/24/17
to wangx...@chromium.org, chri...@chromium.org, trc...@chromium.org, commi...@chromium.org, blink-...@chromium.org, blink-rev...@chromium.org, chromium...@chromium.org, dongseo...@intel.com
Reply all
Reply to author
Forward
0 new messages