get_pins
Get pins of instance or module
Usage: @pins = get_pins($name, @options);
$name: The instance or module name, it can be hierarchical or leaf
@options:
-input: Get input pins
-output: Get output pins
-inout: Get inout pins
-clock: Get clock pin, only valid for sequential cell, flop latch and gated-clock-cell
-reset: Get reset pin, return "" if it doesn't exist
-set: Get set pin, return "" if it doesn't exist
-data: Get data pins
-attribute attribute: Get pins with the attribute
-nextstate_type type: Get pins matching the type
which can be 'data', 'load', 'scan_in', 'scan_enable'
This option is only valid for sequential cell, flop, latch and gated-clock-cell
If no option is present, get all pins
@pins: All pins returned, in 'instance/pin' format
Examples:
#1. Get input pins of a hierarchical instance
my @pins = get_pins("-input", "u_abc/U123");
Result @pins = ("u_abc/U123/A", "u_abc/U123/B")
#2. Get pins of a leaf cell
@pins = get_pins("AND2X2");
Result @pins = ("A","B","Y")