Benchmark of Stream Compressors in terms of Execution Time


BenchmarkDotNet v0.13.12, Windows 11 (10.0.22631.3085/23H2/2023Update/SunValley3)
AMD Ryzen 7 5800H with Radeon Graphics, 1 CPU, 16 logical and 8 physical cores
.NET SDK 8.0.101
  [Host]     : .NET 8.0.1 (8.0.123.58001), X64 RyuJIT AVX2
  Job-KKQZIR : .NET 8.0.1 (8.0.123.58001), X64 RyuJIT AVX2

RunStrategy=Throughput  Compressed=EasyCompressor.Benchmarks.BaseBenchmark+CompressedArg

Comparison: Mean

CompressorCompressedSizeDataCompressDecompressCompressAndDecompress
SnappierCompressor 4,751 bytes (22.98 %) Large (20 KB) 11,229.2 ns 179.9 ns (doubtful) 21,340.3 ns
SnappyCompressor (deprecated) 4,755 bytes (23.00 %) Large (20 KB) 14,232.6 ns 8,482.6 ns 23,820.1 ns
LZ4Compressor 4,386 bytes (21.22 %) Large (20 KB) 15,462.2 ns 9,990.1 ns 26,186.9 ns
ZstdCompressor (deprecated) 3,622 bytes (17.52 %) Large (20 KB) 23,591.6 ns 12,366.1 ns 36,313.6 ns
BrotliCompressor 3,650 bytes (17.66 %) Large (20 KB) 37,288.3 ns 35,637.1 ns 69,576.9 ns
BrotliNETCompressor (deprecated) 3,650 bytes (17.66 %) Large (20 KB) 62,551.4 ns 56,781.3 ns 124,482.6 ns
DeflateCompressor 3,573 bytes (17.28 %) Large (20 KB) 63,045.6 ns 19,309.3 ns 86,950.5 ns
GZipCompressor 3,591 bytes (17.37 %) Large (20 KB) 63,096.4 ns 20,294.2 ns 89,466.2 ns
ZstdSharpCompressor 3,622 bytes (17.52 %) Large (20 KB) 66,929.0 ns 11,373.7 ns 86,125.6 ns
ZLibCompressor 3,579 bytes (17.31 %) Large (20 KB) 69,395.4 ns 25,182.5 ns 98,318.9 ns
LZMACompressor 2,866 bytes (13.86 %) Large (20 KB) 3,944,462.3 ns 577,074.0 ns 4,629,848.5 ns
CompressorCompressedSizeDataCompressDecompressCompressAndDecompress
SnappierCompressor 1,289 bytes (12.95 %) Medium (10 KB) 3,374.3 ns 144.3 ns (doubtful) 6,977.1 ns
LZ4Compressor 928 bytes (9.33 %) Medium (10 KB) 3,797.7 ns 3,650.1 ns 7,462.2 ns
SnappyCompressor (deprecated) 1,270 bytes (12.76 %) Medium (10 KB) 3,920.1 ns 2,292.9 ns 7,132.6 ns
ZstdCompressor (deprecated) 860 bytes (8.64 %) Medium (10 KB) 7,834.4 ns 3,996.9 ns 12,956.2 ns
BrotliCompressor 794 bytes (7.98 %) Medium (10 KB) 11,254.7 ns 16,131.3 ns 28,776.0 ns
DeflateCompressor 875 bytes (8.79 %) Medium (10 KB) 21,339.8 ns 7,505.3 ns 31,271.5 ns
GZipCompressor 893 bytes (8.97 %) Medium (10 KB) 22,039.9 ns 8,099.5 ns 32,445.5 ns
ZLibCompressor 881 bytes (8.85 %) Medium (10 KB) 24,684.7 ns 10,353.8 ns 36,706.6 ns
BrotliNETCompressor (deprecated) 794 bytes (7.98 %) Medium (10 KB) 32,210.3 ns 41,843.5 ns 77,189.0 ns
ZstdSharpCompressor 860 bytes (8.64 %) Medium (10 KB) 43,586.1 ns 2,769.5 ns 45,999.0 ns
LZMACompressor 741 bytes (7.45 %) Medium (10 KB) 1,688,751.6 ns 170,925.8 ns 1,910,325.4 ns
CompressorCompressedSizeDataCompressDecompressCompressAndDecompress
SnappierCompressor 1,812 bytes (90.15 %) Small (2 KB) 2,262.7 ns 152.3 ns (doubtful) 3,332.0 ns
SnappyCompressor (deprecated) 1,772 bytes (88.16 %) Small (2 KB) 3,450.4 ns 923.7 ns 4,626.0 ns
LZ4Compressor 1,768 bytes (87.96 %) Small (2 KB) 5,687.4 ns 1,313.5 ns 7,533.8 ns
ZstdCompressor (deprecated) 1,687 bytes (83.93 %) Small (2 KB) 7,053.6 ns 2,862.8 ns 10,509.3 ns
BrotliCompressor 1,494 bytes (74.33 %) Small (2 KB) 14,842.8 ns 9,901.3 ns 25,478.5 ns
DeflateCompressor 1,392 bytes (69.25 %) Small (2 KB) 28,266.5 ns 8,036.9 ns 38,084.5 ns
GZipCompressor 1,410 bytes (70.15 %) Small (2 KB) 29,020.2 ns 8,236.0 ns 39,296.3 ns
ZLibCompressor 1,398 bytes (69.55 %) Small (2 KB) 29,594.6 ns 8,566.0 ns 39,190.3 ns
BrotliNETCompressor (deprecated) 1,494 bytes (74.33 %) Small (2 KB) 36,592.2 ns 26,640.5 ns 70,276.6 ns
ZstdSharpCompressor 1,687 bytes (83.93 %) Small (2 KB) 39,942.6 ns 1,565.4 ns 43,245.3 ns
LZMACompressor 1,337 bytes (66.52 %) Small (2 KB) 1,452,452.3 ns 241,164.4 ns 1,758,383.2 ns
Powered by https://github.com/mjebrahimi/BenchmarkDotNetVisualizer