зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1085407 - Make the timeline actor's 'memory' and 'ticks' events use the docshell absolute time instead of Date.now(), r=jsantell,ttromey
This commit is contained in:
Родитель
85e3cfa6ad
Коммит
6bd1e17d62
|
@ -138,20 +138,24 @@ let TimelineActor = exports.TimelineActor = protocol.ActorClass({
|
|||
if (!this._isRecording) {
|
||||
return;
|
||||
}
|
||||
if (!this.docShells.length) {
|
||||
return;
|
||||
}
|
||||
|
||||
let endTime = this.docShells[0].now();
|
||||
let markers = [];
|
||||
|
||||
for (let docShell of this.docShells) {
|
||||
markers = [...markers, ...docShell.popProfileTimelineMarkers()];
|
||||
}
|
||||
if (markers.length > 0) {
|
||||
let endTime = this.docShells[0].now();
|
||||
events.emit(this, "markers", markers, endTime);
|
||||
}
|
||||
if (this._memoryActor) {
|
||||
events.emit(this, "memory", Date.now(), this._memoryActor.measure());
|
||||
events.emit(this, "memory", endTime, this._memoryActor.measure());
|
||||
}
|
||||
if (this._framerateActor) {
|
||||
events.emit(this, "ticks", Date.now(), this._framerateActor.getPendingTicks());
|
||||
events.emit(this, "ticks", endTime, this._framerateActor.getPendingTicks());
|
||||
}
|
||||
|
||||
this._dataPullTimeout = setTimeout(() => {
|
||||
|
|
Загрузка…
Ссылка в новой задаче