Skip to content
This repository has been archived by the owner on Jan 26, 2021. It is now read-only.

Latest commit

 

History

History
35 lines (24 loc) · 1.55 KB

TclCommands.md

File metadata and controls

35 lines (24 loc) · 1.55 KB

Usage with TCL Interpreter

OpenDP has internal TCL Interpreter. The following line will create opendb_external objects.

opendp_external odp 

After having a opendp_external object, a user can type any TCL commands after one spacing from the object name(e.g. rep).

odp [tcl_command]

File I/O Commands

  • import_lef [file_name] : *.lef location (Multiple lef files supported. Technology LEF must be ahead of other LEFs.)
  • import_def [file_name] : *.def location (Required due to FloorPlan information)
  • export_def [file_name] : Output DEF location

Flow Control

  • init_opendp : Initialize OpenDP's structure based on LEF and DEF.
  • legalize_place : Legalize placed cells.
  • check_legality : Report overlaps between each cell.

Query results

Note that the following commands will work after init_opendp and legalize_place commands

  • get_utilization : Returns utilizations. [float]
  • get_sum_displacement : Returns sum of displacement between given and legalized design [float]
  • get_average_displacement : Returns average of displacement between given and legalized design [float]
  • get_max_displacement : Print max of displacement between given and legalized design [float]
  • get_original_hpwl : Returns HPWL from the given design. [float]
  • get_legalized_hpwl : Returns HPWL after the legalized design. [float]

Example TCL scripts

FYI, All of the TCL commands are defined in the opendp_external.h header files.