Skip to main content

DelayCalculator

Trait DelayCalculator 

Source
pub trait DelayCalculator {
    // Required methods
    fn calculate_wire_delay(&self, length: i32, load_capacitance: f64) -> f64;
    fn calculate_wire_delay_per_unit(&self, load_capacitance: f64) -> f64;
    fn calculate_wire_capacitance(&self, length: i32) -> f64;
    fn calculate_tapping_point(
        &self,
        distance: i32,
        left_delay: f64,
        right_delay: f64,
        left_capacitance: f64,
        right_capacitance: f64,
    ) -> TappingResult;
}
Expand description

Abstract delay model for wire delay calculation.

Required Methods§

Source

fn calculate_wire_delay(&self, length: i32, load_capacitance: f64) -> f64

Calculates the total wire delay for a given length and load capacitance.

The specific formula depends on the delay model (linear or Elmore).

Source

fn calculate_wire_delay_per_unit(&self, load_capacitance: f64) -> f64

Calculates the wire delay per unit length for a given load capacitance.

Source

fn calculate_wire_capacitance(&self, length: i32) -> f64

Calculates the total wire capacitance for a given length.

Source

fn calculate_tapping_point( &self, distance: i32, left_delay: f64, right_delay: f64, left_capacitance: f64, right_capacitance: f64, ) -> TappingResult

Computes the tapping point (split location) between two subtrees to achieve prescribed skew, given their delays and capacitances.

Returns a TappingResult containing both the clamped extend_left (in [0, distance]) and the raw pre-clamp value, enabling the caller to implement the full elongation logic.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§