pub struct DiskAllocator { /* private fields */ }Expand description
DISK allocator using memory-mapped files (Tinygrad: ops_disk.py). Read-only — cannot execute kernels. Data is transferred via COPY.
Implementations§
Trait Implementations§
Source§impl Allocator for DiskAllocator
impl Allocator for DiskAllocator
fn alloc(&self, size: usize, _options: &BufferOptions) -> Result<RawBuffer>
fn name(&self) -> &str
Source§fn device_spec(&self) -> DeviceSpec
fn device_spec(&self) -> DeviceSpec
Get the device specification for this allocator.
fn free(&self, _buffer: RawBuffer, _options: &BufferOptions)
fn synchronize(&self) -> Result<()>
Source§impl Clone for DiskAllocator
impl Clone for DiskAllocator
Source§fn clone(&self) -> DiskAllocator
fn clone(&self) -> DiskAllocator
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for DiskAllocator
impl RefUnwindSafe for DiskAllocator
impl Send for DiskAllocator
impl Sync for DiskAllocator
impl Unpin for DiskAllocator
impl UnsafeUnpin for DiskAllocator
impl UnwindSafe for DiskAllocator
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