Backed out changeset 07708c9fc5ef (bug 883010) because of test failures
authorEhsan Akhgari <ehsan@mozilla.com>
Mon, 17 Jun 2013 13:13:08 -0400
changeset 135298 f0db2c84b4d133342f8458a4910195f3e247c4ea
parent 135297 25126626dd43bc8ab5c9ec4bbde5aca0d6da2d81
child 135299 26696aad9b5bf08c1643a984695b40cf472dace6
push id29604
push usereakhgari@mozilla.com
push dateMon, 17 Jun 2013 17:13:48 +0000
treeherdermozilla-inbound@f0db2c84b4d1 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
bugs883010
milestone24.0a1
backs out07708c9fc5efdb8d81248550e817253098327d80
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
Backed out changeset 07708c9fc5ef (bug 883010) because of test failures Landed on a CLOSED TREE
content/media/MediaStreamGraph.cpp
content/media/MediaStreamGraph.h
content/media/MediaStreamGraphImpl.h
--- a/content/media/MediaStreamGraph.cpp
+++ b/content/media/MediaStreamGraph.cpp
@@ -1010,21 +1010,17 @@ MediaStreamGraphImpl::RunThread()
       nsTArray<nsAutoPtr<ControlMessage> >& messages = messageQueue[i].mMessages;
 
       for (uint32_t j = 0; j < messages.Length(); ++j) {
         messages[j]->Run();
       }
     }
     messageQueue.Clear();
 
-    // Only update the stream order if needed, since it can be expensive.
-    if (mStreamOrderDirty) {
-      UpdateStreamOrder();
-      mStreamOrderDirty = false;
-    }
+    UpdateStreamOrder();
 
     // Find the sampling rate that we need to use for non-realtime graphs.
     TrackRate sampleRate = IdealAudioRate();
     if (!mRealtime) {
       for (uint32_t i = 0; i < mStreams.Length(); ++i) {
         AudioNodeStream* n = mStreams[i]->AsAudioNodeStream();
         if (n) {
           // We know that the rest of the streams will run at the same rate.
@@ -2150,17 +2146,16 @@ MediaStreamGraphImpl::MediaStreamGraphIm
   , mNeedAnotherIteration(false)
   , mForceShutDown(false)
   , mPostedRunInStableStateEvent(false)
   , mNonRealtimeIsRunning(false)
   , mDetectedNotRunning(false)
   , mPostedRunInStableState(false)
   , mRealtime(aRealtime)
   , mNonRealtimeProcessing(false)
-  , mStreamOrderDirty(false)
 {
 #ifdef PR_LOGGING
   if (!gMediaStreamGraphLog) {
     gMediaStreamGraphLog = PR_NewLogModule("MediaStreamGraph");
   }
 #endif
 
   mCurrentTimeStamp = mInitialTimeStamp = TimeStamp::Now();
@@ -2280,16 +2275,9 @@ MediaStreamGraph::StartNonRealtimeProces
 
   if (graph->mNonRealtimeProcessing)
     return;
   graph->mNonRealtimeTicksToProcess = aTicksToProcess;
   graph->mNonRealtimeProcessing = true;
   graph->EnsureRunInStableState();
 }
 
-void
-ProcessedMediaStream::AddInput(MediaInputPort* aPort)
-{
-  mInputs.AppendElement(aPort);
-  GraphImpl()->SetStreamOrderDirty();
 }
-
-}
--- a/content/media/MediaStreamGraph.h
+++ b/content/media/MediaStreamGraph.h
@@ -266,21 +266,16 @@ public:
     , mExplicitBlockerCount(0)
     , mBlocked(false)
     , mGraphUpdateIndices(0)
     , mFinished(false)
     , mNotifiedFinished(false)
     , mNotifiedBlocked(false)
     , mHasCurrentData(false)
     , mNotifiedHasCurrentData(false)
-    , mHasBeenOrdered(false)
-    , mIsOnOrderingStack(false)
-    , mIsConsumed(false)
-    , mInBlockingSet(false)
-    , mBlockInThisPhase(false)
     , mWrapper(aWrapper)
     , mMainThreadCurrentTime(0)
     , mMainThreadFinished(false)
     , mMainThreadDestroyed(false)
     , mGraph(nullptr)
   {
     MOZ_COUNT_CTOR(MediaStream);
   }
@@ -858,17 +853,20 @@ public:
    */
   void SetAutofinish(bool aAutofinish);
 
   virtual ProcessedMediaStream* AsProcessedStream() { return this; }
 
   friend class MediaStreamGraphImpl;
 
   // Do not call these from outside MediaStreamGraph.cpp!
-  virtual void AddInput(MediaInputPort* aPort);
+  virtual void AddInput(MediaInputPort* aPort)
+  {
+    mInputs.AppendElement(aPort);
+  }
   virtual void RemoveInput(MediaInputPort* aPort)
   {
     mInputs.RemoveElement(aPort);
   }
   bool HasInputPort(MediaInputPort* aPort)
   {
     return mInputs.Contains(aPort);
   }
--- a/content/media/MediaStreamGraphImpl.h
+++ b/content/media/MediaStreamGraphImpl.h
@@ -351,23 +351,16 @@ public:
    * Remove aStream from the graph. Ensures that pending messages about the
    * stream back to the main thread are flushed.
    */
   void RemoveStream(MediaStream* aStream);
   /**
    * Remove aPort from the graph and release it.
    */
   void DestroyPort(MediaInputPort* aPort);
-  /**
-   * Mark the media stream order as dirty.
-   */
-  void SetStreamOrderDirty()
-  {
-    mStreamOrderDirty = true;
-  }
 
   // Data members
 
   /**
    * Media graph thread.
    * Readonly after initialization on the main thread.
    */
   nsCOMPtr<nsIThread> mThread;
@@ -538,18 +531,13 @@ public:
    * audio.
    */
   bool mRealtime;
   /**
    * True when a non-realtime MediaStreamGraph has started to process input.  This
    * value is only accessed on the main thread.
    */
   bool mNonRealtimeProcessing;
-  /**
-   * True when a change has happened which requires us to recompute the stream
-   * blocking order.
-   */
-  bool mStreamOrderDirty;
 };
 
 }
 
 #endif /* MEDIASTREAMGRAPHIMPL_H_ */