Remove rAf suspension logging
authorgraouts@webkit.org <graouts@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 25 Jun 2017 09:22:06 +0000 (09:22 +0000)
committergraouts@webkit.org <graouts@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 25 Jun 2017 09:22:06 +0000 (09:22 +0000)
https://bugs.webkit.org/show_bug.cgi?id=173821

Reviewed by Tim Horton.

Now that webkit.org/b/173628 is fixed, we can remove the logging code we added.

* dom/Document.cpp:
(WebCore::Document::requestAnimationFrame):
* dom/ScriptedAnimationController.cpp:
(WebCore::ScriptedAnimationController::suspend):
(WebCore::ScriptedAnimationController::resume):
* page/Page.cpp:
(WebCore::Page::suspendScriptedAnimations):
(WebCore::Page::resumeScriptedAnimations):
(WebCore::Page::setIsVisibleInternal):
* platform/RuntimeApplicationChecks.h:
* platform/cocoa/RuntimeApplicationChecksCocoa.mm:
(WebCore::MacApplication::isDumpRenderTree): Deleted.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@218792 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Source/WebCore/ChangeLog
Source/WebCore/dom/Document.cpp
Source/WebCore/dom/ScriptedAnimationController.cpp
Source/WebCore/page/Page.cpp
Source/WebCore/platform/RuntimeApplicationChecks.h
Source/WebCore/platform/cocoa/RuntimeApplicationChecksCocoa.mm

index 0b91665..c1c9efb 100644 (file)
@@ -1,3 +1,25 @@
+2017-06-25  Antoine Quint  <graouts@apple.com>
+
+        Remove rAf suspension logging
+        https://bugs.webkit.org/show_bug.cgi?id=173821
+
+        Reviewed by Tim Horton.
+
+        Now that webkit.org/b/173628 is fixed, we can remove the logging code we added.
+
+        * dom/Document.cpp:
+        (WebCore::Document::requestAnimationFrame):
+        * dom/ScriptedAnimationController.cpp:
+        (WebCore::ScriptedAnimationController::suspend):
+        (WebCore::ScriptedAnimationController::resume):
+        * page/Page.cpp:
+        (WebCore::Page::suspendScriptedAnimations):
+        (WebCore::Page::resumeScriptedAnimations):
+        (WebCore::Page::setIsVisibleInternal):
+        * platform/RuntimeApplicationChecks.h:
+        * platform/cocoa/RuntimeApplicationChecksCocoa.mm:
+        (WebCore::MacApplication::isDumpRenderTree): Deleted.
+
 2017-06-24  Sam Weinig  <sam@webkit.org>
 
         [WebIDL] Add complete support for stringifier
index 4886bf6..c4baada 100644 (file)
 #include "RenderView.h"
 #include "RenderWidget.h"
 #include "RequestAnimationFrameCallback.h"
-#include "RuntimeApplicationChecks.h"
 #include "RuntimeEnabledFeatures.h"
 #include "SVGDocumentExtensions.h"
 #include "SVGElement.h"
@@ -6237,15 +6236,6 @@ int Document::requestAnimationFrame(Ref<RequestAnimationFrameCallback>&& callbac
         // It's possible that the Page may have suspended scripted animations before
         // we were created. We need to make sure that we don't start up the animation
         // controller on a background tab, for example.
-
-#if PLATFORM(MAC)
-        if (MacApplication::isDumpRenderTree()) {
-            WTFLogAlways("\nDocument::requestAnimationFrame called on %p, page = %p", this, page());
-            if (page())
-                WTFLogAlways("page()->scriptedAnimationsSuspended() = %s", page()->scriptedAnimationsSuspended() ? "true" : "false");
-        }
-#endif
-
         if (!page() || page()->scriptedAnimationsSuspended())
             m_scriptedAnimationController->suspend();
 
index ce854cd..7de2639 100644 (file)
@@ -39,7 +39,6 @@
 #include "MainFrame.h"
 #include "Page.h"
 #include "RequestAnimationFrameCallback.h"
-#include "RuntimeApplicationChecks.h"
 #include "Settings.h"
 #include <algorithm>
 #include <wtf/CurrentTime.h>
@@ -76,13 +75,6 @@ bool ScriptedAnimationController::requestAnimationFrameEnabled() const
 void ScriptedAnimationController::suspend()
 {
     ++m_suspendCount;
-
-#if PLATFORM(MAC)
-    if (MacApplication::isDumpRenderTree()) {
-        WTFLogAlways("\nScriptedAnimationController::suspend() called on %p, m_suspendCount = %d, document = %p", this, m_suspendCount, &m_document);
-        WTFReportBacktrace();
-    }
-#endif
 }
 
 void ScriptedAnimationController::resume()
@@ -92,14 +84,6 @@ void ScriptedAnimationController::resume()
     if (m_suspendCount > 0)
         --m_suspendCount;
 
-#if PLATFORM(MAC)
-    if (MacApplication::isDumpRenderTree()) {
-        WTFLogAlways("\nScriptedAnimationController::resume() called on %p, m_suspendCount = %d, document = %p", this, m_suspendCount, &m_document);
-        WTFLogAlways("Document = %p", &m_document);
-        WTFReportBacktrace();
-    }
-#endif
-
     if (!m_suspendCount && m_callbacks.size())
         scheduleAnimation();
 }
