From the linked comment Zswap appears to write decompressed pages to disk. I assume Chesterton's fence applies, but why not write them compressed to disk and decompress when/if they need to be loaded back?
> After the folio has been decompressed into the swap cache, the compressed version stored by zswap can be freed.
THIS. This boggles my mind ever since zswap landed in the kernel.
Actually, forget zswap. Why the fuck swap's on disk format hasn't been compressed in the last 2 decades when processing power has been abundant and compressors like lzo/lz4 has been in kernel tree.
> After the folio has been decompressed into the swap cache, the compressed version stored by zswap can be freed.
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/lin...