[Script] Add a template yosys script with rewriting at the end
This commit is contained in:
parent
035043d0d8
commit
7adb78b159
|
@ -0,0 +1,30 @@
|
||||||
|
# Yosys synthesis script for ${TOP_MODULE}
|
||||||
|
# Read verilog files
|
||||||
|
${READ_VERILOG_FILE}
|
||||||
|
|
||||||
|
# Technology mapping
|
||||||
|
hierarchy -top ${TOP_MODULE}
|
||||||
|
proc
|
||||||
|
techmap -D NO_LUT -map +/adff2dff.v
|
||||||
|
|
||||||
|
# Synthesis
|
||||||
|
synth -top ${TOP_MODULE} -flatten
|
||||||
|
clean
|
||||||
|
|
||||||
|
# LUT mapping
|
||||||
|
abc -lut ${LUT_SIZE}
|
||||||
|
|
||||||
|
# Check
|
||||||
|
synth -run check
|
||||||
|
|
||||||
|
# Clean and output blif
|
||||||
|
opt_clean -purge
|
||||||
|
write_blif ${OUTPUT_BLIF}
|
||||||
|
|
||||||
|
# Clear all the designs
|
||||||
|
design -reset
|
||||||
|
|
||||||
|
# Rewrite the .blif to Verilog
|
||||||
|
# so that the pin sequence matches
|
||||||
|
read_blif ${OUTPUT_BLIF}
|
||||||
|
write_verilog ${OUTPUT_VERILOG}
|
Loading…
Reference in New Issue