For the complete documentation index, see llms.txt. Markdown versions of all pages are available by appending .md to any URL (e.g. /get-started.md).
Python function
padded_lut_cols
padded_lut_cols()
max.nn.kv_cache.padded_lut_cols(cols)
Rounds a page lookup-table inner dim up to a kernel-safe width.
Kept in lockstep with the invariant asserted in
max/kernels/src/kv_cache/types.mojo (PagedKVCache.populate):
lookup_table.dim[1] is a multiple of 8 and is at least
logical_cols + 15 so a 16-wide SIMD lookup load from any valid
first_lut_idx stays in-bounds.