Bug 1423220 - Enable tab warming by default for Nightly builds. r=dao
authorMike Conley <mconley@mozilla.com>
Wed, 31 Jan 2018 12:10:03 -0500
changeset 408631 beae66d4b661a78c53baa8a5c766975743577a79
parent 408630 8ff03a020b697ba978a0298f9396b38b1f9f069e
child 408632 9d7410af234ceefd27d3694044b709c2d183a59d
push id100996
push userbtara@mozilla.com
push dateSat, 17 Mar 2018 10:37:43 +0000
treeherdermozilla-inbound@97160a734959 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
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 1423220 - Enable tab warming by default for Nightly builds. r=dao MozReview-Commit-ID: 8bz1U1WSzy5
--- a/browser/app/profile/firefox.js
+++ b/browser/app/profile/firefox.js
@@ -1539,18 +1539,22 @@ pref("privacy.userContext.longPressBehav
 pref("privacy.userContext.extension", "");
 // Start the browser in e10s mode
 pref("browser.tabs.remote.autostart", true);
 pref("browser.tabs.remote.desktopbehavior", true);
 // For speculatively warming up tabs to improve perceived
 // performance while using the async tab switcher.
-// Disabled until bug 1397426 is fixed.
+#if defined(NIGHTLY_BUILD)
+pref("browser.tabs.remote.warmup.enabled", true);
 pref("browser.tabs.remote.warmup.enabled", false);
 pref("browser.tabs.remote.warmup.maxTabs", 3);
 pref("browser.tabs.remote.warmup.unloadDelayMs", 2000);
 // For the about:tabcrashed page
 pref("browser.tabs.crashReporting.sendReport", true);
 pref("browser.tabs.crashReporting.includeURL", false);
 pref("browser.tabs.crashReporting.requestEmail", false);
 pref("browser.tabs.crashReporting.emailMe", false);
--- a/dom/base/test/browser_bug1303838.js
+++ b/dom/base/test/browser_bug1303838.js
@@ -11,16 +11,28 @@
  * link click if loadDivertedInBackground is set to true.
 "use strict";
 const BASE_URL = "http://mochi.test:8888/browser/dom/base/test/";
 add_task(async function() {
+  // On Linux, in our test automation, the mouse cursor floats over
+  // the first tab, which causes it to be warmed up when tab warming
+  // is enabled. The TabSwitchDone event doesn't fire until the warmed
+  // tab is evicted, which is after a few seconds. That means that
+  // this test ends up taking longer than we'd like, since its waiting
+  // for the TabSwitchDone event between tab switches.
+  //
+  // So now we make sure that warmed tabs are evicted very shortly
+  // after warming to avoid the test running too long.
+  await SpecialPowers.pushPrefEnv({
+    set: [["browser.tabs.remote.warmup.unloadDelayMs", 50]],
+  });
   await testLinkClick(false, false);
   await testLinkClick(false, true);
   await testLinkClick(true, false);
   await testLinkClick(true, true);
 async function testLinkClick(withFrame, loadDivertedInBackground) {
   await SpecialPowers.pushPrefEnv({"set": [["browser.tabs.loadDivertedInBackground", loadDivertedInBackground]]});