mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-16 14:55:47 +00:00
Bug 1207696 Part 5j - Don't add GC events to timelines when recording or replaying, r=mccr8.
--HG-- extra : rebase_source : 1c600ce8918a3b343864c8a3606a4de5d25b87f6
This commit is contained in:
parent
3bf3cc3f2e
commit
da3fee20ba
@ -949,14 +949,17 @@ CycleCollectedJSRuntime::GCNurseryCollectionCallback(JSContext* aContext,
|
||||
MOZ_ASSERT(CycleCollectedJSContext::Get()->Context() == aContext);
|
||||
MOZ_ASSERT(NS_IsMainThread());
|
||||
|
||||
RefPtr<TimelineConsumers> timelines = TimelineConsumers::Get();
|
||||
if (timelines && !timelines->IsEmpty()) {
|
||||
UniquePtr<AbstractTimelineMarker> abstractMarker(
|
||||
MakeUnique<MinorGCMarker>(aProgress, aReason));
|
||||
timelines->AddMarkerForAllObservedDocShells(abstractMarker);
|
||||
if (!recordreplay::IsRecordingOrReplaying()) {
|
||||
RefPtr<TimelineConsumers> timelines = TimelineConsumers::Get();
|
||||
if (timelines && !timelines->IsEmpty()) {
|
||||
UniquePtr<AbstractTimelineMarker> abstractMarker(
|
||||
MakeUnique<MinorGCMarker>(aProgress, aReason));
|
||||
timelines->AddMarkerForAllObservedDocShells(abstractMarker);
|
||||
}
|
||||
}
|
||||
|
||||
if (aProgress == JS::GCNurseryProgress::GC_NURSERY_COLLECTION_START) {
|
||||
recordreplay::AutoPassThroughThreadEvents pt;
|
||||
self->mLatestNurseryCollectionStart = TimeStamp::Now();
|
||||
}
|
||||
#ifdef MOZ_GECKO_PROFILER
|
||||
|
Loading…
Reference in New Issue
Block a user