|
Uni20
Asynchronous tensor and runtime library.
|
RAII leases that resolve device descriptors and tensor views to mdspans. More...
#include <uni20/common/trace.hpp>#include <uni20/tensor/concepts.hpp>#include <concepts>#include <cstddef>#include <optional>#include <type_traits>#include <utility>Go to the source code of this file.
Classes | |
| class | uni20::read_mdspan_lease< Mdspan, AccessState > |
| Move-only RAII lease exposing one resolved read-only mdspan. More... | |
| class | uni20::read_tensor_lease< Mdspan, AccessState, BackendSelector, StoragePolicy > |
| Move-only RAII lease exposing a read-only ImmediateTensorView. More... | |
| class | uni20::ready_access< Lease > |
| Always-ready awaitable that transfers one access lease. More... | |
| class | uni20::write_mdspan_lease< Mdspan, AccessState > |
| Move-only RAII lease exposing one resolved writable mdspan. More... | |
| class | uni20::write_tensor_lease< MutableMdspan, ConstMdspan, AccessState, BackendSelector, StoragePolicy > |
| Move-only RAII lease exposing mutable and const immediate TensorViews. More... | |
Namespaces | |
| namespace | uni20 |
Concepts | |
| concept | uni20::TensorAccessState |
| Movable state retaining one acquired tensor data-handle lifetime. | |
| concept | uni20::ReadMdspanLease |
| Move-only lease exposing a resolved read-only mdspan. | |
| concept | uni20::WriteMdspanLease |
| Move-only lease exposing a resolved writable mdspan. | |
| concept | uni20::HostReadMdspanLease |
| Read mdspan lease whose resolved accessor is valid in host code. | |
| concept | uni20::HostWriteMdspanLease |
| Write mdspan lease whose resolved accessor is valid in host code. | |
| concept | uni20::CudaReadMdspanLease |
| Read mdspan lease whose resolved accessor is valid in CUDA code. | |
| concept | uni20::CudaWriteMdspanLease |
| Write mdspan lease whose resolved accessor is valid in CUDA code. | |
| concept | uni20::ReadTensorLease |
| ImmediateTensorView that owns a move-only read access lifetime. | |
| concept | uni20::WriteTensorLease |
| MutableImmediateTensorView that owns a move-only write access lifetime. | |
| concept | uni20::HostReadTensorLease |
| Read lease whose resolved mdspan is directly host-accessible. | |
| concept | uni20::HostWriteTensorLease |
| Write lease whose resolved mutable mdspan is directly host-accessible. | |
| concept | uni20::CudaReadTensorLease |
| Read lease whose resolved mdspan is directly CUDA-accessible. | |
| concept | uni20::CudaWriteTensorLease |
| Write lease whose resolved mutable mdspan is directly CUDA-accessible. | |
| concept | uni20::HostReadableMdspec |
| Mdspec metadata supporting host read acquisition. | |
| concept | uni20::HostWritableMdspec |
| Mutable mdspec metadata supporting host write acquisition. | |
| concept | uni20::HostReadableTensor |
| Tensor view supporting host read acquisition. | |
| concept | uni20::HostWritableTensor |
| Mutable tensor view supporting host write acquisition. | |
Typedefs | |
| template<class Mdspec > | |
| using | uni20::host_read_mdspan_t = std::remove_cvref_t< decltype(std::declval< detail::host_read_mdspan_lease_t< Mdspec > & >().mdspan())> |
| Read-only mdspan type resolved by host descriptor acquisition. | |
| template<class Tensor > | |
| using | uni20::host_read_tensor_mdspan_t = std::remove_cvref_t< decltype(std::declval< detail::host_read_tensor_lease_t< Tensor > & >().mdspan())> |
| Read-only mdspan type resolved by host tensor acquisition. | |
| template<class Mdspec > | |
| using | uni20::host_write_mdspan_t = std::remove_cvref_t< decltype(std::declval< detail::host_write_mdspan_lease_t< Mdspec > & >().mdspan())> |
| Writable mdspan type resolved by host descriptor acquisition. | |
| template<class Tensor > | |
| using | uni20::host_write_tensor_mdspan_t = std::remove_cvref_t< decltype(std::declval< detail::host_write_tensor_lease_t< Tensor > & >().mdspan())> |
| Writable mdspan type resolved by host tensor acquisition. | |
Functions | |
| template<ImmediateTensorView Tensor> requires HostAccessibleMdspan<immediate_tensor_mdspan_t<Tensor>> | |
| auto | uni20::acquire_host_read_access_async (Tensor &tensor) |
| Return an immediately-ready host read acquisition. | |
| template<HostAccessibleMdspan Mdspan> requires std::is_const_v<typename std::remove_cvref_t<Mdspan>::element_type> | |
| auto | uni20::acquire_host_read_access_sync (Mdspan const &mdspan) |
| Acquire a directly host-accessible read-only mdspan. | |
| template<ImmediateTensorView Tensor> requires HostAccessibleMdspan<immediate_tensor_mdspan_t<Tensor>> | |
| auto | uni20::acquire_host_read_access_sync (Tensor &tensor) |
| Acquire an immediately host-accessible tensor view for read-only use. | |
| template<MutableImmediateTensorView Tensor> requires HostAccessibleMdspan<mutable_immediate_tensor_mdspan_t<Tensor>> | |
| auto | uni20::acquire_host_write_access_async (Tensor &tensor) |
| Return an immediately-ready host write acquisition. | |
| template<MutableMdspanLike Mdspan> requires HostAccessibleMdspan<Mdspan> | |
| auto | uni20::acquire_host_write_access_sync (Mdspan &mdspan) |
| Acquire a directly host-accessible writable mdspan. | |
| template<MutableImmediateTensorView Tensor> requires HostAccessibleMdspan<mutable_immediate_tensor_mdspan_t<Tensor>> | |
| auto | uni20::acquire_host_write_access_sync (Tensor &tensor) |
| Acquire an immediately host-accessible mutable tensor view. | |
RAII leases that resolve device descriptors and tensor views to mdspans.