Fix code generation around safe points, bug 690376. r=dvander
authorBrian Hackett <bhackett1024@gmail.com>
Thu, 06 Oct 2011 11:42:41 -0700
changeset 78264 e456bef5839b810ddbcac81500b920a99f8dd10d
parent 78263 cfda40f4a5c815bb8954002fdf59dbe89dc34dab
child 78265 6d74d14dc47cef8587a6a317a843359e38fa2034
push id21283
push userbmo@edmorley.co.uk
push dateFri, 07 Oct 2011 10:41:20 +0000
treeherdermozilla-central@bd1411e362fb [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersdvander
bugs690376
milestone10.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
Fix code generation around safe points, bug 690376. r=dvander
js/src/methodjit/Compiler.cpp
--- a/js/src/methodjit/Compiler.cpp
+++ b/js/src/methodjit/Compiler.cpp
@@ -1582,16 +1582,18 @@ mjit::Compiler::generateMethod()
                 return Compile_Error;
             updateJoinVarTypes();
             fallthrough = true;
 
             if (!cx->typeInferenceEnabled()) {
                 /* All join points have synced state if we aren't doing cross-branch regalloc. */
                 opinfo->safePoint = true;
             }
+        } else if (opinfo->safePoint && !cx->typeInferenceEnabled()) {
+            frame.syncAndForgetEverything();
         }
         frame.assertValidRegisterState();
         a->jumpMap[uint32(PC - script->code)] = masm.label();
 
         // Now that we have the PC's register allocation, make sure it gets
         // explicitly updated if this is the loop entry and new loop registers
         // are allocated later on.
         if (loop && !a->parent)