Conformal Collection Automatic ECO 25sep2020
Conformal Collection Automatic ECO 25sep2020
Copyright Statement
© 2020 Cadence Design Systems, Inc. All rights reserved worldwide. Cadence and the Cadence logo are
registered trademarks of Cadence Design Systems, Inc. All others are the property of their respective
holders
Contents
Conformal Collection: Automatic ECO ......................................................................... 3
How to Run Conformal Flattened ECO Flow ............................................................... 4
Using the Optimize Patch Command ......................................................................... 10
Streamlined ECO Verification .................................................................................... 27
Debug ECO: Preserving Module Contents from Being Flattened When Generating the
Patch ......................................................................................................................... 36
Debug CECO: Diagnosing Unmapped Pin Error Due to Black Box Pin Differences .. 41
Debug CECO: Preventing CECO from Deleting and Adding a New DFF .................. 44
Debug CECO: How to Change the CPU Limit with the Analyze Eco Command ....... 50
Hierarchical Flattened ECO Flow............................................................................... 52
Configuring and Reporting Rule-Based ECO Setup Checks ..................................... 61
This is a collection of user guides and debug guides for using the automatic Conformal
ECO flows.
• Flattened ECO User guide: this guide instructs how to run the recommended
Flatten ECO flow to generate the patch.
• Using the Optimize patch Command: this guide helps user setup patch
optimization for different usage scenarios to obtain the best results.
• Streamline ECO Verification guide: this guide instructs how to setup ECO patch
validation.
• ECO debug guides: these guides instruct how to improve the quality of ECO
patch, debug ECO verification issues.
Summary
This document describes the Conformal flattened ECO flow which is the ECO
recommended flow.
In this flow, you run a flat compare on a hierarchical design. This flow can help when
your hierarchical dofile is causing false non-equivalent points (due to things like clock
gate cloning/decloning, inverter pushes, or boundary optimization).
This flow is not ideal for flat designs or when you have clean hierarchical dofiles (for
example, two dofiles with ECO modules are compared and their NEQs match those
reported by analyze_hier_compare).
• Focuses ECO analysis on the non-equivalent key points identified from a flat
compare.
• Supports hierarchical clock gating that is not a part of an ECO. For example, if
you have two hierarchical gates that do not match, you can perform a flat
compare, but create a patch to the hierarchical netlist.
• Works with the current hierarchical flow. You can also run a combination of the
hierarchical ECO flow and the FEF flow (running FEF on select modules).
• You can insert ECO pin/ports on demand through an ECO pin dofile.
• Easier set up. You can create all ECO patches with one command, and do not
need to run the hierarchical dofile.
Flow Diagram
Once you enter LEC mode, a typical scenario for a flattened ECO flow involves the
following steps:
• Apply and optimize the patch using the apply_patch and optimize_patch
commands, respectively.
Sample Dofile
The following illustrates a sample dofile for a post-mask flattened ECO flow:
Step 1: Setting up
#**********************************************************************
# Sets up the log file and instructs the tool to display usage
# information
#**********************************************************************
set_log_file fef_premask_eco.log.$env(LEC_VERSION) -replace
usage -auto -elapse
#**********************************************************************
# Specifies that the intention is to run the Flattened ECO flow.
# The "set eco option -flat" command executes the following commands:
# SET FLATTEN MODEL -ECO
# SET FLATTEN MODEL -ENABLE_ANALYZE_HIER_COMPARE
# It also automatically adds the following options to the
# ANALYZE HIER_COMPARE command:
# -CONstraints
# -NOEXact_pin_match
# -FUNCTION_Pin_mapping
# -INPUT_OUTPUT_Pin_equivalence
# -THRESHOLD 0
#**********************************************************************
set_eco_option -flat
#**********************************************************************
# Reads in the library and design files
#**********************************************************************
read_library <lib_files> -replace -liberty
read_design <netlist1> -replace -golden
read_design <netlist2> -replace -revised
report_design_data
report_black_box
#**********************************************************************
# Specifies user constraints for test/dft/etc
#**********************************************************************
# Specifies the modeling directives for constant optimization and
# clock gating
#**********************************************************************
# set_flatten_model -seq_constant
# set_flatten_model -gated_clock
# set_analyze_option -auto
#**************************************************************************
# Flattens, remodels, and maps the design
#**************************************************************************
set_system_mode lec
#**************************************************************************
#* Performs ECO-related checks that will flag potential issues related to
#* setup and offer potential solutions early
#**************************************************************************
check_eco_setup
#**************************************************************************
# Compares the flattened designs
#**************************************************************************
add_compared_point -all
compare
#**************************************************************************
#* Performs ECO-related checks that will flag potential issues related to
//* setup and offer potential solutions early
//**************************************************************************
check_eco_setup
//**************************************************************************
//* Breaks down the nonequivalent points to their sub-modules
//**************************************************************************
compare_eco_hierarchy
#**************************************************************************
# Optional steps:
# Reports the nonequivalent modules found by the tool:
#**************************************************************************
# report eco hierarchy -noneq -verbose
#**************************************************************************
# Creates the hierarchical patch.
# This command also creates the ecopins.do dofile, which adds
# ECO pins when there are extra pins in the Revised design
# (as compared to Golden design)
# and deletes ECO pins when there are extra pins in the Golden design .
#**************************************************************************
analyze_eco -hierarchical -ecopin_dofile ecopins.do patch.v -replace
set_system_mode setup
dofile ecopins.do
#**************************************************************************
# Applies the hierarchical patch to the flat netlist
#**************************************************************************
apply_patch -auto -gold -keephierarchy
Step 3: Optimizing the patches and write out the eco netlist.
#**************************************************************************
# Writes out an Genus/RC script (cfm_eco_rc.tcl) in the working
# directory that will optimize the patches and execute the script.
# After OPTIMIZE PATCH successfully completes, the ECO design will be
# in the memory and can be written out. The optimized patches will be
# in the working directory.
#**************************************************************************
optimize_patch -workdir <working_directory> \
-library <lib_file_list> \
-sdc <sdc_filename> \
-instancenaming "ECO2inst_%d" \
-netnaming "ECO2net_%d" \
-sequentialnaming "ECO2reg_%s" \
-SYNCExec "rc/genus -nogui -legacy_ui" \
-verbose
#**************************************************************************
# Reports the ECO changes
#**************************************************************************
report_eco_changes -script -file test.script -replace
#**************************************************************************
# Writes out the G3 ECO netlist
#**************************************************************************
This Conformal ECO (CECO) user guide helps users set up patch optimization for
different usage scenarios to obtain the desired results.
Conformal ECO compares two designs and generates a functional patch that
implements the changes between the two designs. After the patch is created and
applied, it is passed to the synthesis tool through the optimize_patch command. This
command goes through the following steps to complete the patch technology mapping
and optimization:
• Generate a synthesis script (cfm_eco_rc.tcl). This script will include any specified
user scripts.
For more information on the options of optimize_patch, refer to its MAN page.
A Sample Flow
eco.do
set_eco_option -flat
read_design/library
.......
set_system_mode lec
compare_eco_hierarchy
analyze_eco
.....
set_system_mode setup
3. Run CECO
lec -ecogxl -nogui -do eco.do
These options are used to specify common used patch optimization scenarios:
optimize_patch
[-NOUSETIEcell]
[-ALLOWTIECELLINVersion]
[-POSTSETUPscript <script_file_name>]
[-AVOID <cell_name>*]
[-USE <cell_name>*]
[-NOFLATTEN_SMALL]
• -ALLOWTIECELLINVersion: Allows tie cells with inverters if one of the tie hi/lo
cells is not found.
For more information on the options of optimize_patch, refer to its MAN page.
• -POSTSYNscript: Specifies the script to run after all patches are synthesized.
CECO depends on the specified synthesis executable and generates the patch
optimization script (cfm_eco_rc.tcl ) with a corresponding format.
By default, it generates Genus Common UI script. When using with option -synexec
rc or -synexec genus -legacy_ui, it generates a Legacy UI script.
The user scripts that included in cfm_eco_rc.tcl have to be the same format (They either
both in Legacy UI or Common UI) . Otherwise, the optimize patch fails with the following
error message:
Error : The tool is running in common ui mode. [TUI-509] [::unknown]
: Command 'set_attribute' is a legacy ui command.
: Use set_db/get_db instead or do set_db common_ui
false at start of the run.
<patch.v>
module tdsp_data_mux_eco ........;
// pragma no_bbox_empty
assign \t_data[15] = 1'b1;
assign \t_data[14] = 1'b1;
.......
assign \t_data[0] = 1'b0;
endmodule
The following commands apply the patch optimization and preserve patch constants:
apply_patch -auto
optimize_patch -nousetiecell
There are cases when, even after running optimize patch without -nousetiecell, the
output G3 still contains constants (1'b0, 1'b1).
• Check if tie cells in the liberty contain a dont use attribute. If they do, use the -
use <tiecell> option of the optimize_patch command. This will remove the
don't use attribute for the tie cells.
The following commands apply and optimize the patch and allow inversion of the
specified tie cell:
SETUP> apply_patch -auto
SETUP> optimize_patch -allowtiecellinversion -use LOGIC0_X1 \
-avoid LOGIC1_X1
If there are multiple tie cells in the library and you want to specify the tie cell type for
constant mapping, use the command option -avoid <cell> -use <tiehi cell>.
For example:
TCL_SETUP> optimize_patch -use LOGIC0_X1 LOGIC1_X1 \
-avoid TIE0*
When the patch includes new DFFs, to ensure the scan or non-scan DFFs cell type is
kept the same before and after patch optimization with the expected result
presyn.tcl
# Genus Common UI version
set_db unmap_scan_flops false
proc eco_pre_synthesis_cmd {patch} {
set_db [vfind $patch] .dft_scan_map_mode preserve
}
#RC/legacy UI version
set_attribute unmap_scan_flops false
proc eco_pre_synthesis_cmd {patch} {
set_attribute dft_scan_map_mode preserve $patch
}
//Non-scan DFF
DFFR_X2 new_reg1(.CK(clk),.D(write_in),.RN(n_72),.Q(ecow2)); // DFF:1
//Scan DFF
SDFFR_X2 new_reg2(.CK(clk),.D(ecow2),.RN(n_72),.SE(1'b0),.SI(1'b0),.Q(write)); //
DFF:1
//DFF Primitive
DFF read_reg(read,n_175,\read_reg/S ,\read_reg/n$1 ,clk,\read_reg/n$2 );
To preserve the DFFs of the patch without unmapping and remapping to other DFF
cells, the following script can be used:
eco.do
TCL_SETUP> optimize_patch -presynscript presyn.tcl
presyn.tcl
# Genus Common UI version
proc eco_pre_synthesis_cmd {patch} {
set all_insts [vfind $patch -inst *]
set mapped_seqs [get_db $all_insts -if {.sequential == true && .lib_cell != ""}]
if { [llength $mapped_seqs] > 0 } {
set_db $mapped_seqs .preserve true
}
}
# RC/Legacy UI version
proc eco_pre_synthesis_cmd {patch} {
set mapped [filter -invert libcell "" [find $patch -inst *]]
if { [llength $mapped] > 0 } {
set mapped_seqs [filter sequential true $mapped]
set_attr preserve true $mapped_seqs
}
}
To preserve all the cells and nets of the patch without remapping or changing them, the
user can use the following script.
eco.do
TCL_SETUP> optimize_patch -presynscript presyn.tcl
presyn.tcl
# Genus Common UI version
proc eco_pre_synthesis_cmd {patch} {
set all_insts [vfind $patch -inst *]
set mapped [get_db $all_insts -if {.lib_cell != ""}]
if { [llength $mapped] > 0 } {
set_db $mapped .preserve true
}
set all_hnets [vfind $patch -hnet *]
set nonconst_net [get_db $all_hnets -if {.constant == "no_constant"}]
if { [llength $nonconst_net] > 0 } {
In some post-mask ECO cases, there are clock buffer cells in the patch that need to be
preserved. During patch optimization, to prevent Genus from touching the clock buffer
cells in the patch you can include the presynscript as below. Also, the presyncsript
could be extended to preserve any specific cells.
eco.do
TCL_SETUP> optimize_patch -presynscript presyn.tcl
presyn.tcl
# Genus Common UI version
# Please replace "*CKBufffer*" to your Clock buffer cell
proc eco_pre_synthesis_cmd {patch} {
set all_insts [vfind $patch -inst *]
set mapped [get_db $all_insts -if {.base_cell.name == "CKBuffer"}]
if { [llength $mapped] > 0 } {
set_db $mapped .preserve true
}
}
# RC/Legacy UI version
# Replace "*CKBufffer*" to the target clock buffer cells
proc eco_pre_synthesis_cmd {patch} {
set mapped [filter libcell "*CKBuffer" [find $patch -inst *]]
if { [llength $mapped] > 0 } {
set_attr preserve true $mapped
}
}
To disable these optimizations during patch optimization, add the following below to the
presynscript.
eco.do
TCL_SETUP> optimize_patch -presynscript presyn.tcl
presyn.tcl
# Genus Common UI version
set_db / .optimize_merge_flops false
set_db / .optimize_constant_0_flops false
set_db / .optimize_constant_1_flops false
set_db / .optimize_constant_feedback_seqs false
# RC/Legacy UI version
set_attribute optimize_merge_flops false
set_attribute optimize_constant_0_flops false
set_attribute optimize_constant_1_flops false
set_attribute optimize_constant_feedback_seqs false
• A simple DFF can be converted to a DFF with inversion at the input and output.
• Phase inversion is useful when the RTL functionality requires a preset function,
but the technology library has only a reset DFF or vice versa.
• When this attribute is set to true during patch validation, set mapping method
-phase needs to be enabled.
DFF phase inversion is disabled by default. To enable it, set it to true in prelib.tcl. This
setting can be useful in the postmask ECO flow when the number of spare cells is
prelib.tcl
# Genus Common UI version
set_db / .lbr_seq_in_out_phase_opto true
# RC/Legacy UI version
set_attribute lbr_seq_in_out_phase_opto true
eco.do
TCL_SETUP> optimize_patch -prelibscript prelib.tcl
prelib.tcl
# Genus Common UI version
set_db eco_prefer_non_degen 0
# RC/Legacy UI version
set_attribute eco_prefer_non_degen 0 /
The following script can be used to report the coordinates of used spare cell locations.
Note: that the instance name in the report is without applying renaming rules which is
specified by -instancenaming, -sequentialnaming.
eco.do
TCL_SETUP> optimize patch -presynscript presyn.tcl -workdir WORKDIR
presyn.tcl
By default Genus maps and optimizes the patches serially as they are passed from
CECO. In a postmask ECO this may not be optimal mapping. Use below option in
prelib.tcl script to have it revisit all the mapping once the last patch is mapped.
eco.do
TCL_SETUP> optimize_patch -prelibscript prelib.tcl
prelib.tcl
# Genus Common UI version
set_db .eco_revise_spare_gate_assignment 1
# RC/Legacy UI version
set_attribute eco_revise_spare_gate_assignment 1
By default timing constraints have higher priority than design rules in Genus. To change
the default setting, you can use the following prelibscript.
eco.do
TCL_SETUP> optimize_patch -prelibscript prelib.tcl
prelib.tcl
# Genus Common UI version
set_db / .drc_first true
# RC/Legacy UI version
set_attribute drc_first true
Scenario 14: How to Read a DEF File with Filler in Premask Physical
ECO
In premask physical ECO, the DEF file is required to have no-filler cell in it. Use the
following script to allow reading a DEF containing filler cells.
eco.do
TCL_SETUP> optimize_patch -prelibscript prelib.tcl
prelib.tcl
# Genus Common UI version
set_db / .eco_skip_fillers_in_def 1
# RC/Legacy UI version
set_attribute eco_skip_fillers_in_def 1 /
For example:
ECO-INFO: Final total library cell availability (GA + spare/freed)
===================================================================
Generated by: Genus(TM) Synthesis Solution GENUS15.20 - 15.20-p004_1
Generated on: Aug 22 2016 09:45:09 pm
Adding the following postsynscript, Genus will exit with an error code when ECO-
ERROR is present.
eco.do
TCL_SETUP> optimize_patch -postsynscript postsyn.tcl
postsyn.tcl
# Genus Common UI version
if { [get_db / .total_eco_violation] > 0 } {
exit 1
}
# RC/Legacy UI version
if { [get_attr total_eco_violation /] > 0 } {
exit 1
}
You can report the N-worst timing paths that go through each ECO instance before and
after the optimize_patch command.
Adding the following 2 procs to the presynscript, Genus will output the N-worst timing
paths before and after Genus optimization.
eco.do
TCL_SETUP> optimize_patch -presynscript presyn.tcl
presyn.tcl
proc eco_pre_synthesis_global_cmd {eco_insts} {
foreach inst $eco_insts {
In this example N is 20 and presyn.rpt and postsyn.rpt are the respective output files.
Capture Launch
...
In a premask physical or postmask flow, you can report the paths along with location
information after Genus has done placement.
eco.do
TCL_SETUP> optimize_patch -postsynscript postsyn.tcl
postsyn.tcl
# Genus Common UI version
proc eco_final_global_cmd {eco_insts} {
foreach inst $eco_insts {
redirect -append ../final.rpt { report_timing -through \
[vfind [vfind $inst] -pin *] -nworst 20 }
Adding the the proc eco_final_global_cmd, Genus will output the N-worst timing
paths after Genus placement. This can be added to the postsyn script.
Summary
Streamlined ECO verification provides a complete solution for setting up the ECO patch
validation. This solution can reduce setup and comparison runtime, and can eliminate
setup related NEQs due to mapping or sequential modeling issues. The feature was
released in Conformal 14.20.
Background
In the CECO flow, two netlists G1 and G2 are read in and compared. ECO changes will
result in non-equivalences and CECO will create a patch which can be applied to G1 to
implement the functional changes. The resulting netlist is called G3.
The expectation is that the patched netlist G3 will be equivalent to G2. However, this
requires the setup for comparison to be the same as when the ECO patch was
computed. If the setup is different, the functional mapping may map some key points
differently. This can result in a comparison that shows non-equivalence even though the
patch was computed correctly.
Streamlined ECO verification works based on verification information from the G1 and
G2 designs. This includes mapping and sequential modeling information from the patch
generation stage. Streamlined ECO verification captures all the correct setup during
G1G2 run and is applied to G3G2 comparison to ensure the keypoints are mapped and
modeled correctly.
• Patch generation stage: Setup, collect and save the before-ECO design
information and ECO changes to verification information
• Patch validation stage: Apply verification information to LEC compare for G3G2
validation
• Run at the beginning of patch generation stage to capture all the verification
information.
write_verification_information <verification_information_directory>
• Run at the very last step of patch generation stage, after optimize_patch
• Specify that LEC only performs sequential constant and sequential merge
modeling specified in verification information. Also enables mapping from the
verification information.
There may be constraints that are applied to G1 or G2 during patch generation. For
example: pin/instance constraints, pin/instance equivalence, ignored test inputs/outputs.
For example, constraints on the scan enable pins in G1:
add_pin_constraint 0 scan_en -golden
Note the same constraints should be applied on G3 when validating the patch.
Currently, such external constraints are not captured by the verification information, so
they need to be put explicitly before validating the patch, for example:
# Make use of verification information
set_verification_information ver_info -setup all
# Specify to use exact setup
set_flatten_model -specified_setup_only
set_flatten_model -noauto_modeling
...
add pin constraint 0 scan_en -golden
...
set_system_mode lec
add_compared_points -all
compare
Streamlined ECO verification supports customized naming rules for new flops in the
patch. The user can specify the naming rules using either one of the following settings:
set_eco_option -SEQuentialnaming "CFM_ECO_%s"
optimize_patch -SEQuentialnaming "CFM_ECO_%s"
When there is a customized naming setting specified, a new flop will be named
according to user setup. For example, given the naming format CFM_ECO_%s, a flop
copied from G2 named REG1 will be named as CFM_ECO_REG1 in G3. The command
write_verification_information will update the mapping information for G3 side to
be (CFM_ECO_REG1, REG1).
Streamlined ECO verification also supports the flop replacement. Flop replacement
happens when there is a flop type change such as asynchronous reset changed to
asynchronous set. For these scenarios, CECO preserves the original flop in order to
keep scan chain intact. To avoid naming conflict, the name of the new flop is appended
with a number to differentiate the flops.
The enhancement updates the mapping of new flop when a naming change happens. In
the example below, the streamlined ECO verification updates the correct mapping for
the new flop, REG1_1 to be (REG1_1, REG1).
Streamlined ECO verification can also record sequential merge information which helps
in G3 modeling.
Consider the following scenario below: G2 has duplicated flops. When the flop /REG1 is
patched to G3, /ModA/REG1 and /REG1_dup should be sequentially merged. With the
command write_verification_information, the sequential merge information of
/ModA/REG1 and /REG1_dup is recorded.
• Design statistics:
G1 G2
• Patch information:
EQ NEQ
The benchmark result of streamlined ECO verification is shown below. There are 385
ECO test cases in the benchmark. CECO in Conformal 18.20 passes 12 more cases
with the help of streamlined ECO verification.
Benchmark 2: Summary
In the Flattened ECO Flow (recommended flow), the G2 is flattened to match the
hierarchy in G1. This makes it easier to find corresponding nets during patch creation. If
the G2 netlist contains additional modules, these modules will be flattened. The
flattened modules' contents get added to the patch in the next hierarchy of the flattened
modules.
Module preservation is useful for verification, DFT, or Place and Route. This guide will
show you the steps to preserve the additional modules' hierarchy in the final G3 netlist.
Using the report_modules command, you can see there is an additional module
vga_tclk that is introduced in the Revised G2 netlist.
TCL_LEC> report_modules
Golden:
vga_top
vga_htim
vga_vtim
vga_tgen
Revised:
vga_top
vga_htim
vga_vtim
vga_tgen
vga_tclk
In the Flattened ECO Flow, vga_tclk is flattened to make the hierarchies between G1
and G2 match. To preserve the vga_tclk module in the final G3 netlist, this module must
not be flattened in the Conformal ECO flow.
The module boundary of vga_tclk will get flattened in the Revised by the flatten
command option, which is recommended in the FEF flow.
TCL_SETUP> flatten -nolibirary -matchhierarchy -revised
TCL_SETUP> report_modules
Golden:
vga_top
The contents of vga_tclk will now be passed to the Final G3 netlist. Note that the
module vga_tclk is no longer there in the Revised G2 netlist. Its logic is now in the top
module vga_tclk.
To make sure the output patch has the vga _tclk module, black box this module prior to
the flatten command. This will prevent it from being flattened by the flatten
command.
TCL_SETUP> add_black_box vga_tclk -revised
TCL_SETUP> report_black_box
USER: (R) vga_tclk
TCL_SETUP> flatten -nolibrary -matchhierarchy -revised
TCL_SETUP> report_modules
Golden:
vga_top
vga_htim
vga_vtim
vga_tgen
Revised:
vga_top
vga_htim
vga_vtim
vga_tgen
vga_tclk (black box)
Note that the vga_tclk module is still present in the Revised design as a black box.
Since the vga_tclk module is a black box only in the Revised, LEC will classify it as a
not-mapped point.
TCL_SETUP> set_system_mode lec
// Processing Golden ...
// Modeling Golden ...
...
Unmapped points:
=======================================================
Now continuing with the flatten ECO flow, this black box will be copied over to the final
G3 netlist.
During the analyze_eco command process, the patch will contain the vga_tclk module
and its contents.
TCL_LEC> analyze_eco -hierarchical patch.v -replace
// analyzing vga_top (path: vga_top)
// Grouping
...
// Note:5 group(s) added
// Note 20 library cell(s) in the patch
// 1 module instance(s) are in the patch
The one module instance in the patch refers to the vga_tclk black box module.
From the report_modules command, the vga_tclk module is now in the final G3 netlist.
The last step in the CECO flow is to optimize the patch with the optimize_patch
command. During this step, you should use the option -noflatten_small. The default
behavior in Genus is to flatten modules smaller than 10k gates. This option will instruct
Genus to not flatten these modules and keep the hierarchy.
TCL_SETUP> optimize_patch -noflatten_small ...
// Note: Executing 'genus -bg -version'
...
// Normal exit.
// Parsing file work/cfm_eco_patch1.gv
// Flatten patch vga_top -instance eco
To validate the patch in the same session, remove the vga_tclk black box in Revised
with the delete_black_box command. This is done to make sure that Conformal ECO
copied over the contents of vga_tclk correctly from the G2.
TCL_SETUP>optimize_patch -noflatten_small ...
// Note: Executing 'genus -bg -version'
...
// Normal exit.
// Parsing file work/cfm_eco_patch1.gv
// Flatten patch vga_top -instance eco
TCL_SETUP> delete_black_box -all -both
TCL_SETUP> report_modules
Golden:
vga_top
vga_htim
vga_vtim
vga_tgen
vga_tclk
Revised:
Now the patch is validated with the addition of the vga_tclk module hierarchy in the final
G3 netlist.
In Conformal ECO the G1 and G2 netlists may contain black boxes. These can be from
the libraries, such as memories and RAMs, and user defined with the add_black_box
command. In either case, the black box pins should match if they are a part of the ECO
since Conformal ECO can not change the black box interface. If they do not, it can lead
to an error during the analyze_eco command.
The following error message Patch reaches unmapped pin occurs during the
analyze_eco command. This prevents Conformal ECO from creating a successful
patch.
TCL_LEC> analyze_eco -ecopin_dofile ecopin.do patch.v -replace
// Analyzing vga_vtim (path: /vtgen/ver_gen)
...
// Error: Patch reaches unmapped pin Blackbox/o2 in TOP
You first need to get more information on this unmapped black box pin with the following
step.
The following diagram shows the extra black box input pin b and output pin o2 in the G2
netlist. The warning occurs since CECO cannot modify the interface of a black box. It
cannot patch the non-equivalences due to these extra pins.
To address the extra black box pins, check whether the library or module definition of
the black box in G1 and G2 are the same. Use the write_design -bbox_only
command to write out the G1 and G2 black boxes to a file.
TCL_LEC> write_design -bbox_only gol.bbox -golden -replace
TCL_LEC> write_design -bbox_only rev.bbox -revised -replace
You can use tkdiff or a text viewer to compare the module definitions.
This guide explains a simple way to prevent CECO from deleting and adding in a new
DFF when changing a set DFF to a reset DFF or reset to set. If there is a mapped DFF
that is a different type in G2, the default behavior in CECO is to copy the DFF from G2.
This will add in a new DFF and delete the original one. This can break the scan chain,
and make it more difficult in a post-mask ECO since a new spare DFF needs to be used
and rerouted.
In this example, the ECO is changing a set DFF, dout_reg, to a reset DFF. When there
is a DFF type change in the CECO flow, the DFF, dout_reg, will be non-equivalent after
comparison between the G1 and G2 netlists. After compare has completed use the
report_compare_data -nonequivalent command to report the non-equivalent
points.
TCL_LEC> compare
===========================================
Compared points PO DFF Total
-------------------------------------------
Equivalent 1 0 1
-------------------------------------------
Non-equivalent 0 1 1
============================================
The next step in the FEF flow is to run the compare_eco_hierarchy and analyze_eco
commands.
A new DFF has been added to the patch during the patch creation process from the
analyze_eco command. The next step is to apply the patch.
A new DFF has been added and the original one has been freed (deleted). We can also
see the DFF, dout_reg, in the patch file, patch.v.
patch.v
Preventing the DFF from being Added and Deleted by using Phase
Mapping
Since we are changing the DFF from a set to reset, we can use phase mapping so
Conformal ECO can just add an inverter to the output of the DFF. The
set_mapping_method -phase command will map key points with an inverted phase.
Use this command before set_system_mode lec. Once the patch has been applied,
the Golden database has been permanently changed. You will need to add this
command to the dofile and rerun CECO.
TCL_SETUP> set_mapping_method -phase
...
TCL_SETUP> set_system_mode lec
// Processing Golden ...
// Modeling Golden ...
// Processing Revised ...
// Modeling Revised ..
...
Mapped points: SYSTEM class
-----------------------------------------------
Mapped points PI PO DFF Total
-----------------------------------------------
Golden 4 1 1 6
-----------------------------------------------
Revised 4 1 1 6
================================================
The DFF, dout_reg, is now mapped by phase. We can confirm this by reporting the
mapping points with the -inverted_phase option.
Another way to map the DFF by phase is by using a mapping file. In cases where the
user knows the DFFs that are changing type, it map be easier to manually maps these.
In this file you specify which DFF's are to be mapped by phase. In this example, we
create a file named map.f which contains the mapping information.
add_mapped_point dout_reg dout_reg -invert
The first dout_reg is the Golden (G1) DFF name and the second dout_reg is the
Revised (G2) DFF name.
To use the mapping file in the Conformal ECO dofile, it specified with the
set_analyze_option -mapping_file command. Use this command before
set_system_mode lec. The phase mapped DFF will now be in the USER class.
The DFF, dout_reg, is now mapped by phase. We can confirm this by reporting the
mapping points with the -inverted_phase option.
Golden Revised
+ 6 DFF /dout_reg/U$1 - 7 DFF /dout_reg/U$1
==============================================
Mapped points DFF Total
----------------------------------------------
Golden 1 1
----------------------------------------------
Revised 1 1
=============================================
The DFF, dout_reg, is now mapped by phase inversion. This is represented with the
symbol "-" in the Revised DFF.
TCL_LEC> compare
// Command: compare
===========================================
Compared points PO DFF Total
-------------------------------------------
Equivalent 1 0 1
-------------------------------------------
Non-equivalent 0 1 1
============================================
TCL_LEC> compare_eco_hierarchy
...
TCL_LEC> analyze_eco -hierarchical -ecopin_dofile ecopins.do patch.v -replace
// Command: analyze eco -hierarchical -ecopin_dofile ecopins.do patch.v -replace
// Analyzing conv_subreg (path:/)
// Grouping
// Note: 2 group(s) added
// Note: 0 library cell(s) is in the patch
// Note: 1 primitive(s) is in the patch
In this original run, there was a DFF added to the patch. Now with phase mapping, only
a single primitive is added to the patch and there are no DFFs added.
Only a single primitive is added to the patch and no cells are freed (deleted). The
original DFF is kept with its set inverted.
The following warning message CPU limit exceeded can occur during
the analyze_eco command when the default limit of 36000 seconds is reached. The
default is high effort.
TCL_LEC> analyze_eco -ecopin_dofile ecopin.do patch.v -replace
// Analyzing vga_vtim (path: /vtgen)
// Grouping
// Note: 2 group(s) added
// Warning: CPU limit is exceeded, effort lowered to medium
// Note: 15 library cell(s) is in the patch
// Note: 16 primitive(s) are in the patch
// Warning: 2 DFF(s) are in the patch
In this case, the effort level is reduced from high to medium effort. Next we will show
you the CPU limits affect on post optimization.
Post optimization occurs with high effort, when the -post_optimization option is specified
or automatically with ultra effort. Post optimization tries to further reduce the patch size
after the patch is generated. You may see this message that post optimization is
skipped when running the analyze_eco command when the CPU limit is reached.
Next we will show you have to increase the CPU limit to avoid skipping post
optimization to get the smallest patch possible.
There is a new option -cpulimit introduced in Conformal ECO 19.20-p100 for the
analyze_eco command. This option is specified in seconds. The default is 36000
seconds. This number can be increased or decreased. There is no maximum limit.
TCL_LEC> analyze_eco -ecopin_dofile ecopin.do patch.v -replace \
-effort ultra -cpulimit 64000
// Analyzing vga_vtim (path: /vtgen)
// Grouping
// Note: 2 group(s) added
// Post Optimization
// Note: 2 nets found by post optimization
// Note: 10 library cell(s) is in the patch
// Note: 12 primitive(s) are in the patch
// Warning: 2 DFF(s) are in the patch
Increasing the CPU limit to 64000 seconds now allows the patch to be created with the
specified effort level (in this case ultra) without switching to medium effort. In this case
the patch size is reduced from 15 to 10 library cells and 16 to 12 primitives.
Hierarchical flattened ECO flow (Hier-FEF) combines the hierarchical ECO flow for its
runtime advantage and the flattened ECO flow (FEF) for its quality advantage. The Hier-
FEF can reduce the turnaround time by as much as 10x while delivering high-quality
patches.
In Hier-FEF, we generate the targeted ECO blocks dofile using Conformal hierarchical
dofile extraction and then execute individual FEF on ECO blocks to create the ECO
patches.
When ECOs are deep in the design hierarchies, the Hier-FEF avoids processing non-
ECO modules and analyzes only the designated ECO sub-module. As a result, the
turnaround time becomes much faster.
Hier-FEF Advantages
• Utilizes FEF advantages that analyze ECO blocks and automatically identify the
ECO location and ECO module pin changes.
• Utilizes hierarchical dofile generation to speed up the runtime and the module pin
mapping.
• Utilizes automatic ECO setup checks to see if an ECO block is compatible with
this flow.
ECO Flows
Hier-FEF runs FEF on each ECO block where an ECO block is a module including ECO
submodule(s). The ECO block has no interface changes which enables it to be written
out during hierarchical dofile generation.
In the example below, the ECO is to modules modA_1 and modA_2. User can set
modA as ECO block and run Hier-FEF. The other modules are excluded from
comparsion, which saves the turnaround time.
• Flattened-comparison and modeling for the entire design take a long time.
Hier-FEF Flowchart
• Provide a list of ECO blocks and tag these modules with an attribute for
the hierarchical dofile generation.
• Apply the patch, optimize the patch and write out G3 (ECO netlist)
delete_black_box -all -both
set_root_module top -both
foreach module $eco_blocks { dofile ${module}.ecopins.do }
apply_patch -auto
optimize_patch -workdir genus_work -library cells.lib
write_eco_design -newfile g3.v
ECO Validation
After the ECO-change process is done, the next step is patch validation which is done
by running regular equivalence checking on G3 versus G2.
In the ECO netlist validation step, we verify that the ECO blocks are functionally
equivalent as well as the entire final ECO netlist.
• In a separate run, apply the verification information which was saved in Hier-FEF
run.
set_verification_information UVI -setup all
set_flatten_model -specified_setup_only
set_hier_compare_option -ignore_top_merge_constraint
The following is a sample dofile script for validating the ECO netlist G3.
#Step1: Set the flow as a regular lec run
read_library -liberty lib.lib
read_design -golden g3.v
read_design -revised g2.v
Hier-FEF Commands
• set_eco_option -hier_flat
• add_module_attribute -flat_eco_module
• add_module_attribute -analyze_eco_string
-balanced_extraction
-constraints
-noexact_pin_match
-function_pIn_mapping
-input_output_pin_equivalence
-extract_icg
-threshold 0
• Hierarchy generation only writes out modules of ECO blocks. Others are
excluded from hierarchical generation by the command add_noblack_box
• During a normal ECO run hierarchical dofile generation will output these
commands:
add_compared_points -all
compare
In the Hier-FEF the following commands are output during hierarchical dofile
generation:
analyze_hier_compare -eco_aware
add_compared_points -all
compare
compare_eco_hierarchy
check_eco_setup
analyze_eco -hierarchical -ecopin_dofile <module>.ecopins.do <module>.patch.v -
replace
For example, if the user wants to include the option -preserve_clock in the command
analyze_eco, the user can use the command:
Then the output hierarchical dofile for moduleA will include commands:
analyze_hier_compare -eco_aware
add_compared_points -all
compare
compare_eco_hierarchy -verbose
check_eco_setup
analyze_eco -hierarchical -ecopin_dofile A.ecopins A.patch -preserve_clock -replace
There are two ECO setup checks for Hier-FEF. These checks are automatically
performed after the commands
write_hier_compare_dofile and compare_eco_hierarchy.
• Hierarchical ECO module: This check reports the ECO block was not written out
during hierarchical generation.
• Shared pin change in Hier-FEF: This check reports a shared pin of the ECO
block requires the ECO be made at its parent module. A shared pin drives both
function and scan path.
Benchmark Results
From the benchmark results, it shows that Hier-FEF helps to improve turnaround time,
especially for a small ECO block in a large design.
Conformal ECO setup checks streamline the ECO process by flagging potential issues
and suggesting possible resolutions early in the ECO process. Starting from 19.20-
p100, Conformal ECO provides the capability to customize automated setup checks.
Each ECO setup check is rule-based and reports detailed information about the setup
check. Users can configure each ECO setup check for severity and to stop the tool
execution if needed.
In Conformal ECO 20.10, additional setup checks are added to cover more ECO setup
issues. With these setup checks, users can identify issues upfront and improve
turnaround time up to 10X for diagnosis and resolving ECO setup related issues.
Every check name consists of <prefix>.<number>. The prefix depends on when the
check is available. All prefixes are listed below.
The following ECO setup checks are added since Conformal ECO 19.20-p100. For the
details and example of each rule, refer to the appendix at the end of this documentation.
A check with Error severity can cause a patch generation failure or an incorrect patch.
To help users to find the issue and review the setting as early as possible, by default the
process is stopped when an error is detected.
To diagnosis the details of eco setup check, users can use the report_eco_check -
verbose command:
If users confirm the error is expected and want to continue the ECO process, the check
severity can be lowered from Error to Warning with the set_eco_check command.
Benchmark Result
The following are the benchmark results from cases which have missing DFT
constraints (ECO2.3 and ECO2.4).