pub struct KernelConfig {
pub grid: [usize; 3],
pub threadgroup: [usize; 3],
pub template: Vec<(String, TemplateArg)>,
pub init_value: Option<f64>,
}Expand description
How a MetalKernel is launched.
Fields§
§grid: [usize; 3]Threads in the grid, [x, y, z].
threadgroup: [usize; 3]Threads per threadgroup, [x, y, z] (at most 1,024 in all).
template: Vec<(String, TemplateArg)>Template arguments, by name.
init_value: Option<f64>A value every output holds before the kernel runs (else they are uninitialised).
Trait Implementations§
Source§impl Clone for KernelConfig
impl Clone for KernelConfig
Source§impl Debug for KernelConfig
impl Debug for KernelConfig
Source§impl Default for KernelConfig
impl Default for KernelConfig
Source§impl PartialEq for KernelConfig
impl PartialEq for KernelConfig
impl StructuralPartialEq for KernelConfig
Auto Trait Implementations§
impl Freeze for KernelConfig
impl RefUnwindSafe for KernelConfig
impl Send for KernelConfig
impl Sync for KernelConfig
impl Unpin for KernelConfig
impl UnsafeUnpin for KernelConfig
impl UnwindSafe for KernelConfig
Blanket Implementations§
impl<T> AutoreleaseSafe for Twhere
T: ?Sized,
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more