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 152508 2287b266756501af9cedfe42082b3525969be655
parent 152507 f570fc641c5f087fc00e87708ecda8053495c3ad
child 152509 a685f0150c6cce0aacd11ebedc52fdeb49a5601c
push id2859
push userakeybl@mozilla.com
push dateMon, 16 Sep 2013 19:14:59 +0000
treeherdermozilla-beta@87d3c51cd2bf [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbillm
bugs896154
milestone25.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 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;