Bug 808067 - Change the compartments we iterate over when ending GC (r=jonco)

This commit is contained in:
Bill McCloskey 2012-11-05 13:17:06 -08:00
Родитель 478e915804
Коммит d9f11af4be
1 изменённых файлов: 2 добавлений и 2 удалений

Просмотреть файл

@ -4154,12 +4154,12 @@ AutoGCSlice::AutoGCSlice(JSRuntime *rt)
AutoGCSlice::~AutoGCSlice()
{
for (GCCompartmentsIter c(runtime); !c.done(); c.next()) {
/* We can't use GCCompartmentsIter if this is the end of the last slice. */
for (CompartmentsIter 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);
}
}