Disable the tracer when Ion is enabled (bug 684318, r=sstangl).
authorDavid Anderson <danderson@mozilla.com>
Fri, 02 Sep 2011 16:19:48 -0700
changeset 105231 d03e1ba0d3b5a0ee34fb18788acd6fe53aa16673
parent 105230 1643eac86ad14cdde59cdb349dedac7cc5fbb7ab
child 105232 aa856d61ef8537a2cec9b05c6fa41f13464fca1a
push id14706
push usereakhgari@mozilla.com
push dateTue, 11 Sep 2012 20:39:52 +0000
treeherdermozilla-inbound@d50bf1edaabe [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerssstangl
bugs684318
milestone9.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
Disable the tracer when Ion is enabled (bug 684318, r=sstangl).
js/src/jscntxt.cpp
js/src/jstracer.cpp
--- a/js/src/jscntxt.cpp
+++ b/js/src/jscntxt.cpp
@@ -1597,23 +1597,27 @@ IsJITBrokenHere()
     return isBroken;
 }
 #endif
 
 void
 JSContext::updateJITEnabled()
 {
 #ifdef JS_TRACER
+# ifndef JS_ION
     traceJitEnabled = ((runOptions & JSOPTION_JIT) &&
                        !IsJITBrokenHere() &&
                        compartment &&
                        !compartment->debugMode() &&
                        (debugHooks == &js_NullDebugHooks ||
                         (debugHooks == &runtime->globalDebugHooks &&
                          !runtime->debuggerInhibitsJIT())));
+# else
+    traceJitEnabled = false;
+# endif
 #endif
 #ifdef JS_METHODJIT
     methodJitEnabled = (runOptions & JSOPTION_METHODJIT) &&
                        !IsJITBrokenHere()
 # if defined JS_CPU_X86 || defined JS_CPU_X64
                        && JSC::MacroAssemblerX86Common::getSSEState() >=
                           JSC::MacroAssemblerX86Common::HasSSE2
 # endif
--- a/js/src/jstracer.cpp
+++ b/js/src/jstracer.cpp
@@ -2296,16 +2296,20 @@ TraceRecorder::TraceRecorder(JSContext* 
     generatedSpecializedNative(),
     tempTypeMap(cx),
     w(&tempAlloc(), lirbuf)
 {
     JS_ASSERT(globalObj == cx->fp()->scopeChain().getGlobal());
     JS_ASSERT(globalObj->hasOwnShape());
     JS_ASSERT(cx->regs().pc == (jsbytecode*)fragment->ip);
 
+#ifdef JS_ION
+    JS_NOT_REACHED("Tracer is not compatible with Ion");
+#endif
+
 #ifdef JS_METHODJIT
     if (TRACE_PROFILER(cx))
         AbortProfiling(cx);
 #endif
 
     JS_ASSERT(JS_THREAD_DATA(cx)->onTraceCompartment == NULL);
     JS_ASSERT(JS_THREAD_DATA(cx)->profilingCompartment == NULL);
     JS_ASSERT(JS_THREAD_DATA(cx)->recordingCompartment == NULL);