Skip to content

Commit 2fa6b35

Browse files
committed
- Update synth_preamble.tcl and two_phase_clk_synth.tcl
1 parent 4a8f8ff commit 2fa6b35

File tree

2 files changed

+8
-7
lines changed

2 files changed

+8
-7
lines changed

flow/scripts/synth_preamble.tcl

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -183,18 +183,19 @@ proc connect_clk {cell_name clock_pin_name target_clk_port_name} {
183183
}
184184
}
185185

186-
proc check_logical_equivalence {top_module gold gate} {
186+
proc check_logical_equivalence {top_module gold gate abc_args lib_args lib_dont_use_args} {
187187
puts "Save a backup that won't get deleted by this function"
188188
design -save backup_1
189189

190190
# Create new modules
191+
192+
#puts "Create new modules"
191193
design -copy-from $gold -as gold $top_module
192194
design -copy-from $gate -as gate $top_module
193195

194196
equiv_make -inames gold gate equiv
195-
196-
prep -flatten -top equiv
197197
yosys cd equiv
198+
prep -flatten -top equiv
198199
opt_clean -purge
199200

200201
async2sync

flow/scripts/two_phase_clk_synth.tcl

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,8 @@ delete t:\$print
8787
# At least this is predictable.
8888
renames -wire
8989

90+
# Optimize the design
91+
opt -purge
9092

9193
puts "Duplicate each flip-flop"
9294
techmap -max_iter 1 -map $::env(DUPLICATE_DFFS_MAP_FILE)
@@ -107,6 +109,7 @@ connect_clk *custom_FF_replace_2.mux_latch C clk_1
107109
connect_clk *custom_FF_replace_1.mux_latch C clk_2
108110

109111

112+
design -save post_retiming
110113
design -save pre_retiming
111114

112115
puts "Perform retiming"
@@ -116,10 +119,7 @@ opt -noff -purge
116119
design -save post_retiming
117120

118121
puts "Perform logical equivalence checking"
119-
check_logical_equivalence $::env(DESIGN_NAME) pre_retiming post_retiming
120-
121-
# Optimize the design
122-
opt -purge
122+
check_logical_equivalence $::env(DESIGN_NAME) pre_retiming post_retiming $abc_args $lib_args $lib_dont_use_args
123123

124124
# puts "Replace each DFF with a corresponding latch"
125125
techmap -autoproc -map $::env(DFF_TO_LATCH_MAP_FILE)

0 commit comments

Comments
 (0)