Expand description
Thin, panic-safe wrappers around CUDA driver-API entry points
that cudarc 0.19 only exposes at the sys level.
Every function in this module wraps the raw unsafe extern "C"
call in std::panic::catch_unwind, because cudarc’s
dynamic-loader path panics if libcuda.so isn’t present at
runtime. The wrappers convert “library not loadable” panics into
crate::error::GpuError::Unrecoverable so kernel actors stay
alive on no-GPU hosts.
All pointer / handle arguments are forwarded as-is — the caller is responsible for validity.
Functions§
- ipc_
close_ mem_ handle - ipc_
get_ event_ handle - ipc_
get_ mem_ handle - ipc_
open_ event_ handle - ipc_
open_ mem_ handle_ v2 - launch_
cooperative_ kernel - launch_
kernel - mem_
advise_ v2 - Apply a memory advisory hint to a managed-memory range. Wraps
cuMemAdvise_v2(the v2 shape that takes aCUmemLocation). - mem_
prefetch_ async_ v2 - Prefetch
[dev_ptr .. dev_ptr+count)to a target memory location onstream. WrapscuMemPrefetchAsync_v2(the v2 shape that takes aCUmemLocation). - module_
get_ function - module_
load_ data - Load a cubin/fatbin/PTX image from a memory buffer. The buffer must
outlive the returned
CUmodulefor the duration of any pending kernel launch — the driver may keep references to embedded strings. - module_
unload - runtime_
ipc_ get_ mem_ handle