Skip to main content

Module buffer

Module buffer 

Source
Expand description

Buffer<T>: a typed, contiguous value buffer that is either owned (Arc<Vec<T>>, the volas-computed case) or borrows foreign memory zero-copy (e.g. an Arrow / NumPy buffer kept alive by a guard).

Reads go through a slice uniformly (Deref to [T]), so every kernel — which already takes &[T] — is unaffected by where the bytes live. Mutation is copy-on-write: a borrowed (or shared-owned) buffer materialises to a uniquely owned Vec on the first write (Buffer::make_mut). This is the foundation for zero-copy ingest, zero-copy slicing, and zero-copy export.

Enums§

Buffer
A typed contiguous buffer: owned or a zero-copy borrow of foreign memory.