index fac2bc6..cd06a0e 100644 (file)
@@ -85,7 +85,6 @@
 #include "RenderView.h"
 #include "RenderWidget.h"
 #include "ResourceUsageOverlay.h"
-#include "RuntimeApplicationChecks.h"
 #include "RuntimeEnabledFeatures.h"
 #include "SVGDocumentExtensions.h"
 #include "SchemeRegistry.h"
@@ -1150,13 +1149,6 @@ void Page::removeActivityStateChangeObserver(ActivityStateChangeObserver& observ
 
 void Page::suspendScriptedAnimations()
 {
-#if PLATFORM(MAC)
-    if (MacApplication::isDumpRenderTree()) {
-        WTFLogAlways("\nPage::suspendScriptedAnimations() %p", this);
-        WTFReportBacktrace();
-    }
-#endif
-
     m_scriptedAnimationsSuspended = true;
     for (Frame* frame = &mainFrame(); frame; frame = frame->tree().traverseNext()) {
         if (frame->document())
@@ -1166,13 +1158,6 @@ void Page::suspendScriptedAnimations()
 
 void Page::resumeScriptedAnimations()
 {
-#if PLATFORM(MAC)
-    if (MacApplication::isDumpRenderTree()) {
-        WTFLogAlways("\nPage::resumeScriptedAnimations() %p", this);
-        WTFReportBacktrace();
-    }
-#endif
-
     m_scriptedAnimationsSuspended = false;
     for (Frame* frame = &mainFrame(); frame; frame = frame->tree().traverseNext()) {
         if (frame->document())
@@ -1689,10 +1674,6 @@ void Page::setIsVisibleInternal(bool isVisible)
     if (isVisible) {
         m_isPrerender = false;
 
-#if PLATFORM(MAC)
-        if (MacApplication::isDumpRenderTree())
-            WTFLogAlways("\nPage::setIsVisibleInternal(%s), %p", isVisible ? "true" : "false", this);
-#endif
         resumeScriptedAnimations();
 #if PLATFORM(IOS)
         resumeDeviceMotionAndOrientationUpdates();
@@ -1724,10 +1705,6 @@ void Page::setIsVisibleInternal(bool isVisible)
         suspendDeviceMotionAndOrientationUpdates();
 #endif
 
-#if PLATFORM(MAC)
-        if (MacApplication::isDumpRenderTree())
-            WTFLogAlways("\nPage::setIsVisibleInternal(%s), %p", isVisible ? "true" : "false", this);
-#endif
         suspendScriptedAnimations();
 
         if (FrameView* view = mainFrame().view())
index 19780a6..ab88e67 100644 (file)
@@ -45,7 +45,6 @@ WEBCORE_EXPORT bool isAOLInstantMessenger();
 WEBCORE_EXPORT bool isAdobeInstaller();
 WEBCORE_EXPORT bool isAperture();
 WEBCORE_EXPORT bool isAppleMail();
-bool isDumpRenderTree();
 WEBCORE_EXPORT bool isIBooks();
 WEBCORE_EXPORT bool isITunes();
 WEBCORE_EXPORT bool isMicrosoftMessenger();
index a8d2202..d2e28b7 100644 (file)
@@ -162,11 +162,6 @@ bool MacApplication::isSolidStateNetworksDownloader()
     return isSolidStateNetworksDownloader;
 }
 
-bool MacApplication::isDumpRenderTree()
-{
-    return [[[NSProcessInfo processInfo] processName] isEqualToString:@"DumpRenderTree"];
-}
-
 #endif // PLATFORM(MAC)
 
 #if PLATFORM(IOS)