From: Carl Hetherington Date: Tue, 6 Nov 2018 02:15:38 +0000 (+0000) Subject: Double up on DCP-decode prepare threads and readahead as I think it provides a slight... X-Git-Tag: v2.13.66^0 X-Git-Url: https://git.carlh.net/gitweb/?a=commitdiff_plain;h=de0df88ec4c6e4e36fe31765239041a35513c94c;p=dcpomatic.git Double up on DCP-decode prepare threads and readahead as I think it provides a slight performance improvement for playback. --- diff --git a/src/lib/butler.cc b/src/lib/butler.cc index d50c461c8..018334c7e 100644 --- a/src/lib/butler.cc +++ b/src/lib/butler.cc @@ -43,7 +43,7 @@ using boost::optional; /** Minimum video readahead in frames */ #define MINIMUM_VIDEO_READAHEAD 10 /** Maximum video readahead in frames; should never be reached unless there are bugs in Player */ -#define MAXIMUM_VIDEO_READAHEAD 24 +#define MAXIMUM_VIDEO_READAHEAD 48 /** Minimum audio readahead in frames */ #define MINIMUM_AUDIO_READAHEAD (48000 * MINIMUM_VIDEO_READAHEAD / 24) /** Minimum audio readahead in frames; should never be reached unless there are bugs in Player */ @@ -79,10 +79,10 @@ Butler::Butler (shared_ptr player, shared_ptr log, AudioMapping aud */ if (_log) { - LOG_TIMING("start-prepare-threads %1", boost::thread::hardware_concurrency()); + LOG_TIMING("start-prepare-threads %1", boost::thread::hardware_concurrency() * 2); } - for (size_t i = 0; i < boost::thread::hardware_concurrency(); ++i) { + for (size_t i = 0; i < boost::thread::hardware_concurrency() * 2; ++i) { _prepare_pool.create_thread (bind (&boost::asio::io_service::run, &_prepare_service)); } }