2019-08-09 17:49:05 -05:00
|
|
|
# Yosys synthesis script for ${TOP_MODULE}
|
|
|
|
# Read verilog files
|
2022-01-17 02:21:29 -06:00
|
|
|
read_verilog ${READ_VERILOG_OPTIONS} ${VERILOG_FILES}
|
2019-08-09 17:49:05 -05:00
|
|
|
|
|
|
|
# Technology mapping
|
|
|
|
hierarchy -top ${TOP_MODULE}
|
|
|
|
proc
|
|
|
|
techmap -D NO_LUT -map +/adff2dff.v
|
|
|
|
|
|
|
|
# Synthesis
|
2021-10-30 17:12:34 -05:00
|
|
|
flatten
|
2021-10-30 16:46:12 -05:00
|
|
|
opt_expr
|
|
|
|
opt_clean
|
|
|
|
check
|
|
|
|
opt -nodffe -nosdff
|
|
|
|
fsm
|
|
|
|
opt -nodffe -nosdff
|
|
|
|
wreduce
|
|
|
|
peepopt
|
|
|
|
opt_clean
|
|
|
|
opt -nodffe -nosdff
|
|
|
|
memory -nomap
|
|
|
|
opt_clean
|
|
|
|
opt -fast -full -nodffe -nosdff
|
|
|
|
memory_map
|
|
|
|
opt -full -nodffe -nosdff
|
|
|
|
techmap
|
|
|
|
opt -fast -nodffe -nosdff
|
2019-08-09 17:49:05 -05:00
|
|
|
clean
|
|
|
|
|
|
|
|
# LUT mapping
|
|
|
|
abc -lut ${LUT_SIZE}
|
|
|
|
|
|
|
|
# Check
|
|
|
|
synth -run check
|
|
|
|
|
|
|
|
# Clean and output blif
|
|
|
|
opt_clean -purge
|
|
|
|
write_blif ${OUTPUT_BLIF}
|