paulhoule / tentacruel

MIT License
0 stars 0 forks source link

Performance analysis: latency #17

Open paulhoule opened 5 years ago

paulhoule commented 5 years ago

One application I would like to do is use the HEOS system to play sound effects, such as

https://www.youtube.com/watch?v=_f4oJ-DQdSY

that is a short and extreme example, another one is

https://www.youtube.com/watch?v=ELfxtdEakhk

Latency is one thing, but another thing is that sometimes we seem to miss the beginning of the file, which is a bad outcome.

Using a USB stick the latency seems to be less than using the Plex server. My impression is that it is faster on a USB stick with a small filesystem rather than a big one. It may make a difference if it is a fast USB stick or which device has the USB stick plugged in and which device we are connected to as a controller.

paulhoule commented 5 years ago

Right now I am sitting in Room 23, I have the Samsung Stick plugged into that.

My hunch is that the receiver has more CPU power than the other devices. Subjectively it seems quicker to read directories.

When I play "Monokuma-San's Lesson" it seems to be perfectly on cue.

The hunch is that playback start is delayed by many factors such as:

paulhoule commented 5 years ago

Here is my further observation, albeit small sample size.

That gives an intuitive sense of what the latency is like, also some idea of what would go in a controlled experiment.

I have also wondered if having a super-small filesystem (like only the sound effects you will really use) will help.

paulhoule commented 5 years ago

Here is the data for the cheap stick:

-----------------------------------------------------------------------
CrystalDiskMark 6.0.0 x64 (C) 2007-2017 hiyohiyo
                          Crystal Dew World : https://crystalmark.info/
-----------------------------------------------------------------------
* MB/s = 1,000,000 bytes/s [SATA/600 = 600,000,000 bytes/s]
* KB = 1000 bytes, KiB = 1024 bytes

   Sequential Read (Q= 32,T= 1) :   122.047 MB/s
  Sequential Write (Q= 32,T= 1) :    44.323 MB/s
  Random Read 4KiB (Q=  8,T= 8) :     8.033 MB/s [   1961.2 IOPS]
 Random Write 4KiB (Q=  8,T= 8) :     0.736 MB/s [    179.7 IOPS]
  Random Read 4KiB (Q= 32,T= 1) :     7.861 MB/s [   1919.2 IOPS]
 Random Write 4KiB (Q= 32,T= 1) :     0.705 MB/s [    172.1 IOPS]
  Random Read 4KiB (Q=  1,T= 1) :     7.786 MB/s [   1900.9 IOPS]
 Random Write 4KiB (Q=  1,T= 1) :     0.710 MB/s [    173.3 IOPS]

  Test : 1024 MiB [E: 14.7% (4.2/28.6 GiB)] (x5)  [Interval=5 sec]
  Date : 2019/01/23 20:44:28
    OS : Windows 10 Professional [10.0 Build 17763] (x64)
paulhoule commented 5 years ago

Here is what I get for the Samsung:

-----------------------------------------------------------------------
CrystalDiskMark 6.0.0 x64 (C) 2007-2017 hiyohiyo
                          Crystal Dew World : https://crystalmark.info/
-----------------------------------------------------------------------
* MB/s = 1,000,000 bytes/s [SATA/600 = 600,000,000 bytes/s]
* KB = 1000 bytes, KiB = 1024 bytes

   Sequential Read (Q= 32,T= 1) :   143.097 MB/s
  Sequential Write (Q= 32,T= 1) :    36.015 MB/s
  Random Read 4KiB (Q=  8,T= 8) :     6.030 MB/s [   1472.2 IOPS]
 Random Write 4KiB (Q=  8,T= 8) :     1.853 MB/s [    452.4 IOPS]
  Random Read 4KiB (Q= 32,T= 1) :     5.913 MB/s [   1443.6 IOPS]
 Random Write 4KiB (Q= 32,T= 1) :     1.009 MB/s [    246.3 IOPS]
  Random Read 4KiB (Q=  1,T= 1) :     5.143 MB/s [   1255.6 IOPS]
 Random Write 4KiB (Q=  1,T= 1) :     0.948 MB/s [    231.4 IOPS]

  Test : 1024 MiB [E: 10.3% (3.1/29.9 GiB)] (x5)  [Interval=5 sec]
  Date : 2019/01/23 20:54:19
    OS : Windows 10 Professional [10.0 Build 17763] (x64)

which is not hugely different. Samsung wins on some things, the Best Buy house brand wins on some other things.