зеркало из https://github.com/mozilla/gecko-dev.git
Bug 866681, part 1 - Track if any slice of CC was manually triggered. r=smaug
This commit is contained in:
Родитель
1e12524a6d
Коммит
c660ffa34b
|
@ -102,6 +102,7 @@ struct CycleCollectorResults
|
|||
{
|
||||
mForcedGC = false;
|
||||
mMergedZones = false;
|
||||
mAnyManual = false;
|
||||
mVisitedRefCounted = 0;
|
||||
mVisitedGCed = 0;
|
||||
mFreedRefCounted = 0;
|
||||
|
@ -114,6 +115,7 @@ struct CycleCollectorResults
|
|||
|
||||
bool mForcedGC;
|
||||
bool mMergedZones;
|
||||
bool mAnyManual; // true if any slice of the CC was manually triggered, or at shutdown.
|
||||
uint32_t mVisitedRefCounted;
|
||||
uint32_t mVisitedGCed;
|
||||
uint32_t mFreedRefCounted;
|
||||
|
|
|
@ -3594,6 +3594,10 @@ nsCycleCollector::Collect(ccType aCCType,
|
|||
timeLog.Checkpoint("Collect::FreeSnowWhite");
|
||||
}
|
||||
|
||||
if (aCCType != SliceCC) {
|
||||
mResults.mAnyManual = true;
|
||||
}
|
||||
|
||||
++mResults.mNumSlices;
|
||||
|
||||
bool continueSlice = aBudget.isUnlimited() || !aPreferShorterSlices;
|
||||
|
@ -3779,6 +3783,7 @@ nsCycleCollector::BeginCollection(ccType aCCType,
|
|||
// Set up the data structures for building the graph.
|
||||
mGraph.Init();
|
||||
mResults.Init();
|
||||
mResults.mAnyManual = (aCCType != SliceCC);
|
||||
bool mergeZones = ShouldMergeZones(aCCType);
|
||||
mResults.mMergedZones = mergeZones;
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче