Bug 808067 - Back out again due to possible orange (r=orange)
authorBill McCloskey <wmccloskey@mozilla.com>
Mon, 05 Nov 2012 17:22:54 -0800
changeset 112371 60c4b0129f99426fee5c15774ade54e6fae60b4b
parent 112370 38a111dc16e21b822c7a678a4b2b55f433d82611
child 112372 0aa8d7cd5b8f3d697a0d334713e96a1bcf5a99bd
push id23812
push useremorley@mozilla.com
push dateTue, 06 Nov 2012 14:01:34 +0000
treeherdermozilla-central@f4aeed115e54 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersorange
bugs808067
milestone19.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
Bug 808067 - Back out again due to possible orange (r=orange)
js/src/jit-test/lib/prolog.js
js/src/jit-test/tests/basic/bug808067.js
js/src/jsgc.cpp
--- a/js/src/jit-test/lib/prolog.js
+++ b/js/src/jit-test/lib/prolog.js
@@ -27,14 +27,10 @@ if (!("selectforgc" in this)) {
 if (!("verifyprebarriers" in this)) {
   verifyprebarriers = function() { }
 }
 
 if (!("verifypostbarriers" in this)) {
   verifypostbarriers = function() { }
 }
 
-if (!("gcPreserveCode" in this)) {
-  gcPreserveCode = function() { }
-}
-
 if ("options" in this)
     options("allow_xml");
deleted file mode 100644
--- a/js/src/jit-test/tests/basic/bug808067.js
+++ /dev/null
@@ -1,19 +0,0 @@
-function TestCase(n, d, e, a)
-  this.reason = '';
-function reportCompare (expected, actual, description) {
-  var output = "";
-  var testcase = new TestCase("unknown-test-name", description, expected, actual);
-  testcase.reason = output;
-}
-gcPreserveCode();
-var summary = 'return with argument and lazy generator detection';
-expect = "generator function foo returns a value";
-actual = (function (j)  {}).message;
-reportCompare(expect, actual, summary + ": 1");
-reportCompare(expect, actual, summary + ": 2");
-gcslice(0);
-gcslice(1);
-gc();
-var strings = [ (0), ];
-for (var i = 0; i < strings.length; i++)
-  reportCompare(expect, actual, summary + (5e1) + strings[i]);
--- a/js/src/jsgc.cpp
+++ b/js/src/jsgc.cpp
@@ -4074,17 +4074,17 @@ ResetIncrementalGC(JSRuntime *rt, const 
         return;
 
     /* Cancel and ongoing marking. */
     bool wasMarking = false;
     {
         AutoCopyFreeListToArenas copy(rt);
         for (GCCompartmentsIter c(rt); !c.done(); c.next()) {
             if (c->isGCMarking()) {
-                c->setNeedsBarrier(false, JSCompartment::UpdateIon);
+                c->setNeedsBarrier(false, JSCompartment::DontUpdateIon);
                 c->setGCState(JSCompartment::NoGC);
                 wasMarking = true;
             }
         }
     }
 
     if (wasMarking)
         rt->gcMarker.reset();
@@ -4149,22 +4149,22 @@ AutoGCSlice::AutoGCSlice(JSRuntime *rt)
         } else {
             JS_ASSERT(!c->needsBarrier());
         }
     }
 }
 
 AutoGCSlice::~AutoGCSlice()
 {
-    /* We can't use GCCompartmentsIter if this is the end of the last slice. */
-    for (CompartmentsIter c(runtime); !c.done(); c.next()) {
+    for (GCCompartmentsIter c(runtime); !c.done(); c.next()) {
         if (c->isGCMarking()) {
             c->setNeedsBarrier(true, JSCompartment::UpdateIon);
             c->arenas.prepareForIncrementalGC(runtime);
         } else {
+            JS_ASSERT(c->isGCSweeping());
             c->setNeedsBarrier(false, JSCompartment::UpdateIon);
         }
     }
 }
 
 static void
 PushZealSelectedObjects(JSRuntime *rt)
 {