Global Placement#
The global placement module in OpenROAD (gpl
) is based on the open-source
RePlAce tool, from the paper “Advancing Solution Quality and Routability Validation
in Global Placement”.
Features:
Analytic and nonlinear placement algorithm. Solves electrostatic force equations using Nesterov’s method. (link)
Verified with various commercial technologies and research enablements using OpenDB (7/14/16/28/45/55/65nm).
Verified deterministic solution generation with various compilers and OS.
Supports Mixed-size placement mode.
Visualized examples from ISPD 2006 contest; adaptec2.inf |
Real-world Design: Coyote (TSMC16 7.5T) |
Commands#
Note
Parameters in square brackets
[-param param]
are optional.Parameters without square brackets
-param2 param2
are required.
Global Placement#
When using the -timing_driven
flag, gpl
does a virtual repair_design
to find slacks and
weight nets with low slack. It adjusts the worst slacks (modified with
-timing_driven_nets_percentage
) using a multiplier (modified with
-timing_driven_net_weight_max
). The multiplier
is scaled from the full value for the worst slack, to 1.0 at the
timing_driven_nets_percentage
point. Use the set_wire_rc
command to set
resistance and capacitance of estimated wires used for timing.
Routability-driven arguments
They begin with
-routability
.-routability_check_overflow
,-routability_max_density
,-routability_max_bloat_iter
,-routability_max_inflation_iter
,-routability_target_rc_metric
,-routability_inflation_ratio_coef
,-routability_max_inflation_ratio
,-routability_rc_coefficients
Timing-driven arguments
They begin with
-timing_driven
.-timing_driven_net_reweight_overflow
,-timing_driven_net_weight_max
,-timing_driven_nets_percentage
global_placement
[-timing_driven]
[-routability_driven]
[-disable_timing_driven]
[-disable_routability_driven]
[-skip_initial_place]
[-incremental]
[-bin_grid_count grid_count]
[-density target_density]
[-init_density_penalty init_density_penalty]
[-init_wirelength_coef init_wirelength_coef]
[-min_phi_coef min_phi_conef]
[-max_phi_coef max_phi_coef]
[-reference_hpwl reference_hpwl]
[-overflow overflow]
[-initial_place_max_iter initial_place_max_iter]
[-initial_place_max_fanout initial_place_max_fanout]
[-pad_left pad_left]
[-pad_right pad_right]
[-force_cpu]
[-skip_io]
[-skip_nesterov_place]
[-routability_check_overflow routability_check_overflow]
[-routability_max_density routability_max_density]
[-routability_max_bloat_iter routability_max_bloat_iter]
[-routability_max_inflation_iter routability_max_inflation_iter]
[-routability_target_rc_metric routability_target_rc_metric]
[-routability_inflation_ratio_coef routability_inflation_ratio_coef]
[-routability_max_inflation_ratio routability_max_inflation_ratio]
[-routability_rc_coefficients routability_rc_coefficients]
[-timing_driven_net_reweight_overflow]
[-timing_driven_net_weight_max]
[-timing_driven_nets_percentage]
Options#
Switch Name |
Description |
---|---|
|
Enable timing-driven mode. See link for timing-specific arguments. |
|
Enable routability-driven mode. See link for routability-specific arguments. |
|
Skip the initial placement (Biconjugate gradient stabilized, or BiCGSTAB solving) before Nesterov placement. Initial placement improves HPWL by ~5% on large designs. Equivalent to |
|
Enable the incremental global placement. Users would need to tune other parameters (e.g., |
|
Set bin grid’s counts. The internal heuristic defines the default value. Allowed values are integers |
|
Set target density. The default value is |
|
Set initial density penalty. The default value is |
|
Set initial wirelength coefficient. The default value is |
|
Set |
|
Set |
|
Set target overflow for termination condition. The default value is |
|
Set maximum iterations in the initial place. The default value is 20. Allowed values are integers |
|
Set net escape condition in initial place when \(fanout \geq initial\_place\_max\_fanout\). The default value is 200. Allowed values are integers |
|
Set left padding in terms of number of sites. The default value is 0, and the allowed values are integers |
|
Set right padding in terms of number of sites. The default value is 0, and the allowed values are integers |
|
Force to use the CPU solver even if the GPU is available. |
|
Flag to ignore the IO ports when computing wirelength during placement. The default value is False, allowed values are boolean. |
Routability-Driven Arguments#
Switch Name |
Description |
---|---|
|
Set overflow threshold for routability mode. The default value is |
|
Set density threshold for routability mode. The default value is |
|
Set bloat iteration threshold for routability mode. The default value is |
|
Set inflation iteration threshold for routability mode. The default value is |
|
Set target RC metric for routability mode. The default value is |
|
Set inflation ratio coefficient for routability mode. The default value is |
|
Set inflation ratio threshold for routability mode. The default value is |
|
Set routability RC coefficients. It comes in the form of a Tcl List |
Timing-Driven Arguments#
Switch Name |
Description |
---|---|
|
Set overflow threshold for timing-driven net reweighting. Allowed value is a Tcl list of integers where each number is |
|
Set the multiplier for the most timing-critical nets. The default value is |
|
Set the reweighted percentage of nets in timing-driven mode. The default value is 10. Allowed values are floats |
Cluster Flops#
This command does flop clustering based on parameters.
cluster_flops
[-tray_weight tray_weight]\
[-timing_weight timing_weight]\
[-max_split_size max_split_size]\
[-num_paths num_paths]
Options#
Switch Name |
Description |
---|---|
|
Tray weight, default value is 20.0, type |
|
Timing weight, default value is 1.0, type |
|
Maximum split size, default value is -1, type |
|
KIV, default value is 0, type |
Debug Mode#
The global_placement_debug
command initiates a debug mode, enabling real-time visualization of the algorithm’s progress on the layout. Use the command prior to executing the global_placement
command, for example in the global_place.tcl
script.
global_placement_debug
[-pause]
[-update]
[-inst]
[-draw_bins]
[-initial]
Options#
Switch Name |
Description |
---|---|
|
Number of iterations between pauses during debugging. Allows for visualization of the current state. Useful for closely monitoring the progression of the placement algorithm. Allowed values are integers, default is 10. |
|
Defines the frequency (in iterations) at which the tool refreshes its layout output to display the latest state during debugging. Allowed values are integers, default is 10. |
|
Targets a specific instance name for debugging focus. Allowed value is a string, the default behavior focuses on no specific instance. |
|
Activates visualization of placement bins, showcasing their density (indicated by the shade of white) and the direction of forces acting on them (depicted in red). The default setting is disabled. |
|
Pauses the debug process during the initial placement phase. The default setting is disabled. |
Example: global_placement_debug -pause 100 -update 1 -initial -draw_bins -inst _614_
This command configures the debugger to pause every 100 iterations, with layout updates occurring every iteration. It enables initial placement stage visualization, bin drawing, and specifically highlights instance 614.
Useful Developer Commands#
If you are a developer, you might find these useful. More details can be found in the source file or the swig file.
# adds padding and gets global placement uniform target density
get_global_placement_uniform_density -pad_left -pad_right
Example scripts demonstrating how to run gpl
on a sample design on core01
as follows:
./test/core01.tcl
Regression tests#
There are a set of regression tests in ./test
. For more information, refer to this section.
Simply run the following script:
./test/regression
Limitations#
Using the Python interface to gpl#
This API tries to stay close to the API defined in C++
class Replace
that is located here.
When initializing a design, a sequence of Python commands might look like the following:
from openroad import Design, Tech
tech = Tech()
tech.readLef(...)
design = Design(tech)
design.readDef(...)
gpl = design.getReplace()
Here is an example of some options / configurations to the global placer. (See Replace.h for a complete list)
gpl.setInitialPlaceMaxIter(iter)
gpl.setSkipIoMode(skip_io)
gpl.setTimingDrivenMode(timing_driven)
gpl.setTimingNetWeightMax(weight)
There are some useful Python functions located in the file grt_aux.py but these are not considered a part of the final API and they may change.
FAQs#
Check out GitHub discussion about this tool.
References#
C.-K. Cheng, A. B. Kahng, I. Kang and L. Wang, “RePlAce: Advancing Solution Quality and Routability Validation in Global Placement”, IEEE Transactions on Computer-Aided Design of Integrated Circuits and Systems, 38(9) (2019), pp. 1717-1730. (.pdf)
J. Lu, P. Chen, C.-C. Chang, L. Sha, D. J.-H. Huang, C.-C. Teng and C.-K. Cheng, “ePlace: Electrostatics based Placement using Fast Fourier Transform and Nesterov’s Method”, ACM TODAES 20(2) (2015), article 17. (.pdf)
J. Lu, H. Zhuang, P. Chen, H. Chang, C.-C. Chang, Y.-C. Wong, L. Sha, D. J.-H. Huang, Y. Luo, C.-C. Teng and C.-K. Cheng, “ePlace-MS: Electrostatics based Placement for Mixed-Size Circuits”, IEEE TCAD 34(5) (2015), pp. 685-698. (.pdf)
A. B. Kahng, J. Li and L. Wang,
“Improved Flop Tray-Based Design Implementation for Power Reduction”,
IEEE/ACM ICCAD, 2016, pp. 20:1-20:8.The timing-driven mode has been implemented by Mingyu Woo (only available in legacy repo in standalone branch.)
The routability-driven mode has been implemented by Mingyu Woo.
Timing-driven mode re-implementation is ongoing with the current clean-code structure.
License#
BSD 3-Clause License. See LICENSE file.