Bug 139468 - Continuously repainting large parts of Huffington Post.
Summary: Continuously repainting large parts of Huffington Post.
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Layout and Rendering (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: zalan
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2014-12-09 19:14 PST by zalan
Modified: 2014-12-10 20:41 PST (History)
9 users (show)

See Also:


Attachments
Patch (12.85 KB, patch)
2014-12-09 20:35 PST, zalan
no flags Details | Formatted Diff | Diff
Patch (12.67 KB, patch)
2014-12-10 14:39 PST, zalan
zalan: commit-queue-
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description zalan 2014-12-09 19:14:25 PST
1. Turn on "show tiled scrolling indicator"
2. Go to http://www.huffingtonpost.com
3. Notice that we continuously repaint content out of view.
Comment 1 zalan 2014-12-09 20:35:11 PST
Created attachment 242986 [details]
Patch
Comment 2 zalan 2014-12-09 20:49:39 PST
Comment on attachment 242986 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=242986&action=review

> LayoutTests/platform/mac/fast/line-grid/line-align-right-edges-expected.txt:25
> -    RenderText {#text} at (170,3) size 120x24
> -      text run at (170,3) width 120: "X X X"
> +    RenderText {#text} at (161,3) size 120x24
> +      text run at (161,3) width 120: "X X X"

Dave, this is the line-grid issue that I mentioned. Apparently the relative value of the left position for a line inside a grid depends on the position of the parent. Normally (simple case) if a box is at (10px,10px) relative to its parent, when the parent moves the child box still has the (10px, 10px) relative position (layout time). However, in RenderBlock::adjustLogicalLeftOffsetForLine() we use the current layoutOffset when figuring out the left value for a line (grid line case only). It produces different output now that we "skip" a layout for that line (renders the same when loading it to Safari). Do you know what we are supposed to do here?
Comment 3 Antti Koivisto 2014-12-10 07:05:55 PST
Comment on attachment 242986 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=242986&action=review

> Source/WebCore/rendering/RenderBlockFlow.cpp:3497
> -    ASSERT(!m_lineBoxes.firstLineBox());
> +    bool needsLayout = selfNeedsLayout() || relayoutChildren || !m_simpleLineLayout;
> +    if (needsLayout) {
> +        deleteLineBoxesBeforeSimpleLineLayout();
> +        ASSERT(!m_lineBoxes.firstLineBox());
>  
> -    m_simpleLineLayout = SimpleLineLayout::create(*this);
> +        m_simpleLineLayout = SimpleLineLayout::create(*this);
> +    } else {
> +        // Any property change that triggers line layout mode switching should also dirty the box.
> +        ASSERT(!m_lineBoxes.firstLineBox());
> +    }

You should just have one assert below the if() covering all cases.
Comment 4 zalan 2014-12-10 14:39:42 PST
Created attachment 243067 [details]
Patch
Comment 5 zalan 2014-12-10 19:28:52 PST
Committed r177128: <http://trac.webkit.org/changeset/177128>
Comment 6 zalan 2014-12-10 20:41:33 PST
rdar://problem/17261934