pub struct Sha512Estimate {
pub lut: u32,
pub dsp: u32,
pub auto: bool,
}Expand description
Stand-in for the SHA-512 line (rhdl_sha512_pipelined’s component
replaces it): auto-sized to demand by default (at least one 5.5k-LUT
folded core), or by hand 0–432k LUTs and 0–20 DSPs.
Model: LUT / 87.2k blocks per clock, the Yosys cost of the full
pipeline and (per block) of the folded cores, continuous in between.
Fields§
§lut: u32LUT allowance, out of the chip budget (0..=432,000).
dsp: u32DSP allowance, out of the chip budget (0..=20). At 20 the DSP adder variant of the model applies.
auto: boolSized by the planner to what the chip wants, so the line never
limits it (the default); lut then shows the size it settled on.
Implementations§
Source§impl Sha512Estimate
Throughput model of the SHA-512 line.
impl Sha512Estimate
Throughput model of the SHA-512 line.
Sourcepub fn blocks_per_clock(&self) -> f64
pub fn blocks_per_clock(&self) -> f64
Modeled blocks per clock of the allowance.
Sourcepub fn blocks_per_clock_in(&self, lut: u32) -> f64
pub fn blocks_per_clock_in(&self, lut: u32) -> f64
Modeled blocks per clock of lut LUTs: LUTs divided by the
projected LUT cost of one block per clock.
Sourcepub fn largest_lut(&self) -> u32
pub fn largest_lut(&self) -> u32
How far the planner may grow the line past its allowance, out of LUTs no other module uses: 2 blocks per clock (an allowance above that is built as given).
Trait Implementations§
Source§impl Clone for Sha512Estimate
impl Clone for Sha512Estimate
Source§fn clone(&self) -> Sha512Estimate
fn clone(&self) -> Sha512Estimate
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Component for Sha512Estimate
Chip-planner interface of the SHA-512 line stand-in.
impl Component for Sha512Estimate
Chip-planner interface of the SHA-512 line stand-in.
Source§fn knobs(&self) -> Vec<Knob>
fn knobs(&self) -> Vec<Knob>
LUT allowance (0..=65,000 in steps of 1,000) and DSP allowance (0..=20).
Source§fn set_knob(&mut self, index: usize, value: f64)
fn set_knob(&mut self, index: usize, value: f64)
Applies a knob change: index 0 sets the LUT allowance (and makes the size manual), 1 the DSP allowance, 2 auto or manual.
Source§fn plan(&self, share: &Share, cx: &Context) -> Option<Plan>
fn plan(&self, share: &Share, cx: &Context) -> Option<Plan>
The line’s supply of SHA-512 blocks per second at the context’s
clock, or None when the allowance is zero (no line) or does not fit
share. In a share larger than the allowance (the planner lending
it LUTs nobody else uses) the line grows, up to
largest_lut.
Source§fn fixed(&self) -> Option<Share>
fn fixed(&self) -> Option<Share>
The allowance comes off the top of the budget (the SHA part of the LUT split) rather than from the power-weighted shares.
Source§fn size_for(&self, per_second: f64, cx: &Context) -> Option<Share>
fn size_for(&self, per_second: f64, cx: &Context) -> Option<Share>
Auto: the LUTs that hash per_second blocks at the clock (at least
the smallest core), or none when nothing is wanted.
Source§fn build_flags(&self, plan: &Plan) -> BuildFlags
fn build_flags(&self, plan: &Plan) -> BuildFlags
Compile-time settings: the LUTs the line was planned with (its allowance plus anything it grew into) and its DSPs.
None. The TUI shows
it instead of “nothing fits”.Source§impl Debug for Sha512Estimate
impl Debug for Sha512Estimate
Auto Trait Implementations§
impl Freeze for Sha512Estimate
impl RefUnwindSafe for Sha512Estimate
impl Send for Sha512Estimate
impl Sync for Sha512Estimate
impl Unpin for Sha512Estimate
impl UnsafeUnpin for Sha512Estimate
impl UnwindSafe for Sha512Estimate
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