2014-08-23, 12:53
(2014-08-23, 12:03)Tompen Wrote: 5) Increased iBufferSize and min_chunk_size in File.cpp to 256KBInteresting. I'm guessing that not every change here is essential. Can you try reverting each of these changes one at a time and report if behaviour is okay or not?
6) Increased READ_CACHE_CHUNK_SIZE in FileCache.cpp to 256KB
7) Increased FFMPEG_FILE_BUFFER_SIZE in DVDDemuxFFmpeg.h to 256kB
8) Added READ_CACHED and READ_CHUNKED to if(fp->Open(filename)) in DVDInputStreamBluray.cpp (see DVDInputStreamFile.cpp)
9) buffermode 1 and 3MB cachemembuffersize and 99 readbufferfactor
10) reduced m_messageQueue.SetMaxDataSize to 15MB in DVDPlayerVideo.cpp (see OMXPlayerVideo.cpp)
11) increased m_messageQueue.SetMaxDataSize to 15MB in OMXPlayerVideo.cpp
11) sysctl net.ipv4.udp_rmem_min = 262144
12 sysctl vm.swappiness = 100
14) Removed most of the Sleep occurances in the OMXPlayer.cpp process while-loop.
15) Decreased thread priority for OMXPlayer.cpp to lowest possible.
It's possible one of these changes is producing the majority of the benefit and identifying that (with an aim to getting it submitted to xbmc) would be useful.
Quote:When filecache is enabled, the player seems to repeatedly loop and try to fetch data from the filecache, even if it is empty. This waste cpu cycles that are better spent by the filecache to fill itself, so therefor I changed the OMXPlayer thread to lowest possible priority and also removed most of the sleeps.Again interesting. There is another report on the file cache producing high cpu usage in some situations (a radio stream, so presumably low bandwidth and therefore likely to be mostly running with an empty cache). How did you determine the repeated looping? Have you seen anything suspicious in the code?
Quote: <fanartres>1080</fanartres>Increasing fanart resolution from the default on a 256M Pi wouldn't be recommended by me. This does significantly increase gpu memory usage. You might find reducing this (and rescanning the thumbnail cache) allows gpu_mem to be reduced, and so reduce the swap needed by the arm.
<imageres>720</imageres>