pub struct Measurement {
pub product: Block,
pub sum: Block,
pub multiply_add_latency: usize,
pub multiply_add: Rounding,
}Expand description
What the card said of its block: each mode’s semantics and depths, the multiply-add’s latency and rounding.
Fields§
§product: Block§sum: Block§multiply_add_latency: usize§multiply_add: RoundingImplementations§
Source§impl Measurement
impl Measurement
Sourcepub fn read(oracle: &Oracle, json: &str) -> Result<Measurement, MeasureError>
pub fn read(oracle: &Oracle, json: &str) -> Result<Measurement, MeasureError>
The block the oracle’s measurement (the host program’s JSON, super::fp_oracle::HOST_PROGRAM) names for
oracle: each mode’s one class with no difference over the vectors and both streams, its first member’s
semantics, the latencies measured; and the multiply-add’s rounding from its vectors whose C is the product
rounded and negated, read once rounded as the product’s error and twice rounded as zero.
Sourcepub fn read_multiply_add(json: &str) -> Result<(usize, Rounding), MeasureError>
pub fn read_multiply_add(json: &str) -> Result<(usize, Rounding), MeasureError>
The multiply-add alone: its depth and how it rounds, whatever either block named.
Sourcepub fn read_product(oracle: &Oracle, json: &str) -> Result<Block, MeasureError>
pub fn read_product(oracle: &Oracle, json: &str) -> Result<Block, MeasureError>
The multiply’s block alone: its one agreeing class and its depths, whatever the add named.
Sourcepub fn read_sum(oracle: &Oracle, json: &str) -> Result<Block, MeasureError>
pub fn read_sum(oracle: &Oracle, json: &str) -> Result<Block, MeasureError>
The add’s block alone: its one agreeing class and its depths, whatever the multiply named.
Sourcepub fn read_tally(
oracle: &Oracle,
json: &str,
op: Op,
) -> Result<Tally, MeasureError>
pub fn read_tally( oracle: &Oracle, json: &str, op: Op, ) -> Result<Tally, MeasureError>
One mode’s counts alone, whatever its classes name.
Sourcepub fn read_depths(json: &str, op: Op) -> Result<(usize, usize), MeasureError>
pub fn read_depths(json: &str, op: Op) -> Result<(usize, usize), MeasureError>
One mode’s depths alone, fully registered and with its output register alone.
Trait Implementations§
Source§impl Clone for Measurement
impl Clone for Measurement
Source§fn clone(&self) -> Measurement
fn clone(&self) -> Measurement
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for Measurement
impl Debug for Measurement
Source§impl PartialEq for Measurement
impl PartialEq for Measurement
impl Copy for Measurement
impl Eq for Measurement
impl StructuralPartialEq for Measurement
Auto Trait Implementations§
impl Freeze for Measurement
impl RefUnwindSafe for Measurement
impl Send for Measurement
impl Sync for Measurement
impl Unpin for Measurement
impl UnsafeUnpin for Measurement
impl UnwindSafe for Measurement
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,
§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>. Box<dyn Any> can
then be further downcast into Box<ConcreteType> where ConcreteType implements Trait.§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Rc<Trait> (where Trait: Downcast) to Rc<Any>. Rc<Any> can then be
further downcast into Rc<ConcreteType> where ConcreteType implements Trait.§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.§impl<T> DowncastSync for T
impl<T> DowncastSync for T
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.