Ram Usage Question - New Mac Mini
  • There is much discussion on this forum about the limitations of 8GB of ram in the new M1 Mini. On principle, I would like to avoid giving Apple $200 for the extra 8GB of ram. So here is my question: Doesn't the Mac use virtual memory? And isn't the internal SSD really fast? If the previous things are true, then why is having only 8GB of RAM a limitation at all? Won't the software just use virtual memory? And, if the software is not doing a lot of pre-capture, then what is all that RAM being used for anyway? Is it the buffers? The average 1080p camera stream at 15fps and medium compression generates about 20MB per minute. In a system with 32 cameras, 20MB X 32 cameras equals 640MB per minute. At this rate, the system could buffer or pre-capture all 32 cameras for 5 whole minutes each and still only use 3.2GB of ram to do it. I have a 27inch iMac running 32 cameras configured as described above - running SS 4.2.13. The machine has only 8GB of RAM. It performs perfectly. So what am I missing here? Have any users actually come up against the real world camera limitation with 8GB in the new Mini? Thanks!
  • Yes, if real RAM runs low, virtual memory is employed. And on the M1 mini, the SSD is very fast, so virtual memory performs very well. Still, real RAM is >10x faster than SSD, and plus if you have bug chunks of data needing to be swapped to/from the disk frequently, this is a lot of extra copying that wouldn't need to be done if RAM were plentiful, which will inevitably hit performance somewhat.

    The features that use a lot of RAM in SecuritySpy are instant replay (which buffers uncompressed video, albeit at low frame rates), and pre-capture (which buffers compressed video, but at full frame rate). Also every time SecuritySpy starts a video decompression task (for decoding incoming video) or a video compression task (for producing web streams), the system allocates RAM for this (from tens to sometimes hundreds of MB per instance). Then you have various buffers for video display, network ports, disk IO etc.

    Still, I would agree with you that 8 GB is perfectly fine for most systems. We have recently updated our system requirements calculator with the new Mac mini in mind, including better RAM estimates.
  • According to the calculator, the M1 can handle basically twice as many cameras as the next most recent Mac mini (2018)? It's that big of a difference? It didn't look anywhere near that from the video codec tests, at least when you factored in combined sw/hw tests.
  • Hi @emergent, yes this really is the case for H.265, which the calculator is set to by default. If you change the calculator's codec setting to H.264, you will see that the performance is much more similar between these two machines.

    The reason for this is partly that the M1 has a significantly higher capability both for software decoding and for hardware decoding for H.265.

    But there's another wrinkle here too: for Intel Core machines, software and hardware decoding seem to compete somewhat, so that the maximum throughput that these machines can manage when both SW+HW decoding is in use is significantly lower than the sum of SW alone + HW alone. Conversely, for the M1, the SW+HW value is similar to the sum of SW alone + HW alone, indicating much less competition between the two.

    This, combined with the fact that the calculator attempts to give a 20% margin of error separately for SW and HW decoding, results in this estimate, which I believe is an accurate indicator of real-world performance.
  • MacRumors is reporting excessive SSD wear on the new M1 mini. I wonder if this is related to virtual memory. https://www.macrumors.com/2021/02/23/m1-mac-users-report-excessive-ssd-wear/

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!