pub struct ElementwiseSpec<'a> {
pub count: u32,
pub inputs: &'a [Operand],
pub output: Operand,
pub dims: [u32; 6],
pub strides: &'a [[u32; 6]],
pub clamp: Option<[u32; 2]>,
}Expand description
Specialization payload of an elementwise dispatch. The declaration order in the elementwise
kernel is: count, each input operand, the output operand, then (broadcast
only) the output dims and each input’s element strides, then the clamp bounds.
Fields§
§count: u32§inputs: &'a [Operand]§output: Operand§dims: [u32; 6]Output shape padded with leading ones to MAX_RANK.
strides: &'a [[u32; 6]]Per input, element strides over dims (0 along a broadcast dimension).
clamp: Option<[u32; 2]>CLAMP bounds as FP32 bit patterns.
Implementations§
Trait Implementations§
Source§impl<'a> Clone for ElementwiseSpec<'a>
impl<'a> Clone for ElementwiseSpec<'a>
Source§impl<'a> Debug for ElementwiseSpec<'a>
impl<'a> Debug for ElementwiseSpec<'a>
impl<'a> Eq for ElementwiseSpec<'a>
Source§impl<'a> PartialEq for ElementwiseSpec<'a>
impl<'a> PartialEq for ElementwiseSpec<'a>
impl<'a> StructuralPartialEq for ElementwiseSpec<'a>
Auto Trait Implementations§
impl<'a> Freeze for ElementwiseSpec<'a>
impl<'a> RefUnwindSafe for ElementwiseSpec<'a>
impl<'a> Send for ElementwiseSpec<'a>
impl<'a> Sync for ElementwiseSpec<'a>
impl<'a> Unpin for ElementwiseSpec<'a>
impl<'a> UnsafeUnpin for ElementwiseSpec<'a>
impl<'a> UnwindSafe for ElementwiseSpec<'a>
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