Expand description
Driver-only CUDA host stack shared by speakrs and scriptrs
cudakit loads the NVIDIA driver (libcuda) at run time through cudarc and never
loads the CUDA Runtime (libcudart), so a build needs no CUDA toolkit and a
process needs only the driver. With the libraries feature, and only when the
consumer’s Profile allows it, cuBLAS, cuDNN and NVRTC are loaded lazily after a
symbol preflight.
Gpuowns one context and one stream, the device attributes and the optional library handlesRuntimeadds a module cache for a consumer’sKernelAreas: embedded PTX and exact-architecture cubins, loaded by exact identity (ModuleRequest)DeviceTensoris a shaped device bufferSgemmandSgemmBatcheddescribe row-major cuBLAS productsGpu::capturerecords stream work as a replayableGraphdnnplans cuDNN convolutions (featurelibraries)identityreads the driver release for persisted tuning identities
Kernels are written with cuda-oxide in each consumer’s own kernels crate and built
offline by cudakit-build; see the guide
Re-exports§
pub use cudarc;
Modules§
- dnn
libraries - cuDNN forward convolutions: one planner and one plan type for every model
- identity
- Driver releases for persisted identities, such as tune files, with API-only identities kept apart so they are never saved as a release
- symbols
- Library entry points that cudakit checks before cudarc loads a library
Macros§
- embed_
tier - Embeds one area variant under exactly the consumer features for which it is the best shipped PTX
Structs§
- AreaPtx
- The PTX variants of one area embedded by this build
- Artifact
Hash - Content identity of bytes embedded in the running binary
- Blas
Guard libraries - The shared cuBLAS handle in one math mode, from
Gpu::blas - Compute
Capability - A device compute capability, ordered by major then minor version
- Conv2d
- An NCHW 2-D convolution on FP32 buffers (cross-correlation, as in PyTorch
Conv2d) - Device
Attributes - Device facts queried once per
Gpu - Device
Attributes Builder test-support - Builds attributes for host-only tests in consumers
- Device
Tensor - A device buffer with a row-major shape
- Embedded
Cubin - One embedded binary, available only alongside its source PTX variant
- Embedded
Ptx - The PTX fallback and exact-architecture binaries for one tier of one area
- Extra
Symbols - Library entry points a consumer calls directly through cudarc, beyond the ones cudakit’s own wrappers reach
- Gpu
- One CUDA device context and stream, with optional libraries prepared on request
- Graph
- A recorded and instantiated sequence of work on one
Gpu’s stream - Library
Versions libraries - Versions of the loaded numerical libraries, for tune-file identities
- Loaded
Kernels - A kernel module loaded into a CUDA context
- Module
Request - A complete module identity, resolved before the driver sees any bytes
- Options
- How to open a
Runtime; consumers fill it from their own environment variables - Profile
- A consumer’s build-wide CUDA policy, declared once as a constant
- Runtime
- A
Gpuplus the kernel modules of one consumer’s areas - Sgemm
- A row-major GEMM on FP32 buffers:
c = alpha * op(a) · op(b) + beta * c - Sgemm
Batched batchindependentSgemmproducts whose operands sit at fixed element strides in three buffers, such as one product per attention head- TierSet
- A set of PTX tiers, usable in const context
Enums§
- Artifact
Load Error - Failure to load the requested artifact, without substituting another artifact
- Error
- Errors from cudakit
- Library
- A CUDA shared library that cudakit loads at run time
- Library
Policy - Whether a consumer may load optional numerical libraries
- Loaded
Artifact - The exact artifact accepted by the driver for a kernel area
- Math
- Arithmetic precision of cuBLAS and cuDNN work on FP32 data
- PtxTier
- A GPU generation that committed PTX can target
Traits§
- Kernel
Area - A consumer’s kernel areas: one cuda-oxide module each, embedded per PTX tier
Functions§
- check_
len - Checks that a buffer holds exactly the elements an operation reads or writes
- element_
count - Number of elements in a shape, failing on overflow
- load_
artifact - Load exactly the requested bytes; driver rejection never tries the other format
- to_
c_ int - Converts a dimension for a cuBLAS or cuDNN call
- unfold_
windows - Writes rows of
windowsamples cut out of a device span intotarget