Meta Developing Compressed RAM "CRAM" For Linux

Updated

Meta is developing a new Linux memory compression mechanism called CRAM (Compressed RAM), which was presented by Meta engineer Gregory Price at the Linux Plumbers Conference in Prague in October 2026.

Key Features and Advantages

  • Hardware-Offloaded Compression: Unlike existing software-based solutions like ZRAM and Zswap, which require the CPU to decompress data before it can be accessed, CRAM offloads compression to hardware.
  • Byte-Level/Cache-Line Access: A standout feature of CRAM is that it preserves byte-level and cache-line access to compressed memory. Data can be read directly as if it were uncompressed, eliminating the need to decompress entire pages into regular memory before access.
  • Performance: CRAM aims to deliver performance near that of raw DRAM. In tests, read-only data achieved speeds close to raw DRAM, and write performance was noted to be significantly faster than ZRAM, Zswap, and standard swap.
  • Capacity Management: To handle fluctuating compression ratios, CRAM uses a "ballooning" mechanism that dynamically adjusts the amount of memory available to the operating system. This helps ensure the system does not exceed its actual physical capacity.

Current Status

  • Development Stage: CRAM is currently a proposal to the community and not yet a finished product.
  • Upstreaming: Most of the necessary kernel components to support CRAM are already present in the mainline Linux kernel, meaning the project is focused on assembling and refining these pieces rather than building from scratch. However, the feature is not yet fully upstreamed, and no specific timeline for its inclusion in the mainline kernel has been provided.