Title: [183299] trunk/Source/WebKit2
- Revision
- 183299
- Author
- [email protected]
- Date
- 2015-04-24 17:25:39 -0700 (Fri, 24 Apr 2015)
Log Message
theverge.com burning 100% CPU on iPad (due to window.screenX/Y)
<https://webkit.org/b/144175>
<rdar://problem/20694585>
Reviewed by Anders Carlsson.
Return an empty window rect on iOS WK2 builds. This avoids sending a synchronous
IPC request to the UI process that would give the same result, but spend way
more time and CPU cycles to do so.
With this change, theverge.com CPU usage goes from 100% to ~20% when idle.
* WebProcess/WebCoreSupport/WebChromeClient.cpp:
(WebKit::WebChromeClient::windowRect):
Modified Paths
Diff
Modified: trunk/Source/WebKit2/ChangeLog (183298 => 183299)
--- trunk/Source/WebKit2/ChangeLog 2015-04-25 00:19:32 UTC (rev 183298)
+++ trunk/Source/WebKit2/ChangeLog 2015-04-25 00:25:39 UTC (rev 183299)
@@ -1,3 +1,20 @@
+2015-04-24 Andreas Kling <[email protected]>
+
+ theverge.com burning 100% CPU on iPad (due to window.screenX/Y)
+ <https://webkit.org/b/144175>
+ <rdar://problem/20694585>
+
+ Reviewed by Anders Carlsson.
+
+ Return an empty window rect on iOS WK2 builds. This avoids sending a synchronous
+ IPC request to the UI process that would give the same result, but spend way
+ more time and CPU cycles to do so.
+
+ With this change, theverge.com CPU usage goes from 100% to ~20% when idle.
+
+ * WebProcess/WebCoreSupport/WebChromeClient.cpp:
+ (WebKit::WebChromeClient::windowRect):
+
2015-04-24 Brent Fulgham <[email protected]>
TextIndicator for embedded PDFs is slightly offset
Modified: trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebChromeClient.cpp (183298 => 183299)
--- trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebChromeClient.cpp 2015-04-25 00:19:32 UTC (rev 183298)
+++ trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebChromeClient.cpp 2015-04-25 00:25:39 UTC (rev 183299)
@@ -129,7 +129,10 @@
FloatRect WebChromeClient::windowRect()
{
-#if PLATFORM(COCOA)
+#if PLATFORM(IOS)
+ return FloatRect();
+#else
+#if PLATFORM(MAC)
if (m_page->hasCachedWindowFrame())
return m_page->windowFrameInUnflippedScreenCoordinates();
#endif
@@ -140,6 +143,7 @@
return FloatRect();
return newWindowFrame;
+#endif
}
FloatRect WebChromeClient::pageRect()
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes