▲ | fpoling 3 days ago | |||||||||||||||||||||||||
On my laptop with Samsung PRO 990 SSD and Intel Core Ultra 7 165U CPU with 64G RAM under Debian 13: Read test via coping to RAM memory from LUKS-encrypted BTRFS against /tmp that is a standard RAM disk:
Write test:
Preparing RAM disk with zram compression to emulate zram:
Write test to lz4-compressed ZRAM:
Read test from lz4-compressed ZRAM:
So SSD with LUKS is 1.5 times faster than zram for read and 5 times faster than zram for write.Note without LUKS but native SSD encryption the speed of SSD will be at least 2 times faster. Also using recent kernel is important so LUKS uses CPU instructions for AES encryptions. Without that SSD under LUKS will be several times slower. | ||||||||||||||||||||||||||
▲ | vlovich123 2 days ago | parent | next [-] | |||||||||||||||||||||||||
I think this says more about the terrible memory bandwidth & limited compute of the Intel mobile CPUs than about the positive speed of SSDs. Here's an 13900K 64 GiB with a SN850X SSD LUKS encrypted ext4. On my machine RAM compression is still faster. There's also various overheads in this test that make it not a 100% representative sample although I'm not sure how big the divergence is (namely zram swap doesn't have a filesystem and it's deep within the memory management code and not using O_DIRECT). Basic memory bandwidth test:
Read test
$ dd if=random.bin of=/tmp/random.bin conv=fdatasync bs=10M iflag=direct oflag=direct
2500+0 records in
2500+0 records out
26214400000 bytes (26 GB, 24 GiB) copied, 9.09728 s, 2.9 GB/sWrite test
Not sure why that disk write test was suddenly so bad.
Write test to lz4-compressed ZRAM:
Read test:
| ||||||||||||||||||||||||||
| ||||||||||||||||||||||||||
▲ | man8alexd 3 days ago | parent | prev [-] | |||||||||||||||||||||||||
You are measuring sequential throughput with a block size of 10M. Swap I/O is random 4K pages (with default readahead 32K and clustered swapout 1M), with the read latency being the most important factor. | ||||||||||||||||||||||||||
|