Why SSDs lose performance with compressed files

The Boss

PC

Why SSDs lose performance with compressed files

Compressed, files, lose, performance, SSDs


As you know, depending on the size of the file allocation we configure when formatting the storage unit (whether SSD or not) it has an impact on the method and functionality when that file handles files. In the same way, it happens that depending on how the compression is done, it will cost more or less SSD to manage these files.

Having said that, let's start at the beginning, because it's understanding what causes these performance problems in SSDs is compressed filesWe must first understand how compressing a file works.

How a file system works

File compression is known as «Loss of Loss«, Or pressure not lost. Unlike "Lossy Compression" or lost compression used for video or music, reducing file size does not mean a loss of quality. The stress lost will reduce the quality of the audio or video file by removing parts of it, and once we do that file will stop working.

Therefore, file compression remains intact, and its purpose is to group multiple files into one that is smaller in size.

Files compressed

To explain how this pressure, which may appear to some people as magic, will give a basic example. Assume that files exist colored blocks, and by pressing on them what we do is to put the same color together in the same block as many times as possible. It is best to have one block of each color, but in most cases it is impossible. With the image below you can easily understand it.

Obviously those "missing" blocks are listed, so that when we want to export a file we will know exactly where they were and what they were contained to "restore" to their original form.

Another example is that you can see it better, and with color blocks, but with the right setting there will be only one block of each color. Here we have 10: 2 blocks of blue, 3 red and 5 yellow. When we pressed them, we only had three blocks, one color each and each with an indication of what was originally there.

There is another example. Assume we have a file containing the following content:

bbbbuuuuuuuuaaaaaa

That compressed file looks like this:

b5u9a6

Obviously, the file would be too small and take up too little space. How does this apply to pressure.

Why do SSDs lose performance in compressed files?

This is where the file size distribution we discussed earlier starts working again. Compressing files means reducing the file size and also the index, the type of display that shows what the file was in the original before compressing it.

Because of this, SSDs already have problems with small files, so imagine if we put in front of them a container with a lot of very small files and, in addition, to get rid of them they must be constantly consulting the index, and only knowing what they are and what they have inside. This is the main reason why SSDs lose so much functionality when they have to handle compressed files.

Take a look at the following screenshot of the ATTO bench, for example. Here we can see that with smaller files the SSD works much better, but as files increase in size, performance increases.

Another example, with the AS SSD File Compression Benchmark, shows exactly how an SSD behaves when it has to handle compressed files. We're talking about PCIe NVMe SSD running at 3200 MB / s read and 2800 MB / s write, with algorithms that prefer better performance with compressed files and, nevertheless, performance is financially hard.

This is especially evident in SATA 3 SSDs, where the interface limits the width of the file used to handle files.

Leave a Comment