Compile Strategy
Compile Strategy
During an incremental compile, Design Compiler can improve quality of results (QoR)
by improving the structure of your design after the initial compile. Incremental mapping
uses the existing gates from an earlier compilation as a starting point for the mapping
process. It improves the existing design cost by focusing on the areas of the design
that do not meet constraints and affects the second pass of compile. The existing
structure is preserved where all constraints are already met. Mapping optimizations are
accepted only if they improve the circuit speed or area.
To perform an incremental compile, use the -incremental_mapping option with
the compile command or use the -incremental option with the compile_ultra
command.
Keep the following points in mind when you do an incremental compile:
◦ The option enables only gate-level optimizations.
◦ Gates are not converted back to the generic technology (GTECH) level.
◦ Flattening and structuring are not done on the mapped portion of the design.
◦ Implementations for DesignWare operators are reselected if optimization costs can
be improved.
In topographical mode, you can perform a second-pass, incremental compile to enable
topographical-based optimization for post-topographical-based synthesis flows such
as retiming, design-for-test (DFT), DFTMAX, and minor netlist edits. The primary focus
in Design Compiler topographical mode is to maintain QoR correlation; therefore, only
limited changes to the netlist can be made. Use the -incremental option with the
compile_ultra command to run an incremental compile in topographical mode.
Compile Strategies
To optimize successfully, do the following before you compile the design:
• Ensure that partitioning is the best possible for synthesis. The quality of optimization
results depends on how the HDL description is written. In particular, the partitioning of
the hierarchy in the HDL, if done well, can enhance optimization.
• Define constraints as accurately as possible but do not overconstrain your design.
• Use a good synthesis library.
• Identify all multicycle and false paths.
• Instantiate clock gating elements.
The top-level, or global, specifications for this design, given in Table 23, are defined by the
script in Example 71. These specifications apply to TOP and all its subdesigns.
Note:
To prevent buffering of the clock network, the script sets the input drive
resistance of the clock port (clk) to 0 (infinite drive strength).
Top-Down Compilation
In the top-down compile method, all environment and constraint settings are defined
with respect to the top-level design. Although this strategy automatically takes care of
interblock dependencies, the method is not practical for large designs because all designs
must reside in memory at the same time. Therefore, you should only use the top-down
compile strategy for designs that are not limited by memory or CPU.
You can use an alternate approach to compile a top-level design on a system that
is memory limited. By replacing some of the subdesigns with hierarchical model
representations, such as block abstractions, you can greatly reduce the memory
requirements for the subdesign instantiation in the top-level design. For information about
how to generate and use block abstractions, see Using Hierarchical Models.
Design Compiler automatically compiles the hierarchical circuits without collapsing the
hierarchy. After each module in the design is compiled, Design Compiler continues
to optimize the circuit until the constraints are met. This process sometimes requires
recompiling subdesigns on a critical path. When the performance goals are achieved or
when no further improvement can be made, the compile process stops.
Hierarchical compilation is automatic when the design being compiled has multiple levels
of hierarchy that are not marked dont_touch. Design Compiler preserves the hierarchy
information and optimizes individual levels automatically, based on the constraints at
the top level of hierarchy (dont_touch attributes placed on the top level of hierarchy are
ignored).
The top-down compile strategy has these advantages:
• Provides a push-button approach
• Takes care of interblock dependencies automatically
See Also
• Using Attributes
• Defining the Design Environment
• Defining Design Constraints
1. Read in as much of the design hierarchy as you need to use in this session. For
example, enter
dc_shell> read_file -format ddc adder.ddc
Reading ddc file ’/usr/design/adder.ddc’
Current design is ’ADDER’.
See Also
• Resolving Multiple Instances of a Design Reference
Bottom-Up Compilation
Use the bottom-up compile strategy for medium-sized and large designs. In the bottom-
up strategy, individual subdesigns are constrained and compiled separately and then
incorporated into the top-level design. The top-level constraints are applied, and the
design is checked for violations. Although it is possible that no violations are present, this
outcome is unlikely because the interface settings between subdesigns usually are not
sufficiently accurate at the start.
• The subdesign constraints are not preserved after you perform a top-level compile.
To ensure that you are using the correct constraints, always reapply the subdesign
constraints before compiling or analyzing a subdesign.
• By default, compile modifies the original copy in the current design. This could be
a problem when the same design is referenced from multiple modules, which are
compiled separately in sequence. For example, the first compile could change the
interface or the functionality of the design by boundary optimization. When this design
is referenced from another module in the subsequent compile, the modified design is
uniquified and used.
You can set the compile_keep_original_for_external_references variable to
true, which enables compile to keep the original design when there is an external
reference to the design. When the variable is set to true, the original design and its
subdesigns are copied and preserved before doing any modifications during compile if
there is an external reference to this design.
Typically, you require this variable only when you are doing a bottom-up compile
without setting a dont_touch attribute on all the subdesigns, especially those with
boundary optimizations turned on. If there is a dont_touch attribute on any of the
instances of the design or in the design, this variable has no effect.
# clear memory
remove_design -all
# recompile subblock
current_design $block
link
# apply global attributes and constraints
source defaults.con
# apply characterization constraints
set char_block_script "$block.wscr"
source $char_block_script
# apply block attributes and constraints
set block_script "$block.con"
source $block_script
# recompile the block
compile_ultra
}
See Also
• Using Hierarchical Models
• Performing a Bottom-up Hierarchical Compile
Provides steps for performing a bottom-up compile in topographical mode.
Mixed Compile
You can take advantage of the benefits of both the top-down and the bottom-up compile
strategies by using both.
• Use the top-down compile strategy for small hierarchies of blocks.
• Use the bottom-up compile strategy to tie small hierarchies together into larger blocks.
Figure 69 shows an example of the mixed compilation strategy.