Changeset 181813 in webkit


Ignore:
Timestamp:
Mar 20, 2015 2:32:28 PM (9 years ago)
Author:
Simon Fraser
Message:

Log the slow-scrolling reasons (if any) on first commit of a ScrollingTreeFrameScrollingNodeMac
https://bugs.webkit.org/show_bug.cgi?id=142917

Reviewed by Beth Dakin.

The scrollperf test would fail to detect transitions between slow and fast scrolling
for new pages, because there was no logging when slow-scrolling scrolling tree was
torn down, and a new fast-scrolling tree constructed.

Fix by always logging the slow-scrolling reasons in the first update of the
ScrollingTreeFrameScrollingNodeMac, even when the slow-scrolling reasons haven't
changed.

  • page/scrolling/mac/ScrollingTreeFrameScrollingNodeMac.h:
  • page/scrolling/mac/ScrollingTreeFrameScrollingNodeMac.mm:

(WebCore::ScrollingTreeFrameScrollingNodeMac::ScrollingTreeFrameScrollingNodeMac):
(WebCore::ScrollingTreeFrameScrollingNodeMac::updateBeforeChildren):

Location:
trunk/Source/WebCore
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r181810 r181813  
     12015-03-20  Simon Fraser  <simon.fraser@apple.com>
     2
     3        Log the slow-scrolling reasons (if any) on first commit of a ScrollingTreeFrameScrollingNodeMac
     4        https://bugs.webkit.org/show_bug.cgi?id=142917
     5
     6        Reviewed by Beth Dakin.
     7       
     8        The scrollperf test would fail to detect transitions between slow and fast scrolling
     9        for new pages, because there was no logging when slow-scrolling scrolling tree was
     10        torn down, and a new fast-scrolling tree constructed.
     11       
     12        Fix by always logging the slow-scrolling reasons in the first update of the
     13        ScrollingTreeFrameScrollingNodeMac, even when the slow-scrolling reasons haven't
     14        changed.
     15
     16        * page/scrolling/mac/ScrollingTreeFrameScrollingNodeMac.h:
     17        * page/scrolling/mac/ScrollingTreeFrameScrollingNodeMac.mm:
     18        (WebCore::ScrollingTreeFrameScrollingNodeMac::ScrollingTreeFrameScrollingNodeMac):
     19        (WebCore::ScrollingTreeFrameScrollingNodeMac::updateBeforeChildren):
     20
    1212015-03-19  Geoffrey Garen  <ggaren@apple.com>
    222
  • trunk/Source/WebCore/page/scrolling/mac/ScrollingTreeFrameScrollingNodeMac.h

    r181510 r181813  
    101101    FloatPoint m_probableMainThreadScrollPosition;
    102102    bool m_lastScrollHadUnfilledPixels;
     103    bool m_hadFirstUpdate;
    103104};
    104105
  • trunk/Source/WebCore/page/scrolling/mac/ScrollingTreeFrameScrollingNodeMac.mm

    r181510 r181813  
    6262    , m_horizontalScrollbarPainter(0)
    6363    , m_lastScrollHadUnfilledPixels(false)
     64    , m_hadFirstUpdate(false)
    6465{
    6566}
     
    112113    }
    113114
     115    bool logScrollingMode = !m_hadFirstUpdate;
    114116    if (scrollingStateNode.hasChangedProperty(ScrollingStateFrameScrollingNode::ReasonsForSynchronousScrolling)) {
    115117        if (shouldUpdateScrollLayerPositionSynchronously()) {
     
    124126        }
    125127
     128        logScrollingMode = true;
     129    }
     130
     131    if (logScrollingMode) {
    126132        if (scrollingTree().scrollingPerformanceLoggingEnabled())
    127133            logThreadedScrollingMode(synchronousScrollingReasons());
     
    140146        m_scrollController.updateScrollSnapPoints(ScrollEventAxis::Vertical, convertToLayoutUnits(scrollingStateNode.verticalSnapOffsets()));
    141147#endif
     148
     149    m_hadFirstUpdate = true;
    142150}
    143151
Note: See TracChangeset for help on using the changeset viewer.