Compressed swap is a common lever to improve memory density, but there's a lot of confusion about how to best use it out there, and many people treat zram/zswap as two flavours of the same thing when they are really far more nuanced.

So what works, what doesn't, and why? In this article I go over the tradeoffs, the work we are doing upstream, and a little about what the future looks like. I am, as always, happy to answer questions :-)

https://chrisdown.name/2026/03/24/zswap-vs-zram-when-to-use-what.html

Debunking zswap and zram myths

zswap and zram are fundamentally different approaches with different philosophies. If in doubt, use zswap.

@cdown does use of zswap interfere with use of hibernation?

@jernej Yes! zswap works nicely with hibernation since it requires a disk-backed swap device anyway. In the zswap case, the same backing device is where the hibernation image goes. The zswap pool lives in RAM and is captured as part of the hibernation image, so nothing is lost.

Hibernating to swap on zram on the other hand is explicitly not supported, and logind (for example) actively blocks attempts to do so.

So zswap is actually the better choice if you care about hibernation.