Bug 896154 - Don't check per thread data when verifying pre barriers until after worker threads have been paused, r=billm.
authorBrian Hackett <bhackett1024@gmail.com>
Fri, 26 Jul 2013 16:27:44 -0600
changeset 140247 2287b266756501af9cedfe42082b3525969be655
parent 140246 f570fc641c5f087fc00e87708ecda8053495c3ad
child 140248 a685f0150c6cce0aacd11ebedc52fdeb49a5601c
push id1951
push userryanvm@gmail.com
push dateSun, 28 Jul 2013 01:55:51 +0000
treeherderfx-team@73b69c146ca6 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbillm
bugs896154
milestone25.0a1
Bug 896154 - Don't check per thread data when verifying pre barriers until after worker threads have been paused, r=billm.
js/src/gc/Verifier.cpp
--- a/js/src/gc/Verifier.cpp
+++ b/js/src/gc/Verifier.cpp
@@ -439,27 +439,26 @@ NextNode(VerifyNode *node)
     else
         return (VerifyNode *)((char *)node + sizeof(VerifyNode) +
                              sizeof(EdgeValue)*(node->count - 1));
 }
 
 void
 gc::StartVerifyPreBarriers(JSRuntime *rt)
 {
-    if (rt->gcVerifyPreData ||
-        rt->gcIncrementalState != NO_INCREMENTAL ||
-        !IsIncrementalGCSafe(rt))
-    {
+    if (rt->gcVerifyPreData || rt->gcIncrementalState != NO_INCREMENTAL)
         return;
-    }
 
     MinorGC(rt, JS::gcreason::API);
 
     AutoPrepareForTracing prep(rt);
 
+    if (!IsIncrementalGCSafe(rt))
+        return;
+
     for (GCChunkSet::Range r(rt->gcChunkSet.all()); !r.empty(); r.popFront())
         r.front()->bitmap.clear();
 
     VerifyPreTracer *trc = js_new<VerifyPreTracer>();
 
     rt->gcNumber++;
     trc->number = rt->gcNumber;
     trc->count = 0;