summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorwin7-7 <win7-7@users.noreply.github.com>2019-04-30 02:43:47 +0300
committerGitHub <noreply@github.com>2019-04-30 02:43:47 +0300
commit4d03ec5c22ff2ac288808ad008a94634a53745da (patch)
tree1ca35d5ab43bf09adbe1157a6f937242aa059d48
parentd59b5441ef7552889b6e64c677086caeaefaaf3e (diff)
downloadUXP-4d03ec5c22ff2ac288808ad008a94634a53745da.tar
UXP-4d03ec5c22ff2ac288808ad008a94634a53745da.tar.gz
UXP-4d03ec5c22ff2ac288808ad008a94634a53745da.tar.lz
UXP-4d03ec5c22ff2ac288808ad008a94634a53745da.tar.xz
UXP-4d03ec5c22ff2ac288808ad008a94634a53745da.zip
remaining tabs to space js/src/jsgc.cpp
-rw-r--r--js/src/jsgc.cpp52
1 files changed, 26 insertions, 26 deletions
diff --git a/js/src/jsgc.cpp b/js/src/jsgc.cpp
index 283eb22b0..589e478f4 100644
--- a/js/src/jsgc.cpp
+++ b/js/src/jsgc.cpp
@@ -3758,11 +3758,11 @@ GCRuntime::beginMarkPhase(JS::gcreason::Reason reason, AutoLockForExclusiveAcces
gcstats::AutoPhase ap2(stats, gcstats::PHASE_MARK_ROOTS);
- if (isIncremental) {
+ if (isIncremental) {
bufferGrayRoots();
- markCompartments();
- }
-
+ markCompartments();
+ }
+
return true;
}
@@ -3778,11 +3778,11 @@ GCRuntime::markCompartments()
* (1) the compartment has been entered (set in beginMarkPhase() above)
* (2) the compartment is not being collected (set in beginMarkPhase()
* above)
- * (3) an object in the compartment was marked during root marking, either
- * as a black root or a gray root (set in RootMarking.cpp), or
+ * (3) an object in the compartment was marked during root marking, either
+ * as a black root or a gray root (set in RootMarking.cpp), or
* (4) the compartment has incoming cross-compartment edges from another
- * compartment that has maybeAlive set (set by this method).
- *
+ * compartment that has maybeAlive set (set by this method).
+ *
* If the maybeAlive is false, then we set the scheduledForDestruction flag.
* At the end of the GC, we look for compartments where
* scheduledForDestruction is true. These are compartments that were somehow
@@ -3802,35 +3802,35 @@ GCRuntime::markCompartments()
/* Propagate the maybeAlive flag via cross-compartment edges. */
- Vector<JSCompartment*, 0, js::SystemAllocPolicy> workList;
-
- for (CompartmentsIter comp(rt, SkipAtoms); !comp.done(); comp.next()) {
- if (comp->maybeAlive) {
- if (!workList.append(comp))
- return;
- }
- }
- while (!workList.empty()) {
- JSCompartment* comp = workList.popCopy();
- for (JSCompartment::WrapperEnum e(comp); !e.empty(); e.popFront()) {
+ Vector<JSCompartment*, 0, js::SystemAllocPolicy> workList;
+
+ for (CompartmentsIter comp(rt, SkipAtoms); !comp.done(); comp.next()) {
+ if (comp->maybeAlive) {
+ if (!workList.append(comp))
+ return;
+ }
+ }
+ while (!workList.empty()) {
+ JSCompartment* comp = workList.popCopy();
+ for (JSCompartment::WrapperEnum e(comp); !e.empty(); e.popFront()) {
if (e.front().key().is<JSString*>())
continue;
JSCompartment* dest = e.front().mutableKey().compartment();
if (dest && !dest->maybeAlive) {
dest->maybeAlive = true;
- if (!workList.append(dest))
- return;
- }
+ if (!workList.append(dest))
+ return;
+ }
}
}
/* Set scheduleForDestruction based on maybeAlive. */
- for (GCCompartmentsIter comp(rt); !comp.done(); comp.next()) {
- MOZ_ASSERT(!comp->scheduledForDestruction);
- if (!comp->maybeAlive && !rt->isAtomsCompartment(comp))
- comp->scheduledForDestruction = true;
+ for (GCCompartmentsIter comp(rt); !comp.done(); comp.next()) {
+ MOZ_ASSERT(!comp->scheduledForDestruction);
+ if (!comp->maybeAlive && !rt->isAtomsCompartment(comp))
+ comp->scheduledForDestruction = true;
}
}