Bug 1382889 - Part 2: Add a checkpoint between closing tabs and clearing the preloaded process. r=bc
authorEric Rahm <erahm@mozilla.com>
Wed, 26 Jul 2017 12:07:17 -0700
changeset 422443 484096481587c8c66e27a4d834ec62f596ae55f3
parent 422442 92d9a593abdad1174fe96840233ebd6bca1bc1e7
child 422444 c6bc36c3b43c05b1f50f454a04b563a2cc6c1569
push id1517
push userjlorenzo@mozilla.com
push dateThu, 14 Sep 2017 16:50:54 +0000
treeherdermozilla-release@3b41fd564418 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbc
bugs1382889
milestone56.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1382889 - Part 2: Add a checkpoint between closing tabs and clearing the preloaded process. r=bc This adds an additional measurement before we clear the preloaded process. It will allow us to track future regressions within the preloaded process. MozReview-Commit-ID: Bza7VscEqH3
testing/awsy/awsy/process_perf_data.py
testing/awsy/awsy/test_memory_usage.py
--- a/testing/awsy/awsy/process_perf_data.py
+++ b/testing/awsy/awsy/process_perf_data.py
@@ -12,16 +12,17 @@ import parse_about_memory
 
 # A description of each checkpoint and the root path to it.
 CHECKPOINTS = [
     { 'name': "Fresh start", 'path': "memory-report-Start-0.json.gz" },
     { 'name': "Fresh start [+30s]", 'path': "memory-report-StartSettled-0.json.gz" },
     { 'name': "After tabs open", 'path': "memory-report-TabsOpen-4.json.gz" },
     { 'name': "After tabs open [+30s]", 'path': "memory-report-TabsOpenSettled-4.json.gz" },
     { 'name': "After tabs open [+30s, forced GC]", 'path': "memory-report-TabsOpenForceGC-4.json.gz" },
+    { 'name': "Tabs closed extra processes", 'path': "memory-report-TabsClosedExtraProcesses-4.json.gz" },
     { 'name': "Tabs closed", 'path': "memory-report-TabsClosed-4.json.gz" },
     { 'name': "Tabs closed [+30s]", 'path': "memory-report-TabsClosedSettled-4.json.gz" },
     { 'name': "Tabs closed [+30s, forced GC]", 'path': "memory-report-TabsClosedForceGC-4.json.gz" }
 ]
 
 # A description of each perfherder suite and the path to its values.
 PERF_SUITES = [
     { 'name': "Resident Memory", 'node': "resident" },
@@ -36,16 +37,17 @@ def update_checkpoint_paths(checkpoint_f
     Updates CHECKPOINTS with memory report file fetched in data_path
     :param checkpoint_files: list of files in data_path
     """
     target_path = [['Start-', 0],
                       ['StartSettled-', 0],
                       ['TabsOpen-', -1],
                       ['TabsOpenSettled-', -1],
                       ['TabsOpenForceGC-', -1],
+                      ['TabsClosedExtraProcesses-', -1],
                       ['TabsClosed-', -1],
                       ['TabsClosedSettled-', -1],
                       ['TabsClosedForceGC-', -1]]
     for i in range(len(target_path)):
         (name, idx) = target_path[i]
         paths = sorted([x for x in checkpoint_files if name in x])
         CHECKPOINTS[i]['path'] = paths[idx]
 
--- a/testing/awsy/awsy/test_memory_usage.py
+++ b/testing/awsy/awsy/test_memory_usage.py
@@ -365,16 +365,20 @@ class TestMemoryUsage(MarionetteTestCase
             self.marionette.switch_to_window(self._tabs[0])
             self.logger.info("switched to first window")
             with self.marionette.using_context('content'):
                 self.logger.info("navigating to about:blank")
                 self.marionette.navigate("about:blank")
                 self.logger.info("navigated to about:blank")
             self.signal_user_active()
 
+            # Create checkpoint that may contain retained processes that will
+            # be reused.
+            create_checkpoint("TabsClosedExtraProcesses", itr)
+
             # Clear out the retained processes and measure again.
             self.clear_preloaded_browser()
 
             create_checkpoint("TabsClosed", itr)
             time.sleep(self._settleWaitTime)
             create_checkpoint("TabsClosedSettled", itr)
             self.assertTrue(self.do_full_gc(), "GC ran")
             create_checkpoint("TabsClosedForceGC", itr)