summaryrefslogtreecommitdiffstats
path: root/js/xpconnect
diff options
context:
space:
mode:
authorwolfbeast <mcwerewolf@wolfbeast.com>2019-03-21 09:53:24 +0100
committerwolfbeast <mcwerewolf@wolfbeast.com>2019-03-23 02:00:13 +0100
commit80dfca45772a4d4fc5fd61630e2a812e779ec620 (patch)
treed27f6877ff95b648d5b6f42ca1bdbfd08b1ef4c3 /js/xpconnect
parent90a44b312f35dc679982d558d18555d69e356ffb (diff)
downloadUXP-80dfca45772a4d4fc5fd61630e2a812e779ec620.tar
UXP-80dfca45772a4d4fc5fd61630e2a812e779ec620.tar.gz
UXP-80dfca45772a4d4fc5fd61630e2a812e779ec620.tar.lz
UXP-80dfca45772a4d4fc5fd61630e2a812e779ec620.tar.xz
UXP-80dfca45772a4d4fc5fd61630e2a812e779ec620.zip
Pref the use of unboxed plain objects in JS and disable by default.
This should be all that's needed for #1017, but verification of impact is definitely desired.
Diffstat (limited to 'js/xpconnect')
-rw-r--r--js/xpconnect/src/XPCJSContext.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/js/xpconnect/src/XPCJSContext.cpp b/js/xpconnect/src/XPCJSContext.cpp
index 0243d80e3..bde949a96 100644
--- a/js/xpconnect/src/XPCJSContext.cpp
+++ b/js/xpconnect/src/XPCJSContext.cpp
@@ -1427,6 +1427,8 @@ ReloadPrefsCallback(const char* pref, void* data)
bool extraWarnings = Preferences::GetBool(JS_OPTIONS_DOT_STR "strict");
+ bool unboxedObjects = Preferences::GetBool(JS_OPTIONS_DOT_STR "unboxed_objects");
+
sSharedMemoryEnabled = Preferences::GetBool(JS_OPTIONS_DOT_STR "shared_memory");
#ifdef DEBUG
@@ -1455,6 +1457,8 @@ ReloadPrefsCallback(const char* pref, void* data)
useBaselineEager ? 0 : -1);
JS_SetGlobalJitCompilerOption(cx, JSJITCOMPILER_ION_WARMUP_TRIGGER,
useIonEager ? 0 : -1);
+ JS_SetGlobalJitCompilerOption(cx, JSJITCOMPILER_UNBOXED_OBJECTS,
+ unboxedObjects);
}
XPCJSContext::~XPCJSContext()