pub trait IntoCudaIterator<'a> {
type Iter;
fn into_cuda_iter(&'a mut self, chunk_len: usize) -> Result<Self::Iter>;
}
Expand description
Conversion into a CUDA iterator.
By implementing IntoCudaIterator
for a type, you define how the type is
converted into an iterator capable of executing CUDA functions on a GPU.
The iterator must define a transfer strategy.
The chunk_len
parameter specifies the granularity of each data transfer
from main-memory to device memory. The same granularity is used when
passing input parameters to the GPU kernel.
Associated Types
Required methods
fn into_cuda_iter(&'a mut self, chunk_len: usize) -> Result<Self::Iter>
fn into_cuda_iter(&'a mut self, chunk_len: usize) -> Result<Self::Iter>
Creates an iterator from a value.
See the module-level documentation for details.
Implementations on Foreign Types
sourceimpl<'i, 'r, 's, R, S> IntoCudaIterator<'i> for (&'r mut UnifiedBuffer<R>, &'s mut UnifiedBuffer<S>) where
'r: 'i,
's: 'i,
R: Copy + DeviceCopy,
S: Copy + DeviceCopy,
impl<'i, 'r, 's, R, S> IntoCudaIterator<'i> for (&'r mut UnifiedBuffer<R>, &'s mut UnifiedBuffer<S>) where
'r: 'i,
's: 'i,
R: Copy + DeviceCopy,
S: Copy + DeviceCopy,
Converts a tuple of two mutable unified buffer references into a CUDA iterator.
The references must be mutable because the buffer should not be modified during the prefetching operation (as required by UnifiedBuffer::as_unified_ptr).