Title: [189186] trunk/Tools
Revision
189186
Author
[email protected]
Date
2015-08-31 15:01:44 -0700 (Mon, 31 Aug 2015)

Log Message

Skip slow lock tests on Windows/debug
https://bugs.webkit.org/show_bug.cgi?id=148643

Reviewed by Alexey Proskuryakov.

The lock tests simulate a critical section by doing some floating point math, and then either
make those critical sections very long or invoke them many times. This appears to be
particularly slow on Windows in debug mode, maybe because Visual Studio's debug build makes
that kind of computation slow.

These tests are almost as useful in release as they are in debug, so it's probably better to
just skip the in debug on platforms where this causes timeouts.

* TestWebKitAPI/Tests/WTF/Lock.cpp:
(TestWebKitAPI::runLockTest):
(TestWebKitAPI::skipSlow):
(TestWebKitAPI::TEST):

Modified Paths

Diff

Modified: trunk/Tools/ChangeLog (189185 => 189186)


--- trunk/Tools/ChangeLog	2015-08-31 21:38:43 UTC (rev 189185)
+++ trunk/Tools/ChangeLog	2015-08-31 22:01:44 UTC (rev 189186)
@@ -1,3 +1,23 @@
+2015-08-31  Filip Pizlo  <[email protected]>
+
+        Skip slow lock tests on Windows/debug
+        https://bugs.webkit.org/show_bug.cgi?id=148643
+
+        Reviewed by Alexey Proskuryakov.
+
+        The lock tests simulate a critical section by doing some floating point math, and then either
+        make those critical sections very long or invoke them many times. This appears to be
+        particularly slow on Windows in debug mode, maybe because Visual Studio's debug build makes
+        that kind of computation slow.
+
+        These tests are almost as useful in release as they are in debug, so it's probably better to
+        just skip the in debug on platforms where this causes timeouts.
+
+        * TestWebKitAPI/Tests/WTF/Lock.cpp:
+        (TestWebKitAPI::runLockTest):
+        (TestWebKitAPI::skipSlow):
+        (TestWebKitAPI::TEST):
+
 2015-08-29  Chris Fleizach  <[email protected]>
 
         AX: When navigating the elements of a scrollable element with VoiceOver, the scrollTop() position of the element does not permanently change

Modified: trunk/Tools/TestWebKitAPI/Tests/WTF/Lock.cpp (189185 => 189186)


--- trunk/Tools/TestWebKitAPI/Tests/WTF/Lock.cpp	2015-08-31 21:38:43 UTC (rev 189185)
+++ trunk/Tools/TestWebKitAPI/Tests/WTF/Lock.cpp	2015-08-31 22:01:44 UTC (rev 189186)
@@ -87,6 +87,15 @@
     }
 }
 
+bool skipSlow()
+{
+#if PLATFORM(WIN) && !defined(NDEBUG)
+    return true;
+#else
+    return false;
+#endif
+}
+
 TEST(WTF_WordLock, UncontendedShortSection)
 {
     runLockTest<WordLock>(1, 1, 1, 10000000);
@@ -99,21 +108,29 @@
 
 TEST(WTF_WordLock, ContendedShortSection)
 {
+    if (skipSlow())
+        return;
     runLockTest<WordLock>(1, 10, 1, 5000000);
 }
 
 TEST(WTF_WordLock, ContendedLongSection)
 {
+    if (skipSlow())
+        return;
     runLockTest<WordLock>(1, 10, 10000, 10000);
 }
 
 TEST(WTF_WordLock, ManyContendedShortSections)
 {
+    if (skipSlow())
+        return;
     runLockTest<WordLock>(10, 10, 1, 500000);
 }
 
 TEST(WTF_WordLock, ManyContendedLongSections)
 {
+    if (skipSlow())
+        return;
     runLockTest<WordLock>(10, 10, 10000, 500);
 }
 
@@ -129,31 +146,43 @@
 
 TEST(WTF_Lock, ContendedShortSection)
 {
+    if (skipSlow())
+        return;
     runLockTest<Lock>(1, 10, 1, 10000000);
 }
 
 TEST(WTF_Lock, ContendedLongSection)
 {
+    if (skipSlow())
+        return;
     runLockTest<Lock>(1, 10, 10000, 10000);
 }
 
 TEST(WTF_Lock, ManyContendedShortSections)
 {
+    if (skipSlow())
+        return;
     runLockTest<Lock>(10, 10, 1, 500000);
 }
 
 TEST(WTF_Lock, ManyContendedLongSections)
 {
+    if (skipSlow())
+        return;
     runLockTest<Lock>(10, 10, 10000, 1000);
 }
 
 TEST(WTF_Lock, ManyContendedLongerSections)
 {
+    if (skipSlow())
+        return;
     runLockTest<Lock>(10, 10, 100000, 1);
 }
 
 TEST(WTF_Lock, SectionAddressCollision)
 {
+    if (skipSlow())
+        return;
     runLockTest<Lock>(4, 2, 10000, 2000);
 }
 
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to