Title: [210212] trunk/Source/WebCore
Revision
210212
Author
[email protected]
Date
2016-12-30 06:00:07 -0800 (Fri, 30 Dec 2016)

Log Message

Unreviewed, rolling out r210206.
https://bugs.webkit.org/show_bug.cgi?id=166621

Crashes on macOS PLT (Requested by kling on #webkit).

Reverted changeset:

"Drop the render tree for documents in the page cache."
https://bugs.webkit.org/show_bug.cgi?id=121798
http://trac.webkit.org/changeset/210206

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (210211 => 210212)


--- trunk/Source/WebCore/ChangeLog	2016-12-30 10:53:58 UTC (rev 210211)
+++ trunk/Source/WebCore/ChangeLog	2016-12-30 14:00:07 UTC (rev 210212)
@@ -1,3 +1,16 @@
+2016-12-30  Commit Queue  <[email protected]>
+
+        Unreviewed, rolling out r210206.
+        https://bugs.webkit.org/show_bug.cgi?id=166621
+
+        Crashes on macOS PLT (Requested by kling on #webkit).
+
+        Reverted changeset:
+
+        "Drop the render tree for documents in the page cache."
+        https://bugs.webkit.org/show_bug.cgi?id=121798
+        http://trac.webkit.org/changeset/210206
+
 2016-12-28  Sergio Villar Senin  <[email protected]>
 
         [css-grid] Isolate instrinsic size computation from layout

Modified: trunk/Source/WebCore/dom/Document.cpp (210211 => 210212)


--- trunk/Source/WebCore/dom/Document.cpp	2016-12-30 10:53:58 UTC (rev 210211)
+++ trunk/Source/WebCore/dom/Document.cpp	2016-12-30 14:00:07 UTC (rev 210212)
@@ -2221,6 +2221,7 @@
 void Document::destroyRenderTree()
 {
     ASSERT(hasLivingRenderTree());
+    ASSERT(m_pageCacheState != InPageCache);
 
     SetForScope<bool> change(m_renderTreeBeingDestroyed, true);
 
@@ -4523,13 +4524,6 @@
     if (m_pageCacheState == state)
         return;
 
-    if (state == InPageCache) {
-        // When entering page cache, tear down the render tree before setting the in-cache flag.
-        // This maintains the invariant that render trees are never present in the page cache.
-        if (hasLivingRenderTree())
-            destroyRenderTree();
-    }
-
     m_pageCacheState = state;
 
     FrameView* v = view();

Modified: trunk/Source/WebCore/history/CachedFrame.cpp (210211 => 210212)


--- trunk/Source/WebCore/history/CachedFrame.cpp	2016-12-30 10:53:58 UTC (rev 210211)
+++ trunk/Source/WebCore/history/CachedFrame.cpp	2016-12-30 14:00:07 UTC (rev 210212)
@@ -130,7 +130,6 @@
         m_document->page()->chrome().client().needTouchEvents(true);
 #endif
 
-    frame.view()->didRestoreFromPageCache();
 }
 
 CachedFrame::CachedFrame(Frame& frame)

Modified: trunk/Source/WebCore/page/FrameView.cpp (210211 => 210212)


--- trunk/Source/WebCore/page/FrameView.cpp	2016-12-30 10:53:58 UTC (rev 210211)
+++ trunk/Source/WebCore/page/FrameView.cpp	2016-12-30 14:00:07 UTC (rev 210212)
@@ -636,13 +636,6 @@
     return ScrollView::createScrollbar(orientation);
 }
 
-void FrameView::didRestoreFromPageCache()
-{
-    // When restoring from page cache, the main frame stays in place while subframes get swapped in.
-    // We update the scrollable area set to ensure that scrolling data structures get invalidated.
-    updateScrollableAreaSet();
-}
-
 void FrameView::setContentsSize(const IntSize& size)
 {
     if (size == contentsSize())

Modified: trunk/Source/WebCore/page/FrameView.h (210211 => 210212)


--- trunk/Source/WebCore/page/FrameView.h	2016-12-30 10:53:58 UTC (rev 210211)
+++ trunk/Source/WebCore/page/FrameView.h	2016-12-30 14:00:07 UTC (rev 210212)
@@ -587,8 +587,6 @@
 
     bool shouldPlaceBlockDirectionScrollbarOnLeft() const final;
 
-    void didRestoreFromPageCache();
-
 protected:
     bool scrollContentsFastPath(const IntSize& scrollDelta, const IntRect& rectToScroll, const IntRect& clipRect) override;
     void scrollContentsSlowPath(const IntRect& updateRect) override;

Modified: trunk/Source/WebCore/page/animation/AnimationBase.cpp (210211 => 210212)


--- trunk/Source/WebCore/page/animation/AnimationBase.cpp	2016-12-30 10:53:58 UTC (rev 210211)
+++ trunk/Source/WebCore/page/animation/AnimationBase.cpp	2016-12-30 14:00:07 UTC (rev 210212)
@@ -89,11 +89,9 @@
 
 void AnimationBase::setNeedsStyleRecalc(Element* element)
 {
-    if (!element || element->document().renderTreeBeingDestroyed())
-        return;
-
-    ASSERT(element->document().pageCacheState() == Document::NotInPageCache);
-    element->invalidateStyleAndLayerComposition();
+    ASSERT(!element || element->document().pageCacheState() == Document::NotInPageCache);
+    if (element)
+        element->invalidateStyleAndLayerComposition();
 }
 
 double AnimationBase::duration() const
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to