Title: [90246] trunk/Tools
Revision
90246
Author
[email protected]
Date
2011-07-01 11:14:37 -0700 (Fri, 01 Jul 2011)

Log Message

2011-07-01  Adam Barth  <[email protected]>

        Reviewed by Darin Adler.

        ReportCrash destabilizes new-run-webkit-tests
        https://bugs.webkit.org/show_bug.cgi?id=63795

        ReportCrash chews up too many system resources that it destablizes
        tests run concurrently.  This patch causes us to spin down all the
        worker processes when ReportCrash is running.

        Also, this patch causes the master process to tell the user we're
        waiting for the crash reporter rather than having that be the worker's
        job.  This stops the user from getting spammed with too many "waiting
        for crash reporter" messages and also cleans up some minor UI issues
        with the meter.

        * Scripts/webkitpy/layout_tests/layout_package/manager.py:
        * Scripts/webkitpy/layout_tests/layout_package/single_test_runner.py:
        * Scripts/webkitpy/layout_tests/port/base.py:
        * Scripts/webkitpy/layout_tests/port/server_process.py:

Modified Paths

Diff

Modified: trunk/Tools/ChangeLog (90245 => 90246)


--- trunk/Tools/ChangeLog	2011-07-01 17:57:37 UTC (rev 90245)
+++ trunk/Tools/ChangeLog	2011-07-01 18:14:37 UTC (rev 90246)
@@ -1,3 +1,25 @@
+2011-07-01  Adam Barth  <[email protected]>
+
+        Reviewed by Darin Adler.
+
+        ReportCrash destabilizes new-run-webkit-tests
+        https://bugs.webkit.org/show_bug.cgi?id=63795
+
+        ReportCrash chews up too many system resources that it destablizes
+        tests run concurrently.  This patch causes us to spin down all the
+        worker processes when ReportCrash is running.
+
+        Also, this patch causes the master process to tell the user we're
+        waiting for the crash reporter rather than having that be the worker's
+        job.  This stops the user from getting spammed with too many "waiting
+        for crash reporter" messages and also cleans up some minor UI issues
+        with the meter.
+
+        * Scripts/webkitpy/layout_tests/layout_package/manager.py:
+        * Scripts/webkitpy/layout_tests/layout_package/single_test_runner.py:
+        * Scripts/webkitpy/layout_tests/port/base.py:
+        * Scripts/webkitpy/layout_tests/port/server_process.py:
+
 2011-07-01  Adam Roben  <[email protected]>
 
         Teach webkitpy about the new format of our ChangeLog template

Modified: trunk/Tools/Scripts/webkitpy/layout_tests/layout_package/manager.py (90245 => 90246)


--- trunk/Tools/Scripts/webkitpy/layout_tests/layout_package/manager.py	2011-07-01 17:57:37 UTC (rev 90245)
+++ trunk/Tools/Scripts/webkitpy/layout_tests/layout_package/manager.py	2011-07-01 18:14:37 UTC (rev 90246)
@@ -668,7 +668,9 @@
 
         try:
             while not self.is_done():
-                # FIXME: Do we need to run in a loop anymore?
+                if self._port.executive().running_pids(self._port.is_crash_reporter):
+                    self._printer.print_update("Waiting for crash reporter ...")
+                    self._port.executive().wait_newest(self._port.is_crash_reporter)
                 manager_connection.run_message_loop(delay_secs=1.0)
 
             # Make sure all of the workers have shut down (if possible).
@@ -782,9 +784,7 @@
 
         start_time = time.time()
 
-        interrupted, keyboard_interrupted, thread_timings, test_timings, \
-            individual_test_timings = (
-            self._run_tests(self._test_files_list, result_summary))
+        interrupted, keyboard_interrupted, thread_timings, test_timings, individual_test_timings = self._run_tests(self._test_files_list, result_summary)
 
         # We exclude the crashes from the list of results to retry, because
         # we want to treat even a potentially flaky crash as an error.

Modified: trunk/Tools/Scripts/webkitpy/layout_tests/layout_package/single_test_runner.py (90245 => 90246)


--- trunk/Tools/Scripts/webkitpy/layout_tests/layout_package/single_test_runner.py	2011-07-01 17:57:37 UTC (rev 90245)
+++ trunk/Tools/Scripts/webkitpy/layout_tests/layout_package/single_test_runner.py	2011-07-01 18:14:37 UTC (rev 90246)
@@ -125,6 +125,11 @@
         return self._run_compare_test()
 
     def _run_compare_test(self):
+        # Before running the test, we wait for any crash reporters to finish
+        # running. On Mac, ReportCrash chews up a bunch of resources and
+        # causes the tests to become unstable, so we don't want to run in
+        # parallel with ReportCrash.
+        self._port.executive().wait_newest(self._port.is_crash_reporter)
         driver_output = self._driver.run_test(self._driver_input())
         expected_driver_output = self._expected_driver_output()
         test_result = self._compare_output(driver_output, expected_driver_output)

Modified: trunk/Tools/Scripts/webkitpy/layout_tests/port/base.py (90245 => 90246)


--- trunk/Tools/Scripts/webkitpy/layout_tests/port/base.py	2011-07-01 17:57:37 UTC (rev 90245)
+++ trunk/Tools/Scripts/webkitpy/layout_tests/port/base.py	2011-07-01 18:14:37 UTC (rev 90246)
@@ -138,6 +138,9 @@
         self._results_directory = None
         self.set_option_default('use_apache', self._default_to_apache())
 
+    def executive(self):
+        return self._executive
+
     def wdiff_available(self):
         if self._wdiff_available is None:
             self._wdiff_available = self.check_wdiff(logging=False)

Modified: trunk/Tools/Scripts/webkitpy/layout_tests/port/server_process.py (90245 => 90246)


--- trunk/Tools/Scripts/webkitpy/layout_tests/port/server_process.py	2011-07-01 17:57:37 UTC (rev 90245)
+++ trunk/Tools/Scripts/webkitpy/layout_tests/port/server_process.py	2011-07-01 18:14:37 UTC (rev 90246)
@@ -172,7 +172,6 @@
         if sys.platform != "darwin":
             return
         try:
-            self._log('Sampling %s process... (use --no-sample-on-timeout to skip this step)' % self._name)
             hang_report = os.path.join(self._port.results_directory(), "%s-%s.sample.txt" % (self._name, self._proc.pid))
             self._executive.run_command([
                 "/usr/bin/sample",
@@ -197,11 +196,9 @@
 
             now = time.time()
             if now > deadline:
-                if self._executive.running_pids(self._port.is_crash_reporter):
-                    self._log('Waiting for crash reporter...')
-                    self._executive.wait_newest(self._port.is_crash_reporter)
-                    if not self.crashed:
-                        self._check_for_crash()
+                self._executive.wait_newest(self._port.is_crash_reporter)
+                if not self.crashed:
+                    self._check_for_crash()
                 self.timed_out = True
                 if not self.crashed:
                     self._sample()
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes

Reply via email to