Title: [240365] trunk/Source/WebKit
Revision
240365
Author
ryanhad...@apple.com
Date
2019-01-23 16:23:52 -0800 (Wed, 23 Jan 2019)

Log Message

Unreviewed, rolling out r240343.

Caused 4 PSON API test failures.

Reverted changeset:

"[PSON] Flash on back navigation on Mac"
https://bugs.webkit.org/show_bug.cgi?id=193716
https://trac.webkit.org/changeset/240343

Modified Paths

Diff

Modified: trunk/Source/WebKit/ChangeLog (240364 => 240365)


--- trunk/Source/WebKit/ChangeLog	2019-01-24 00:17:15 UTC (rev 240364)
+++ trunk/Source/WebKit/ChangeLog	2019-01-24 00:23:52 UTC (rev 240365)
@@ -1,3 +1,15 @@
+2019-01-23  Ryan Haddad  <ryanhad...@apple.com>
+
+        Unreviewed, rolling out r240343.
+
+        Caused 4 PSON API test failures.
+
+        Reverted changeset:
+
+        "[PSON] Flash on back navigation on Mac"
+        https://bugs.webkit.org/show_bug.cgi?id=193716
+        https://trac.webkit.org/changeset/240343
+
 2019-01-23  Chris Dumez  <cdu...@apple.com>
 
         Deprecate API to limit the maximum number of WebProcesses

Modified: trunk/Source/WebKit/UIProcess/SuspendedPageProxy.cpp (240364 => 240365)


--- trunk/Source/WebKit/UIProcess/SuspendedPageProxy.cpp	2019-01-24 00:17:15 UTC (rev 240364)
+++ trunk/Source/WebKit/UIProcess/SuspendedPageProxy.cpp	2019-01-24 00:23:52 UTC (rev 240365)
@@ -26,7 +26,6 @@
 #include "config.h"
 #include "SuspendedPageProxy.h"
 
-#include "DrawingAreaProxy.h"
 #include "Logging.h"
 #include "WebPageMessages.h"
 #include "WebPageProxy.h"
@@ -155,19 +154,6 @@
 
     m_process->removeMessageReceiver(Messages::WebPageProxy::messageReceiverName(), m_page.pageID());
 
-    bool shouldKeepOnFailure = false;
-#if PLATFORM(MAC)
-    // With web process side tiles, we need to keep the suspended page around on failure to avoid flashing.
-    // It is removed by WebPageProxy::enterAcceleratedCompositingMode when the target page is ready.
-    shouldKeepOnFailure = m_page.drawingArea() && m_page.drawingArea()->type() == DrawingAreaTypeTiledCoreAnimation;
-#endif
-    if (newSuspensionState == SuspensionState::FailedToSuspend && !shouldKeepOnFailure) {
-        RunLoop::main().dispatch([weakProcessPool = makeWeakPtr(m_process->processPool()), weakThis = makeWeakPtr(*this)] {
-            if (weakProcessPool && weakThis)
-                weakProcessPool->removeSuspendedPage(*weakThis);
-        });
-    }
-
     if (m_readyToUnsuspendHandler)
         m_readyToUnsuspendHandler(this);
 }

Modified: trunk/Source/WebKit/UIProcess/WebPageProxy.cpp (240364 => 240365)


--- trunk/Source/WebKit/UIProcess/WebPageProxy.cpp	2019-01-24 00:17:15 UTC (rev 240364)
+++ trunk/Source/WebKit/UIProcess/WebPageProxy.cpp	2019-01-24 00:23:52 UTC (rev 240365)
@@ -6847,12 +6847,7 @@
 
 void WebPageProxy::enterAcceleratedCompositingMode(const LayerTreeContext& layerTreeContext)
 {
-#if PLATFORM(MAC)
-    ASSERT(m_drawingArea->type() == DrawingAreaTypeTiledCoreAnimation);
-#endif
     pageClient().enterAcceleratedCompositingMode(layerTreeContext);
-    // We needed the failed suspended page to stay alive to avoid flashing. Now we can get rid of it.
-    m_process->processPool().removeFailedSuspendedPagesForPage(*this);
 }
 
 void WebPageProxy::exitAcceleratedCompositingMode()

Modified: trunk/Source/WebKit/UIProcess/WebProcessPool.cpp (240364 => 240365)


--- trunk/Source/WebKit/UIProcess/WebProcessPool.cpp	2019-01-24 00:17:15 UTC (rev 240364)
+++ trunk/Source/WebKit/UIProcess/WebProcessPool.cpp	2019-01-24 00:23:52 UTC (rev 240365)
@@ -2262,13 +2262,6 @@
     });
 }
 
-void WebProcessPool::removeFailedSuspendedPagesForPage(WebPageProxy& page)
-{
-    m_suspendedPages.removeAllMatching([&page](auto& suspendedPage) {
-        return &suspendedPage->page() == &page && suspendedPage->failedToSuspend();
-    });
-}
-
 std::unique_ptr<SuspendedPageProxy> WebProcessPool::takeSuspendedPage(SuspendedPageProxy& suspendedPage)
 {
     return m_suspendedPages.takeFirst([&suspendedPage](auto& item) {

Modified: trunk/Source/WebKit/UIProcess/WebProcessPool.h (240364 => 240365)


--- trunk/Source/WebKit/UIProcess/WebProcessPool.h	2019-01-24 00:17:15 UTC (rev 240364)
+++ trunk/Source/WebKit/UIProcess/WebProcessPool.h	2019-01-24 00:23:52 UTC (rev 240365)
@@ -447,7 +447,6 @@
     // SuspendedPageProxy management.
     void addSuspendedPage(std::unique_ptr<SuspendedPageProxy>&&);
     void removeAllSuspendedPagesForPage(WebPageProxy&);
-    void removeFailedSuspendedPagesForPage(WebPageProxy&);
     std::unique_ptr<SuspendedPageProxy> takeSuspendedPage(SuspendedPageProxy&);
     void removeSuspendedPage(SuspendedPageProxy&);
     bool hasSuspendedPageFor(WebProcessProxy&) const;

Modified: trunk/Source/WebKit/WebProcess/WebPage/WebPage.cpp (240364 => 240365)


--- trunk/Source/WebKit/WebProcess/WebPage/WebPage.cpp	2019-01-24 00:17:15 UTC (rev 240364)
+++ trunk/Source/WebKit/WebProcess/WebPage/WebPage.cpp	2019-01-24 00:23:52 UTC (rev 240365)
@@ -1340,6 +1340,7 @@
 void WebPage::suspendForProcessSwap()
 {
     auto failedToSuspend = [this, protectedThis = makeRef(*this)] {
+        close();
         send(Messages::WebPageProxy::DidFailToSuspendAfterProcessSwap());
     };
 
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to