Skip to main content

Crate edgefirst_tensor_abi

Crate edgefirst_tensor_abi 

Source
Expand description

Layout-only C ABI contract for the EdgeFirst tensor surface.

Plain #[repr(C)] values and the integer vocabularies, declared exactly once. Every -capi crate imports these instead of carrying an “identical copy” — r2’s duplication was safe but unverified-by-construction; a single declaration makes divergence impossible instead of merely absent.

This crate has no dependencies and must never gain one. The vocabulary values are asserted against edgefirst-tensor’s authority from the crates that depend on both (see edgefirst-tensor-capi/src/codes.rs) — this crate is emitted surface, never a second authority.

Structs§

EfClientState
Client-owned state a library entry point calls back into — frozen by value, forever, and reused verbatim by every domain that needs one (PBO today; CUDA-GL next).
EfD3d11Layout
The D3D11 texture behind a Windows texture tensor.
EfImageDescView
Flattened, #[repr(C)] view of an image-request descriptor’s fields.
EfQuantizationInfo
Presence/shape summary of a tensor’s quantization metadata.
EfTensorPlane
One plane’s location, mirroring TensorPlane on the wire.
EfTensorView
A mapped CPU window over a tensor’s bytes.
EfViewOrigin
Parent-region snapshot for a tensor that is a view/batch sub-region.

Enums§

EfCompression
Vendor tile-compression scheme actually in force for a tensor’s allocation.
EfCompressionRequest
Compression request, as ef_tensor_image_desc_set_compression takes it and EfImageDescView::compression reports it.
EfContiguity
Whether a tensor’s memory is known to be physically contiguous (ef_tensor_contiguity).
EfCpuAccess
CPU access: a tensor’s declaration, or the direction of a map window.
EfDtype
Element type of a tensor’s addressing grid.
EfErrorClass
Which kind of failure the calling thread’s last failing ef_tensor_* call was.
EfStorageKind
Backing store for a tensor.

Type Aliases§

EfClientRefFn
A retain or release call on a client-owned callback context.
EfCudaMapFn
Map a CUDA graphics resource to a device pointer. 0 on success.
EfCudaMapFnNullable
Map a CUDA graphics resource to a device pointer. 0 on success.
EfCudaUnmapFn
Unmap a resource previously mapped by an EfCudaMapFn.
EfCudaUnmapFnNullable
Unmap a resource previously mapped by an ef_cuda_map_fn.
EfCudaUnregisterFn
Unregister a CUDA graphics resource.
EfCudaUnregisterFnNullable
Unregister a CUDA graphics resource.
EfPboMapFn
Map a PBO for CPU access. 0 on success; -1 when the GL context is gone; any other non-zero value a generic failure.
EfPboMapFnNullable
Map a PBO for CPU access. 0 on success; -1 when the GL context is gone; any other non-zero value a generic failure.
EfPboUnmapFn
Unmap a PBO previously mapped by an EfPboMapFn. Same return codes.
EfPboUnmapFnNullable
Unmap a PBO previously mapped by an ef_pbo_map_fn. Same return codes.