Bug 1555558 - Don't collect the nursery for finalise or decommit slices r=sfink

Differential Revision: https://phabricator.services.mozilla.com/D33137

--HG--
extra : moz-landing-system : lando
This commit is contained in:
Paul Bone 2019-05-31 06:05:19 +00:00
parent 23673be0be
commit f8fc1d2bcc

View File

@ -7282,11 +7282,9 @@ void GCRuntime::incrementalSlice(SliceBudget& budget, JS::GCReason reason,
MOZ_FALLTHROUGH;
case State::Compact:
MOZ_ASSERT(nursery().isEmpty());
storeBuffer().checkEmpty();
if (isCompacting) {
MOZ_ASSERT(nursery().isEmpty());
storeBuffer().checkEmpty();
if (!startedCompacting) {
beginCompactPhase();
}
@ -7630,11 +7628,11 @@ bool GCRuntime::shouldCollectNurseryForSlice(bool nonincrementalByAPI,
switch (incrementalState) {
case State::NotActive:
case State::Sweep:
case State::Finalize:
case State::Compact:
case State::Decommit:
return true;
case State::Mark:
case State::Finalize:
case State::Decommit:
return (nonincrementalByAPI || budget.isUnlimited() || lastMarkSlice ||
nursery().shouldCollect() || hasIncrementalTwoSliceZealMode());
case State::Finish: