Bug 797185 - Disable DVG stack search when building with --enable-more-deterministic. r=decoder
authorJan de Mooij <jdemooij@mozilla.com>
Thu, 04 Oct 2012 13:26:16 +0200
changeset 109347 a85c0f30cdfae5b2283516537b89374165b39810
parent 109346 a5c50066ecbb2f9f91c8a53a3d0ee198a3045f1e
child 109348 8af00f1609b9357fc3de65742e3f3d3a9b9ae951
push id82
push usershu@rfrn.org
push dateFri, 05 Oct 2012 13:20:22 +0000
reviewersdecoder
bugs797185
milestone18.0a1
Bug 797185 - Disable DVG stack search when building with --enable-more-deterministic. r=decoder
js/src/jsopcode.cpp
--- a/js/src/jsopcode.cpp
+++ b/js/src/jsopcode.cpp
@@ -6161,16 +6161,25 @@ static bool
 DecompileExpressionFromStack(JSContext *cx, int spindex, int skipStackHits, Value v, char **res)
 {
     JS_ASSERT(spindex < 0 ||
               spindex == JSDVG_IGNORE_STACK ||
               spindex == JSDVG_SEARCH_STACK);
 
     *res = NULL;
 
+#ifdef JS_MORE_DETERMINISTIC
+    /*
+     * Give up if we need deterministic behavior for differential testing.
+     * IonMonkey doesn't use StackFrames and this ensures we get the same
+     * error messages.
+     */
+    return true;
+#endif
+
     ScriptFrameIter frameIter(cx);
 
     if (frameIter.done())
         return true;
 
     JSScript *script = frameIter.script();
     jsbytecode *valuepc = frameIter.pc();
     JSFunction *fun = frameIter.isFunctionFrame()