pub struct MlxCudaKernelConfig(/* private fields */);Expand description
Owned MLX-C CUDA kernel configuration handle.
Implementations§
Source§impl MlxCudaKernelConfig
impl MlxCudaKernelConfig
Sourcepub fn add_output(
&mut self,
shape: &[i32],
dtype: MlxDtype,
) -> Result<(), MlxCError>
pub fn add_output( &mut self, shape: &[i32], dtype: MlxDtype, ) -> Result<(), MlxCError>
Adds one typed output with a static shape.
Sourcepub fn set_grid(&mut self, grid: [i32; 3]) -> Result<(), MlxCError>
pub fn set_grid(&mut self, grid: [i32; 3]) -> Result<(), MlxCError>
Sets the launch grid dimensions.
Sourcepub fn set_thread_group(
&mut self,
thread_group: [i32; 3],
) -> Result<(), MlxCError>
pub fn set_thread_group( &mut self, thread_group: [i32; 3], ) -> Result<(), MlxCError>
Sets the thread-group dimensions.
Sourcepub fn set_init_value(&mut self, initial_value: f32) -> Result<(), MlxCError>
pub fn set_init_value(&mut self, initial_value: f32) -> Result<(), MlxCError>
Sets the scalar initialization value for output buffers.
Sourcepub fn set_verbose(&mut self, verbose: bool) -> Result<(), MlxCError>
pub fn set_verbose(&mut self, verbose: bool) -> Result<(), MlxCError>
Toggles MLX’s verbose logging for this kernel launch.
Sourcepub fn add_dtype_template_argument(
&mut self,
name: &str,
dtype: MlxDtype,
) -> Result<(), MlxCError>
pub fn add_dtype_template_argument( &mut self, name: &str, dtype: MlxDtype, ) -> Result<(), MlxCError>
Adds a dtype template argument.
Trait Implementations§
Source§impl Debug for MlxCudaKernelConfig
impl Debug for MlxCudaKernelConfig
Source§impl Drop for MlxCudaKernelConfig
impl Drop for MlxCudaKernelConfig
Auto Trait Implementations§
impl !Send for MlxCudaKernelConfig
impl !Sync for MlxCudaKernelConfig
impl Freeze for MlxCudaKernelConfig
impl RefUnwindSafe for MlxCudaKernelConfig
impl Unpin for MlxCudaKernelConfig
impl UnsafeUnpin for MlxCudaKernelConfig
impl UnwindSafe for MlxCudaKernelConfig
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