Skip to main content

Module dlpack

Module dlpack 

Source
Expand description

DLPack interop for zero-copy GPU exchange.

This module provides a minimal DLPack implementation for exporting XLOG GPU buffers to other ecosystems (e.g., Python cuDF) without device↔host copies.

Structs§

DLDataType
DLDevice
DLManagedTensor
DLTensor
DlpackManagedTensor
Owned DLPack tensor handle.
DlpackTable
A table-like wrapper that can export individual columns as DLPack tensors without copies.

Constants§

K_DLBOOL
K_DLCPU
K_DLCUDA
K_DLFLOAT
K_DLINT
K_DLUINT

Functions§

export_slice_managed_tensor
Export an xlog-owned runtime-backed slice as a 2-D DLPack managed tensor without copies. The manager context holds the slice’s Arc, so the export shares the exact producer allocation and the memory stays alive until the consumer’s deleter runs; xlog remains the owner throughout. The declared rows x cols x dtype view must cover the allocation exactly — a mismatched shape is a typed error, never a truncated or padded view.

Type Aliases§

DLDataTypeCode
DLDeleter
DLDeviceType