Expand description
AccelRef<T, B> — backend-agnostic typed device pointer.
Each backend defines its own concrete buffer type
(cudarc::driver::CudaSlice<T> for CUDA, hip-sys slices for
ROCm, MTLBuffer for Metal, …). This module declares the
generation-validated wrapper contract every backend’s concrete
*Ref<T> type satisfies.
Backends that want to share more shape than this trait offers
are encouraged to ship a pub type AccelRef<T> = MyConcreteRef<T>;
re-export so application code can pattern-match on the concrete
type when needed.
Structs§
- AnyRef
- Marker struct so portable code can reference an
“abstract
AccelRef<T>” without committing to a backend. Concrete backends usually expose their own typedef (e.g.atomr_accel_cuda::GpuRef<T>).
Traits§
- Accel
Ref - Trait implemented by every backend’s typed-pointer wrapper.