Initial commit.
[freedom-sifive.git] / fpga / e300artydevkit / script / impl.tcl
1 set_param {messaging.defaultLimit} 1000000
2
3 read_ip [glob -directory $ipdir [file join * {*.xci}]]
4
5 synth_design -top $top -flatten_hierarchy rebuilt
6 write_checkpoint -force [file join $wrkdir post_synth]
7
8 opt_design
9 write_checkpoint -force [file join $wrkdir post_opt]
10
11 place_design
12 write_checkpoint -force [file join $wrkdir post_place]
13
14 phys_opt_design
15 power_opt_design
16 route_design
17 write_checkpoint -force [file join $wrkdir post_route]
18
19 write_bitstream -force [file join $wrkdir "${top}.bit"]
20 write_sdf -force [file join $wrkdir "${top}.sdf"]
21 write_verilog -mode timesim -force [file join ${wrkdir} "${top}.v"]
22 write_debug_probes -force [file join $wrkdir "${top}.ltx"]
23
24 # AR 63042 <http://www.xilinx.com/support/answers/63041.html>:
25 # Work around the write_mem_info command not supporting "processor-less"
26 # (non-Microblaze) designs.
27 set bram_inst [get_cells -hierarchical "bram"]
28 if {$bram_inst ne ""} {
29 source [file join $scriptdir "bram.tcl"]
30 write_mmi [file join $wrkdir "${top}.mmi"] $bram_inst
31 }
32
33 if {[info exists bootrom_inst]} {
34 puts "Generating bootrom.mmi ..."
35 set rom_inst [get_cells -hierarchical "${bootrom_inst}"]
36 if {$rom_inst ne ""} {
37 source [file join $scriptdir "bram.tcl"]
38 write_mmi [file join $wrkdir "bootrom.mmi"] $rom_inst
39 }
40 }
41
42 set rptdir [file join $wrkdir report]
43 file mkdir $rptdir
44 set rptutil [file join $rptdir utilization.txt]
45 report_datasheet -file [file join $rptdir datasheet.txt]
46 report_utilization -hierarchical -file $rptutil
47 report_clock_utilization -file $rptutil -append
48 report_ram_utilization -file $rptutil -append -detail
49 report_timing_summary -file [file join $rptdir timing.txt] -max_paths 10
50 report_high_fanout_nets -file [file join $rptdir fanout.txt] -timing -load_types -max_nets 25
51 report_drc -file [file join $rptdir drc.txt]
52 report_io -file [file join $rptdir io.txt]
53 report_clocks -file [file join $rptdir clocks.txt]