Skip to content

Posting revision 4: 0xE4

Revision 4 generalizes revision 3 from one integer key to a tuple of 2 to 8 integer fields.

SEAM 1 writers produce this revision only at store format 4 or higher, when nvars is 1 or 2, every key has the same 2 to 8 fields with tags in 0x03 to 0x05, all payloads are plain varints, and the block is smaller than the revision 2 block by at least one byte per entry.

The value starts with 0x00 and the next byte is 0xE4. See Block head.

After the common head:

Field Encoding Meaning
nvars u8, 1 or 2 number of payload variables per entry
nf u8, 2 to 8 number of fields in each key tuple
tags nf bytes one tag per field
keys, field 0 the keys section the first field, bit-split like revision 3
other fields nf - 1 times group(n) one integer group per remaining field
payloads nvars times group(n) one integer group per payload variable

The tuples must be ascending in tuple order; each key is nf fields of tag ‖ u64 BE, so a decoded key is nf * 9 bytes. Field 0 may repeat between neighbours. Decoders check widths, field ranges, strict ordering and the exact length (SPEC V731).

Keys can have several integer fields rather than one. The first field keeps the bit-split layout, and the others are plain integer groups.