pub struct SimpleBufferInsertionEngine {
pub inverting_buffer_cell: String,
pub max_fanout: u32,
}Expand description
Simple buffer tree generator. This generator creates buffer trees consisting of a single type of inverter cell.
The algorithm works as follows:
- Create clusters of the sink terminals based on their location. Each cluster must have maximum size
max_fanout. Cluster sizes should be balanced. - Insert a buffer to drive each cluster. Place the buffer at the ‘center of mass’ of the terminals, or such that the quadratic distance to the sinks is minimized.
- Repeat the same with the newly inserted buffers until the fan out limit is satisfied.
- Make sure that the signal is not being inverted by adding another buffer when necessary.
Caveats
This algorithm assumes that the sinks are small standard-cells. This allows to easily find the rough location of the actual pin shape by assuming it is equal to the position of the cell. For large macro blocks this will not yield good results since the pins are substantially far away from the center of the cell.
Fields§
§inverting_buffer_cell: StringThe name of the inverting buffer cell to be used in the buffer tree.
max_fanout: u32Maximal number of cells that should be driven by a buffer cell.
Must be larger than 1.
Implementations§
source§impl SimpleBufferInsertionEngine
impl SimpleBufferInsertionEngine
sourcefn insert_buffers_recursive<LN: NetlistEdit + LayoutEdit>(
&self,
chip: &mut LN,
signal_source: TerminalId<LN>,
signal_sinks: &Vec<TerminalId<LN>>,
need_inversion: bool
) -> Result<(Vec<LN::CellInstId>, Vec<LN::NetId>), ()>where
LN::Coord: PrimInt,
fn insert_buffers_recursive<LN: NetlistEdit + LayoutEdit>( &self, chip: &mut LN, signal_source: TerminalId<LN>, signal_sinks: &Vec<TerminalId<LN>>, need_inversion: bool ) -> Result<(Vec<LN::CellInstId>, Vec<LN::NetId>), ()>where LN::Coord: PrimInt,
All terminals must be in the same parent cell.
need_inversion: Force the insertion of an inverter even if no buffer needs to be inserted.
Panics
Panics when
- The buffer cell cannot be found.
- The source terminal is not connected to a net.
- The sinks are not all connected to the same net as the source.
Trait Implementations§
source§impl Clone for SimpleBufferInsertionEngine
impl Clone for SimpleBufferInsertionEngine
source§fn clone(&self) -> SimpleBufferInsertionEngine
fn clone(&self) -> SimpleBufferInsertionEngine
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read more