pub struct KernelConfig {
pub block_size: (u32, u32, u32),
pub grid_size: (u32, u32, u32),
pub shared_memory_size: u32,
}
Expand description
Kernel configuration parameters
Fields§
§block_size: (u32, u32, u32)
§grid_size: (u32, u32, u32)
Implementations§
Source§impl KernelConfig
impl KernelConfig
Sourcepub fn for_matrix_multiply(rows: usize, cols: usize) -> Self
pub fn for_matrix_multiply(rows: usize, cols: usize) -> Self
Create optimal configuration for matrix multiplication
Sourcepub fn for_vector_operation(size: usize) -> Self
pub fn for_vector_operation(size: usize) -> Self
Create optimal configuration for vector operations
Trait Implementations§
Source§impl Clone for KernelConfig
impl Clone for KernelConfig
Source§fn clone(&self) -> KernelConfig
fn clone(&self) -> KernelConfig
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 KernelConfig
impl RefUnwindSafe for KernelConfig
impl Send for KernelConfig
impl Sync for KernelConfig
impl Unpin for KernelConfig
impl UnwindSafe for KernelConfig
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