pub struct RocmResidentStorage { /* private fields */ }Expand description
Resident storage for a ROCm matmul result.
Implementations§
Source§impl RocmResidentStorage
impl RocmResidentStorage
Sourcepub fn new(
site: Symbol,
allocation: RocmAllocation,
shape: Vec<usize>,
dtype: Symbol,
cells: Arc<[Value]>,
) -> Self
pub fn new( site: Symbol, allocation: RocmAllocation, shape: Vec<usize>, dtype: Symbol, cells: Arc<[Value]>, ) -> Self
Builds resident ROCm storage around checked host-equivalent cells.
Sourcepub fn allocation(&self) -> &RocmAllocation
pub fn allocation(&self) -> &RocmAllocation
Returns the resident allocation evidence.
Sourcepub fn resident_tensor(&self) -> Option<Tensor>
pub fn resident_tensor(&self) -> Option<Tensor>
Rebuilds a canonical tensor without counting a user readback.
Trait Implementations§
Source§impl TensorStorage for RocmResidentStorage
impl TensorStorage for RocmResidentStorage
Source§fn location(&self) -> TensorLocation
fn location(&self) -> TensorLocation
The current storage placement.
Source§fn materialize(&self) -> Result<Arc<dyn TensorStorage>>
fn materialize(&self) -> Result<Arc<dyn TensorStorage>>
Returns a host-observable form of this storage. Read more
Auto Trait Implementations§
impl !Freeze for RocmResidentStorage
impl !RefUnwindSafe for RocmResidentStorage
impl !UnwindSafe for RocmResidentStorage
impl Send for RocmResidentStorage
impl Sync for RocmResidentStorage
impl Unpin for RocmResidentStorage
impl UnsafeUnpin for RocmResidentStorage
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more