Skip to main content

SHARD_CAPACITY

Constant SHARD_CAPACITY 

Source
pub const SHARD_CAPACITY: usize = 200;
Expand description

The number of entries per Inspect array shard.

In Inspect VMO format, the maximum allocation block size is Order 7 (2048 bytes). Subtracting an 8-byte block header and an 8-byte array metadata header leaves 2032 bytes for elements. For 64-bit entries (8 bytes each), a single array block can hold at most 254 slots ((2048 - 16) / 8 = 254). 200 is chosen as a round capacity safely under this limit so that each shard fits within a single max-order Inspect VMO block.