Bug 1271166: Reduce media thread pool size. r=cpearce
authorJean-Yves Avenard <jyavenard@mozilla.com>
Mon, 09 May 2016 12:34:22 +1000
changeset 365146 b5091adfb4ed5fce8d856778ace8f23c97fe87cc
parent 365145 6a30c1484e916c03c69a617653ddc4ae8bfbecec
child 365147 51922d1ebfa13a4932ac4c6dfd6010a39d145812
push id17650
push usermartin.thomson@gmail.com
push dateTue, 10 May 2016 05:06:10 +0000
reviewerscpearce
bugs1271166
milestone49.0a1
Bug 1271166: Reduce media thread pool size. r=cpearce A thread pool of 8 threads is already more than enough; especially considering that the media decoder use their own threading model. MozReview-Commit-ID: BOFjNnYTaRz
dom/media/VideoUtils.cpp
--- a/dom/media/VideoUtils.cpp
+++ b/dom/media/VideoUtils.cpp
@@ -200,17 +200,17 @@ already_AddRefed<SharedThreadPool> GetMe
     default:
       MOZ_FALLTHROUGH_ASSERT("Unexpected MediaThreadType");
     case MediaThreadType::PLAYBACK:
       name = "MediaPlayback";
       break;
   }
   return SharedThreadPool::
     Get(nsDependentCString(name),
-        Preferences::GetUint("media.num-decode-threads", 12));
+        Preferences::GetUint("media.num-decode-threads", 4));
 }
 
 bool
 ExtractH264CodecDetails(const nsAString& aCodec,
                         int16_t& aProfile,
                         int16_t& aLevel)
 {
   // H.264 codecs parameters have a type defined as avcN.PPCCLL, where