pub struct GhashSqSlicedWideMul<T>(/* private fields */);Expand description
WideMul strategy for PackedGhashSq1x256b keeping the three Karatsuba products of the
coordinate multiply separate, so that the multiply-by-X can be deferred into a reduction.
Trait Implementations§
Source§impl<T> TransparentWrapper<T> for GhashSqSlicedWideMul<T>
impl<T> TransparentWrapper<T> for GhashSqSlicedWideMul<T>
§fn wrap_ref(s: &Inner) -> &Self
fn wrap_ref(s: &Inner) -> &Self
Convert a reference to the inner type into a reference to the wrapper
type.
§fn wrap_mut(s: &mut Inner) -> &mut Self
fn wrap_mut(s: &mut Inner) -> &mut Self
Convert a mutable reference to the inner type into a mutable reference to
the wrapper type.
§fn wrap_slice(s: &[Inner]) -> &[Self]where
Self: Sized,
fn wrap_slice(s: &[Inner]) -> &[Self]where
Self: Sized,
Convert a slice to the inner type into a slice to the wrapper type.
§fn wrap_slice_mut(s: &mut [Inner]) -> &mut [Self]where
Self: Sized,
fn wrap_slice_mut(s: &mut [Inner]) -> &mut [Self]where
Self: Sized,
Convert a mutable slice to the inner type into a mutable slice to the
wrapper type.
§fn peel_ref(s: &Self) -> &Inner
fn peel_ref(s: &Self) -> &Inner
Convert a reference to the wrapper type into a reference to the inner
type.
§fn peel_mut(s: &mut Self) -> &mut Inner
fn peel_mut(s: &mut Self) -> &mut Inner
Convert a mutable reference to the wrapper type into a mutable reference
to the inner type.
§fn peel_slice(s: &[Self]) -> &[Inner]where
Self: Sized,
fn peel_slice(s: &[Self]) -> &[Inner]where
Self: Sized,
Convert a slice to the wrapped type into a slice to the inner type.
§fn peel_slice_mut(s: &mut [Self]) -> &mut [Inner]where
Self: Sized,
fn peel_slice_mut(s: &mut [Self]) -> &mut [Inner]where
Self: Sized,
Convert a mutable slice to the wrapped type into a mutable slice to the
inner type.
Source§impl WideMul for GhashSqSlicedWideMul<PackedGhashSq1x256b>
impl WideMul for GhashSqSlicedWideMul<PackedGhashSq1x256b>
Source§fn wide_mul(a: Self, b: Self) -> Self::Output
fn wide_mul(a: Self, b: Self) -> Self::Output
Karatsuba over Y: defers the three GHASH products a·e, b·f, (a+b)·(e+f).
Source§fn reduce(wide: Self::Output) -> Self
fn reduce(wide: Self::Output) -> Self
Folds Y² = X·Y + X, recovering the Karatsuba cross term as t₁ + t₀ + t₂:
z₀ = t₀ + X·t₂ and z₁ = (t₁ + t₀ + t₂) + X·t₂ = z₀ + t₁ + t₂.
Scaling t₂ by X while it is still unreduced turns z₀ into a single reduction of an
accumulated wide product, so the two coordinates cost two reductions in total.
type Output = SlicedGhashSqWide<<BinaryField128bGhash as WideMul>::Output>
Auto Trait Implementations§
impl<T> Freeze for GhashSqSlicedWideMul<T>where
T: Freeze,
impl<T> RefUnwindSafe for GhashSqSlicedWideMul<T>where
T: RefUnwindSafe,
impl<T> Send for GhashSqSlicedWideMul<T>where
T: Send,
impl<T> Sync for GhashSqSlicedWideMul<T>where
T: Sync,
impl<T> Unpin for GhashSqSlicedWideMul<T>where
T: Unpin,
impl<T> UnsafeUnpin for GhashSqSlicedWideMul<T>where
T: UnsafeUnpin,
impl<T> UnwindSafe for GhashSqSlicedWideMul<T>where
T: UnwindSafe,
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
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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§impl<T> Pointable for T
impl<T> Pointable for T
§impl<I, T> TransparentWrapperAlloc<I> for T
impl<I, T> TransparentWrapperAlloc<I> for T
§fn wrap_vec(s: Vec<Inner>) -> Vec<Self>where
Self: Sized,
fn wrap_vec(s: Vec<Inner>) -> Vec<Self>where
Self: Sized,
Convert a vec of the inner type into a vec of the wrapper type.
§fn wrap_box(s: Box<Inner>) -> Box<Self>
fn wrap_box(s: Box<Inner>) -> Box<Self>
Convert a box to the inner type into a box to the wrapper
type.
§fn wrap_rc(s: Rc<Inner>) -> Rc<Self>
fn wrap_rc(s: Rc<Inner>) -> Rc<Self>
Convert an
Rc to the inner type into an Rc to the wrapper type.§fn wrap_arc(s: Arc<Inner>) -> Arc<Self>
fn wrap_arc(s: Arc<Inner>) -> Arc<Self>
Convert an
Arc to the inner type into an Arc to the wrapper type.§fn peel_vec(s: Vec<Self>) -> Vec<Inner>where
Self: Sized,
fn peel_vec(s: Vec<Self>) -> Vec<Inner>where
Self: Sized,
Convert a vec of the wrapper type into a vec of the inner type.
§fn peel_box(s: Box<Self>) -> Box<Inner>
fn peel_box(s: Box<Self>) -> Box<Inner>
Convert a box to the wrapper type into a box to the inner
type.