Bug 1384459 - Only enable WebVR device enumeration for 64-bit builds
We wish to enable WebVR only for 64-bit builds before it rides the
trains with 55 in release.
This will serve a few purposes:
- Reduction of test requirements by reduction of configuration matrices.
- Ensuring that the optimal 64-bit builds are used for WebVR sites,
which are often likely to hit 32-bit address space fragmentation
limitations resulting in OOMs.
- Act as a rudimentary soft-launch in 55. 56 is expected to bring a
larger set of users to 64-bit builds.
MozReview-Commit-ID: 207ABcd31dP
--- a/modules/libpref/init/all.js
+++ b/modules/libpref/init/all.js
@@ -5231,17 +5231,22 @@ pref("dom.vr.autoactivate.enabled", fals
pref("dom.vr.controller_trigger_threshold", "0.1");
// Maximum number of milliseconds the browser will wait for content to call
// VRDisplay.requestPresent after emitting vrdisplayactivate during VR
// link traversal. This prevents a long running event handler for
// vrdisplayactivate from later calling VRDisplay.requestPresent, which would
// result in a non-responsive browser in the VR headset.
pref("dom.vr.navigation.timeout", 5000);
// Oculus device
+#if defined(HAVE_64BIT_BUILD)
+// We are only enabling WebVR by default on 64-bit builds (Bug 1384459)
pref("dom.vr.oculus.enabled", true);
+#else
+pref("dom.vr.oculus.enabled", false);
+#endif
// Minimum number of milliseconds after content has stopped VR presentation
// before the Oculus session is re-initialized to an invisible / tracking
// only mode. If this value is too high, users will need to wait longer
// after stopping WebVR presentation before automatically returning to the
// Oculus home interface. (They can immediately return to the Oculus Home
// interface through the Oculus HUD without waiting this duration)
// If this value is too low, the Oculus Home interface may be visible
// momentarily during VR link navigation.
@@ -5251,17 +5256,18 @@ pref("dom.vr.oculus.present.timeout", 10
// Oculus requests that we shut down and unload the OVR library, by setting
// a "ShouldQuit" flag. To ensure that we don't interfere with
// Oculus software auto-updates, we will not attempt to re-load the
// OVR library until this timeout has elapsed.
pref("dom.vr.oculus.quit.timeout", 30000);
// OSVR device
pref("dom.vr.osvr.enabled", false);
// OpenVR device
-#ifdef XP_WIN
+#if defined(XP_WIN) && defined(HAVE_64BIT_BUILD)
+// We are only enabling WebVR by default on 64-bit builds (Bug 1384459)
pref("dom.vr.openvr.enabled", true);
#else
// See Bug 1310663 (Linux) and Bug 1310665 (macOS)
pref("dom.vr.openvr.enabled", false);
#endif
// Pose prediction reduces latency effects by returning future predicted HMD
// poses to callers of the WebVR API. This currently only has an effect for
// Oculus Rift on SDK 0.8 or greater.