pub struct RoundPipeline<const STAGES: usize>where
W<STAGES>: BitWidth,{ /* private fields */ }Expand description
Registered prefix of the BLAKE3 compression pipeline.
Only STAGES = 28 produces complete BLAKE3 output. Smaller specializations
exist for bounded lowering and RTL-equivalence tests; they return XORs of
incomplete working states and must not be used as a hash. The complete
specialization is CompressionPipeline.
The initiation interval is one cycle, with STAGES registered transfers
of latency. Data and tags do not reset. Synchronous reset clears all valid
bits and therefore flushes every in-flight token.
stage 0 stage 1 stage 2 stage 3 stage 27
init+phase 0 ─▶ phase 1 ─▶ phase 2 ─▶ phase 3 ─▶ ... ─▶ phase 3 ─▶ feed_forward ─▶ output
(reg) (reg) (reg) (reg) (reg) (no register)
tag, valid: copied one stage per clock beside the data#[rhdl(dq_no_prefix)] names the generated input/output bundles plain
D and Q (instead of RoundPipelineD/RoundPipelineQ); the kernel
below uses those names.
Trait Implementations§
Source§impl<const STAGES: usize> Clone for RoundPipeline<STAGES>where
W<STAGES>: BitWidth,
impl<const STAGES: usize> Clone for RoundPipeline<STAGES>where
W<STAGES>: BitWidth,
Source§fn clone(&self) -> RoundPipeline<STAGES>
fn clone(&self) -> RoundPipeline<STAGES>
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl<const STAGES: usize> Debug for RoundPipeline<STAGES>where
W<STAGES>: BitWidth,
impl<const STAGES: usize> Debug for RoundPipeline<STAGES>where
W<STAGES>: BitWidth,
Source§impl<const STAGES: usize> Default for RoundPipeline<STAGES>where
W<STAGES>: BitWidth,
Build a pipeline of STAGES stages, checking that STAGES is legal.
impl<const STAGES: usize> Default for RoundPipeline<STAGES>where
W<STAGES>: BitWidth,
Build a pipeline of STAGES stages, checking that STAGES is legal.
Source§impl<const STAGES: usize> Synchronous for RoundPipeline<STAGES>where
W<STAGES>: BitWidth,
impl<const STAGES: usize> Synchronous for RoundPipeline<STAGES>where
W<STAGES>: BitWidth,
Source§type S = (<RoundPipeline<STAGES> as SynchronousDQ>::Q, <[DFF<RoundState>; STAGES] as Synchronous>::S, <[DFF<Bits<32>>; STAGES] as Synchronous>::S, <[DFF<bool>; STAGES] as Synchronous>::S)
type S = (<RoundPipeline<STAGES> as SynchronousDQ>::Q, <[DFF<RoundState>; STAGES] as Synchronous>::S, <[DFF<Bits<32>>; STAGES] as Synchronous>::S, <[DFF<bool>; STAGES] as Synchronous>::S)
PartialEq and Clone. It holds whatever
state is needed to compute the output of the circuit given it’s input.
This state is typically auto-derived by the Synchronous derive macro,
and it’s typically a struct containing the states of all the subcircuits,
along with their last know outputs.Source§fn init(&self) -> Self::S
fn init(&self) -> Self::S
Synchronous derive macro,
and it typically initializes the states of all the subcircuits to their
initial states.Source§fn children(
&self,
parent_scope: &ScopedName,
) -> impl Iterator<Item = Result<Descriptor<SyncKind>, RHDLError>>
fn children( &self, parent_scope: &ScopedName, ) -> impl Iterator<Item = Result<Descriptor<SyncKind>, RHDLError>>
Source§fn sim(
&self,
clock_reset: ClockReset,
input: <Self as SynchronousIO>::I,
state: &mut Self::S,
) -> <Self as SynchronousIO>::O
fn sim( &self, clock_reset: ClockReset, input: <Self as SynchronousIO>::I, state: &mut Self::S, ) -> <Self as SynchronousIO>::O
§fn descriptor(
&self,
scoped_name: ScopedName,
) -> Result<Descriptor<SyncKind>, RHDLError>
fn descriptor( &self, scoped_name: ScopedName, ) -> Result<Descriptor<SyncKind>, RHDLError>
Source§impl<const STAGES: usize> SynchronousDQ for RoundPipeline<STAGES>where
W<STAGES>: BitWidth,
impl<const STAGES: usize> SynchronousDQ for RoundPipeline<STAGES>where
W<STAGES>: BitWidth,
Source§impl<const STAGES: usize> SynchronousIO for RoundPipeline<STAGES>where
W<STAGES>: BitWidth,
Ports of RoundPipeline: one request in, one result out per clock.
impl<const STAGES: usize> SynchronousIO for RoundPipeline<STAGES>where
W<STAGES>: BitWidth,
Ports of RoundPipeline: one request in, one result out per clock.
Auto Trait Implementations§
impl<const STAGES: usize> Freeze for RoundPipeline<STAGES>
impl<const STAGES: usize> RefUnwindSafe for RoundPipeline<STAGES>
impl<const STAGES: usize> Send for RoundPipeline<STAGES>
impl<const STAGES: usize> Sync for RoundPipeline<STAGES>
impl<const STAGES: usize> Unpin for RoundPipeline<STAGES>
impl<const STAGES: usize> UnsafeUnpin for RoundPipeline<STAGES>
impl<const STAGES: usize> UnwindSafe for RoundPipeline<STAGES>
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
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>
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>
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<D> OwoColorize for D
impl<D> OwoColorize for D
§fn fg<C>(&self) -> FgColorDisplay<'_, C, Self>where
C: Color,
fn fg<C>(&self) -> FgColorDisplay<'_, C, Self>where
C: Color,
§fn bg<C>(&self) -> BgColorDisplay<'_, C, Self>where
C: Color,
fn bg<C>(&self) -> BgColorDisplay<'_, C, Self>where
C: Color,
§fn on_magenta(&self) -> BgColorDisplay<'_, Magenta, Self>
fn on_magenta(&self) -> BgColorDisplay<'_, Magenta, Self>
§fn default_color(&self) -> FgColorDisplay<'_, Default, Self>
fn default_color(&self) -> FgColorDisplay<'_, Default, Self>
§fn on_default_color(&self) -> BgColorDisplay<'_, Default, Self>
fn on_default_color(&self) -> BgColorDisplay<'_, Default, Self>
§fn bright_black(&self) -> FgColorDisplay<'_, BrightBlack, Self>
fn bright_black(&self) -> FgColorDisplay<'_, BrightBlack, Self>
§fn on_bright_black(&self) -> BgColorDisplay<'_, BrightBlack, Self>
fn on_bright_black(&self) -> BgColorDisplay<'_, BrightBlack, Self>
§fn bright_red(&self) -> FgColorDisplay<'_, BrightRed, Self>
fn bright_red(&self) -> FgColorDisplay<'_, BrightRed, Self>
§fn on_bright_red(&self) -> BgColorDisplay<'_, BrightRed, Self>
fn on_bright_red(&self) -> BgColorDisplay<'_, BrightRed, Self>
§fn bright_green(&self) -> FgColorDisplay<'_, BrightGreen, Self>
fn bright_green(&self) -> FgColorDisplay<'_, BrightGreen, Self>
§fn on_bright_green(&self) -> BgColorDisplay<'_, BrightGreen, Self>
fn on_bright_green(&self) -> BgColorDisplay<'_, BrightGreen, Self>
§fn bright_yellow(&self) -> FgColorDisplay<'_, BrightYellow, Self>
fn bright_yellow(&self) -> FgColorDisplay<'_, BrightYellow, Self>
§fn on_bright_yellow(&self) -> BgColorDisplay<'_, BrightYellow, Self>
fn on_bright_yellow(&self) -> BgColorDisplay<'_, BrightYellow, Self>
§fn bright_blue(&self) -> FgColorDisplay<'_, BrightBlue, Self>
fn bright_blue(&self) -> FgColorDisplay<'_, BrightBlue, Self>
§fn on_bright_blue(&self) -> BgColorDisplay<'_, BrightBlue, Self>
fn on_bright_blue(&self) -> BgColorDisplay<'_, BrightBlue, Self>
§fn bright_magenta(&self) -> FgColorDisplay<'_, BrightMagenta, Self>
fn bright_magenta(&self) -> FgColorDisplay<'_, BrightMagenta, Self>
§fn on_bright_magenta(&self) -> BgColorDisplay<'_, BrightMagenta, Self>
fn on_bright_magenta(&self) -> BgColorDisplay<'_, BrightMagenta, Self>
§fn bright_purple(&self) -> FgColorDisplay<'_, BrightMagenta, Self>
fn bright_purple(&self) -> FgColorDisplay<'_, BrightMagenta, Self>
§fn on_bright_purple(&self) -> BgColorDisplay<'_, BrightMagenta, Self>
fn on_bright_purple(&self) -> BgColorDisplay<'_, BrightMagenta, Self>
§fn bright_cyan(&self) -> FgColorDisplay<'_, BrightCyan, Self>
fn bright_cyan(&self) -> FgColorDisplay<'_, BrightCyan, Self>
§fn on_bright_cyan(&self) -> BgColorDisplay<'_, BrightCyan, Self>
fn on_bright_cyan(&self) -> BgColorDisplay<'_, BrightCyan, Self>
§fn bright_white(&self) -> FgColorDisplay<'_, BrightWhite, Self>
fn bright_white(&self) -> FgColorDisplay<'_, BrightWhite, Self>
§fn on_bright_white(&self) -> BgColorDisplay<'_, BrightWhite, Self>
fn on_bright_white(&self) -> BgColorDisplay<'_, BrightWhite, Self>
§fn blink_fast(&self) -> BlinkFastDisplay<'_, Self>
fn blink_fast(&self) -> BlinkFastDisplay<'_, Self>
§fn strikethrough(&self) -> StrikeThroughDisplay<'_, Self>
fn strikethrough(&self) -> StrikeThroughDisplay<'_, Self>
§fn color<Color>(&self, color: Color) -> FgDynColorDisplay<'_, Color, Self>where
Color: DynColor,
fn color<Color>(&self, color: Color) -> FgDynColorDisplay<'_, Color, Self>where
Color: DynColor,
OwoColorize::fg] or
a color-specific method, such as [OwoColorize::green], Read more§fn on_color<Color>(&self, color: Color) -> BgDynColorDisplay<'_, Color, Self>where
Color: DynColor,
fn on_color<Color>(&self, color: Color) -> BgDynColorDisplay<'_, Color, Self>where
Color: DynColor,
OwoColorize::bg] or
a color-specific method, such as [OwoColorize::on_yellow], Read more