0% found this document useful (0 votes)
149 views1 page

How To Create A List of Cells in A Timing Path

tempus rm script

Uploaded by

thsim85
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
149 views1 page

How To Create A List of Cells in A Timing Path

tempus rm script

Uploaded by

thsim85
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 1

How to create a list of cells in a timing path?

Explanation of Script
The attached TCL script can be used to get a sorted list of lib/cell combinations from a timing path.

The script makes use of the -collection option of the report_timing command and then loops through the collection variable to extract the cell name and library
information. The collection returned by report_timing -collection is of type timing_point.

A timing point represents a pin of a cell and the get_cells -of_object command returns the cell pointer from it. Similarly, the get_lib_cells -of_object
command can be used to get the cell name as library_name/cell_name format from the timing point. The cell names with library reference is appended to a TCL list
and sorted to filter the unique elements, before printing the information.

Note:
As an option, in the code, you may include the parts of the path covering the launch or capture the clock segment. This part is commented out in the script. Uncomment
these lines to include the cell names of the cells in the launch and capture the clock paths as well.

Usage
You need to get the timing report into a collection in the form report_timing -collection -path_type full_clock -net -from <launch_point> -
to <capture_point>, where <launch_point> and <capture_point> represent the desired timing startpoint and endpoint.

For example:

set rt_cmd "report_timing -from DTMF_INST/RESULTS_CONV_INST/r1200_reg_0/Q -to DTMF_INST/RESULTS_CONV_INST/gt_reg/D -net


-path_type full_clock -collection"

After sourcing the script, you get the following output

Library/Cell tpz973g/PDO04CDG
Library/Cell tsmc18/AOI21X1
Library/Cell tsmc18/AOI2BB1X1
Library/Cell tsmc18/NAND4X1
Library/Cell tsmc18/NOR2BX1
Library/Cell tsmc18/NOR4BX1
Library/Cell tsmc18/OAI21XL
Library/Cell tsmc18/OAI22X1
Library/Cell tsmc18/SDFFNX1
Library/Cell tsmc18/SDFFSHQX1
Library/Cell tsmc18/SEDFFX1

Code
# Getting a sorted list of lirary_name/cell_name from a timing report
#
# Get the timing report into a collection
# Replace launch_point and capture_point with a timing startpoint and timing endpoint respectively
# before running the script
set rt_cmd "report_timing -collection -path_type full_clock -net -from launch_point -to capture_point"
set timing_path [eval $rt_cmd]

# Get the timing point from the report collection


set tp_coll [ get_property $timing_path timing_points]

# If coverage of launch and capture clock is needed add the next two lines
#append_to_collection tp_coll [ get_property [ get_property $timing_path launch_clock_path] timing_points]
#append_to_collection tp_coll [ get_property [ get_property $timing_path capture_clock_path] timing_points]

# Loop through the timing points and get the library_name/cell_name information
foreach_in_collection tp $tp_coll {
set pin [get_property $tp pin ]
if {[get_property $pin is_port] == false && [get_property $pin is_hierarchical] == false} {
set lib_cell [get_object_name [ get_lib_cells -of_objects [ get_cell -of_objects [get_pin $pin ] ] ] ]
lappend lib_cell_list $lib_cell
} else {
Puts "Skip because [get_object_name $pin] is port or hierarchical."
}
}

# Sort and uniquify the resulting list


set sorted_lib_cell_list [ lsort -uniq $lib_cell_list ]

# Loop through the sorted list and print it


foreach lc $sorted_lib_cell_list {
Puts "Library/Cell $lc"
}

Internal Notes
None

Return to the top of the page

You might also like