get_fanins Constraint

get_fanins [-no_logic] -through <names> <start point>

This command returns a string of fanout ports and registers. This command supports the following options:

  • -no_logic if used, the software does not follow combinational timing arcs
  • -through pins, cells or nets (see -through Option for supported use cases)
  • <names> can be a net, cell, or pin
  • <start point> is a port, pin, or net

By default, the get_fanins command traces through combinational timing arcs.

# Given a set of register clock pins, find the clock source 
set reg_pattern "o*\[*\]~FF" 
set reg_cells [ get_cells ${reg_pattern} ] 
foreach reg $reg_cells { 
    # use get_pins to look for clock pin with pattern end with "|CLK" 
    set pin_pattern "${reg}|CLK" 
    set reg_pins [ get_pins $pin_pattern ] 
    
    # Find the clock source from register clock pins 
    foreach clk_pin $reg_pins { 
        set fanins [get_fanins $clk_pin] 
        puts "CLK_PIN: $clk_pin $fanins" 
    }
}
Note: This constraint returns a string, not an Efinity Tcl object. Therefore, you cannot use it in a nested format with object specifiers such as get_nets or get_cells.