Bug 1189506. Move setting of mStateComputedTime to OneIteration so it's near setting mProcessedTime. r=karlt
authorRobert O'Callahan <robert@ocallahan.org>
Sat, 05 Sep 2015 00:41:15 +1200
changeset 295511 f38cc960f179b0e5907b0ad947f42410484905fd
parent 295510 71ba3cb1406e9a63d4d7d09acc7420ccd5d37ab8
child 295512 e09858e37a65770cc21af64aea1756b0740b00fa
push id5245
push userraliiev@mozilla.com
push dateThu, 29 Oct 2015 11:30:51 +0000
treeherdermozilla-beta@dac831dc1bd0 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerskarlt
bugs1189506
milestone43.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1189506. Move setting of mStateComputedTime to OneIteration so it's near setting mProcessedTime. r=karlt
dom/media/MediaStreamGraph.cpp
--- a/dom/media/MediaStreamGraph.cpp
+++ b/dom/media/MediaStreamGraph.cpp
@@ -1109,18 +1109,16 @@ MediaStreamGraphImpl::UpdateGraph(GraphT
   // Since stream blocking is computed in the interval of
   // [mStateComputedTime, aEndBlockingDecision), it won't be computed at all.
   // We should ensure next iteration so that pending blocking changes will be
   // computed in next loop.
   if (ensureNextIteration ||
       aEndBlockingDecisions == mStateComputedTime) {
     EnsureNextIteration();
   }
-
-  mStateComputedTime = aEndBlockingDecisions;
 }
 
 void
 MediaStreamGraphImpl::Process(GraphTime aFrom, GraphTime aTo)
 {
   // Play stream contents.
   bool allBlockedForever = true;
   // True when we've done ProcessInput for all processed streams.
@@ -1253,17 +1251,20 @@ bool
 MediaStreamGraphImpl::OneIteration(GraphTime aStateEnd)
 {
   MaybeProduceMemoryReport();
 
   GraphTime stateFrom = mStateComputedTime;
   GraphTime stateEnd = std::min(aStateEnd, mEndTime);
   UpdateGraph(stateEnd);
 
+  mStateComputedTime = stateEnd;
+
   Process(stateFrom, stateEnd);
+
   mProcessedTime = stateEnd;
 
   UpdateCurrentTimeForStreams(stateFrom, stateEnd);
 
   return UpdateMainThreadState();
 }
 
 void