Skip to content

Value Compression

XOR‑Delta

Metrics that change slowly — temperature, CPU %, latency — produce nearly identical IEEE 754 bit patterns. XOR‑Delta exploits this: XOR consecutive values, and most bits cancel out. The remaining handful of meaningful bits is all you need to store.

Two consecutive CPU readings like 50.0 and 51.0 are stored as 64-bit floats — but they share 57 of their 64 bits. XOR-Delta stores only the 7 bits that differ, plus a tiny header describing where those bits live. Most metric sequences compress to 2–14 bits per sample instead of 64.

The very first value is always stored as raw 64 bits. Compression applies from the second value onward.

① Choose a Signal

Pick a pattern and watch how temporal locality affects compression.

② XOR Visualization Table

For each value after the first, XOR it with the previous value to get only the bits that changed:

Each row shows a value XOR'd with its predecessor. Click any row to expand bit-level detail.

# Value XOR with prev Lead 0s Trail 0s Meaningful Encoding Cost

IEEE 754 float64 layout: 1 sign bit · 11 exponent bits · 52 fraction bits

③ Encoding Decision Tree

Based on the XOR result, the encoder picks the most efficient encoding:

Every value follows this flowchart. Click a table row above to highlight the path taken.

④ Bit Cost Profile

Each bar shows one value's encoding cost. Green = identical (1 bit), blue = window reuse, yellow = new window.

⑤ Compression Summary